1window.theme=window.theme||{},window.Shopify=window.Shopify||{};const PUB_SUB_EVENTS={infiniteScrollHappen:"infinite-scroll-happen",collectionPaginationChange:"collection-pagination-change",collectionProductChange:"collection-product-change"};let subscribers={};function subscribe(e,t){return void 0===subscribers[e]&&(subscribers[e]=[]),subscribers[e]=[...subscribers[e],t],function(){subscribers[e]=subscribers[e].filter((e=>e!==t))}}function publish(e,t){subscribers[e]&&subscribers[e].forEach((e=>{e(t)}))}window.theme=window.theme||{},window.Shopify=window.Shopify||{},theme.cartCache=null,theme.cartFetchPromise=null,theme.applyCartCount=function(e){e&&"number"==typeof e.item_count&&document.querySelectorAll(".cart_count").forEach((t=>{t.textContent=e.item_count,t.classList.toggle("hidden",e.item_count<=0)}))},theme.invalidateCartCache=function(){theme.cartCache=null,theme.cartFetchPromise=null},theme.fetchCart=function(e){const t=e&&!0===e.force;if(!t&&theme.cartCache)return Promise.resolve(theme.cartCache);if(!t&&theme.cartFetchPromise)return theme.cartFetchPromise;const n=(window.Shopify?.routes?.root||"/")+"cart.js";return theme.cartFetchPromise=fetch(n).then((e=>e.json())).then((e=>(theme.cartCache=e,e))).catch((e=>
1{throw theme.invalidateCartCache(),e})),theme.cartFetchPromise},theme.refreshProductVariantState=function(){const e=document.getElementById("product-json"),t=document.querySelector('[id^="product-select-"]');if(!e||!t)return;let n;try{n=JSON.parse(e.textContent)}catch{return}if(!n.handle)return;const i=document.querySelector("[data-product-form]"),o=i?JSON.parse(i.dataset.productForm||"{}"):{},r=window.Shopify?.routes?.root||"/";fetch(`${r}products/${n.handle}.js`).then((e=>e.ok?e.json():null)).then((e=>{if(!e?.variants)return;const n=e.variants.find((e=>String(e.id)===String(t.value)));if(!n)return;const i=e=>"undefined"!=typeof Shopify&&Shopify.formatMoney&&o.money_format?Shopify.formatMoney(e,o.money_format):(e/100).toFixed(2);document.querySelectorAll(".price-container").forEach((e=>{const t=e.querySelector(".product-price.current .money")||e.querySelector(".product-price.current");t&&(t.innerHTML=n.available?i(n.price):o.sold_out||"Sold out");const r=e.querySelector(".was");r&&n.compare_at_price>n.price&&n.available?(r.innerHTML='<span class="money">'+i(n.compare_at_price)+"</span>",r.style.display=""):r&&(r.style.display="none");const a=e.querySelector(".money_save");a&&(n.compare_at_price>n.price&&n.available?a.style.display="":a.style.display="none");const s=e.querySelector(".product-price.current");s&&s.classList.toggle("sale",n.compare_at_price>n.price&&n.available)})),document.querySelectorAll(".add").forEach((e=>{e.disabled=!n.available,n.available?o.button&&(e.value=o.button):o.sold_out&&(e.value=o.sold_out)}));const r=document.querySelector(".checkout-buy-now-btn");r&&(r.style.display=n.available?"block":"none");const a=document.querySelector("[data-product-form] .shopify-payment-button");a&&(a.style.display=n.available?"block":"none")})).catch((()=>{}))}
1,theme.refreshAfterBfcacheRestore=function(){theme.invalidateCartCache(),theme.fetchCart({force:!0}).then(theme.applyCartCount).catch((()=>{})),theme.refreshProductVariantState()},window.NodeList&&!NodeList.prototype.forEach&&(NodeList.prototype.forEach=function(e,t){t=t||window;for(var n=0;n<this.length;n++)e.call(t,this[n],n,this)}),theme.Sections=function(){this.constructors={},this.instances=[],$(document).on("shopify:section:load",this._onSectionLoad.bind(this)).on("shopify:section:unload",this._onSectionUnload.bind(this)).on("shopify:section:select",this._onSelect.bind(this)).on("shopify:section:deselect",this._onDeselect.bind(this)).on("shopify:block:select",this._onBlockSelect.bind(this)).on("shopify:block:deselect",this._onBlockDeselect.bind(this))},theme.Sections.prototype=_.assignIn({},theme.Sections.prototype,{_createInstance:function(e,t){var n=$(e),i=n.attr("data-section-id"),o=n.attr("data-section-type");if(t=t||this.constructors[o],!_.isUndefined(t)){var r=_.assignIn(new t(e),{id:i,type:o,container:e});this.instances.push(r)}},_onSectionLoad:function(e){var t=$("[data-section-id]",e.target)[0];t&&this._createInstance(t)},_onSectionUnload:function(e){this.instances=_.filter(this.instances,(function(t){var n=t.id===e.originalEvent.detail.sectionId;return n&&_.isFunction(t.onUnload)&&t.onUnload(e),!n}))},_onSelect:function(e){var t=_.find(this.instances,(function(t){return t.id===e.originalEvent.detail.sectionId}));!_.isUndefined(t)&&_.isFunction(t.onSelect)&&t.onSelect(e)},_onDeselect:function(e){var t=_.find(this.instances,(function(t){return t.id===e.originalEvent.detail.sectionId}));!_.isUndefined(t)&&_.isFunction(t.onDeselect)&&t.onDeselect(e)},_onBlockSelect:function(e){var t=_.find(this.instances,(function(t){return t.id===e.originalEvent.detail.sectionId}));!_.isUndefined(t)&&_.isFunction(t.onBlockSelect)&&t.onBlockSelect(e)},_onBlockDeselect:function(e){var t=_.find(this.instances,(function(t){return t.id===e.originalEvent.detail.sectionId}));!_.isUndefined(t)&&_.isFunction(t.onBlockDeselect)&&t.onBlockDeselect(e)},register:function(e,t){this.constructors[e]=t,$("[data-section-type="+e+"]").each(function(e,n){this._createInstance(n,t)}.bind(this))}});var mobile=window.matchMedia("(max-width: 740px)"),tablet=window.matchMedia("(max-width: 979px) and (min-width: 741px)"),desktop=window.matchMedia("(min-width: 980px)");$(document).ready((function(){document.addEventListener("lazybeforeunveil",(function(e){AOS.init({disable:"mobile"})})),Events.on("editor:section:select",(function(){AOS.init()})),$("input, textarea").placeholder(),$(".rte table").wrap('<div class="rte__table-wrapper"></div>'),$('[data-fancybox^="quick-view"]').fancybox({type:"ajax",toolbar:!1,infobar:!1,arrows:!1,baseClass:"quickview-popup",afterShow:function(){var e=document.querySelector(".product-quick-view");Events.trigger("quickview:load",e)}});var e=$("#sidebar");$(document).on("click.toggleNav touch.toggleNav",".show",(function(){e.toggleClass("open")})),$(window).on("load resize orientationchange",(function(){if($(window).width()>980){var e=$("header").height(),t=Number(e)+Number(20);$(".share-icons").stick_in_parent({parent:".product-page",offset_top:t})}}))}));var Events=new EventEmitter3,MainVariantTitle="";function getFetchedSection(e,t){if(!e)return null;const n=e.querySelector(`#shopify-section-${t}`);if(n)return n;const i=t.includes("__")?`__${t.split("__").pop()}`:t,o=e.querySelector(`[id^="shopify-section-"][id$="${i}"]`);if(o)return o;const r=e.querySelector('[data-section-type="product-section"]');return r?r.closest('[id^="shopify-section-"]')||r.parentElement:null}function syncProductGlobalsFromDoc(e){e&&e.querySelectorAll("script").forEach((e=>{const t=e.textContent||"";if(t.includes("window.productSpecification")||t.includes("window.productDescription"))try{new Function(t)()}catch(e){}}))}function applyProductTitle(e,t){if(!e)return null;syncProductGlobalsFromDoc(e);const n=e.querySelector(".product_title")?.textContent?.trim();if(!n)return null;(t?t.querySelectorAll(".product_title"):document.querySelectorAll(".product_title")).forEac
1h((e=>{e.textContent=n}));const i=e.querySelector('meta[itemprop="name"]'),o=document.querySelector('meta[itemprop="name"]');i&&o&&o.setAttribute("content",i.getAttribute("content"));const r=document.title.includes(" â ")?document.title.split(" â ").slice(1).join(" â "):"";return document.title=r?`${n} â ${r}`:n,n}Events.trigger=Events.emit,theme.ProductForm=function(e,t,n){$(e);let i={},o=document.querySelector("inventory-message").children[1].children[1].innerText?document.querySelector("inventory-message").children[1].children[1].innerText:"",r="";var a=JSON.parse(e.dataset.productForm||"{}"),s=s||[],c=c||[],l="",d=null,u=null,p=0;const h=document.querySelectorAll(".addons-products__list .addons-products__item")?document.querySelectorAll(".addons-products__list .addons-products__item"):null,f=document.querySelectorAll(".addons-products__list .addons-product__ottoman")?document.querySelectorAll(".addons-products__list .addons-product__ottoman"):null,m=document.querySelector("[data-addon-variant-per-unit-price]")?document.querySelector("[data-addon-variant-per-unit-price]"):null,v=document.querySelector("[data-addon-variant-all-unit-price]")?document.querySelector("[data-addon-variant-all-unit-price]"):null,g=document.querySelector("input[data-addon-variant-all-added-once]")?document.querySelector("input[data-addon-variant-all-added-once]"):null,y=e.querySelector("#product-select-"+n.id);async function w(e,t){const n={items:e};try{const e=await fetch("/cart/add.js",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(n)});await e.json();
1return theme.invalidateCartCache(),theme.fetchCart({force:!0}).then(theme.applyCartCount).catch((e=>{})),t&&function(){const e=document.querySelector(".loader-area");fetch("/cart?section_id=cart-items").then((e=>{if(!e.ok)throw new Error("Failed to fetch updated cart section");return e.text()})).then((t=>{const n=(new DOMParser).parseFromString(t,"text/html").getElementById("CartDrawer");e.classList.remove("hidden"),n&&(document.getElementById("CartDrawer").innerHTML=n.innerHTML);const i=document.querySelector("cart-drawer"),o=document.getElementById("PageContainer");i.classList.add("animate"),setTimeout((()=>{i.classList.contains("is-empty")&&i.classList.remove("is-empty"),i.classList.contains("active")||i.classList.add("active"),o&&!o.classList.contains("active")&&o.classList.add("active"),setTimeout((()=>{e.classList.add("hidden")}),600)}),200)})).catch((e=>{}))}(),!0}catch(e){return!1}}async function S(e){try{theme.invalidateCartCache();const t=await theme.fetchCart({force:!0}),n=getStorage("cart_final_note")||"";let i=n?`${n}\n${e}`:e;const o=[],r=i.split("\n");for(const e of r){t.items.some((t=>{const n=t.variant_title?t.variant_title.split(" / "):[],i=t.variant_title?` - ${t.variant_title}`:"",o=[t.title.endsWith(i)?t.title.slice(0,-i.length):t.title,...n].filter(Boolean).join(" | ");return e.includes(o)}))&&!o.includes(e)&&o.push(e)}const a=o.join("\n");setStorage("cart_final_note",a);const s=function(e){if(!e)return"";const t=e.split("\n").filter(Boolean);let n=0,i="";return t.forEach((e=>{const t=e.split("|").map((e=>e.trim())),o=t[t.length-1],r=o.match(/(\d+)-(\d+)/);if(r){const e=parseInt(r[1],10)+parseInt(r[2],10);e>n&&(n=e,i=o)}!i&&o.includes("In Stock")&&(i=o)})),i?`Confirmed Lead Time: ${i}`:""}(a);await fetch("/cart/update.js",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({note:s})})}catch(e){}}async function b(e,t,i,o){if(1){const r=Array.isArray(e)?e:[e],a=Array.isArray(t)?t:[t];if(r.length!==a.length)return!1;const s=document.getElementById("product-select-"+n.id)?document.getElementById("product-select-"+n.id):null,c=r.map(((e,t)=>{const n=s?.querySelector(`option[value="${e}"]`)?.dataset.variantFabricType||null,i={id:e,quantity:a[t]};return n&&(i.properties={Fabric:n}),i})),l=await w(c,o),d=await S(i);return l&&d}return!1}function _(e,t){e=Number(e),t=Number(t);const n=s.indexOf(e);t>0?-1===n?(s.push(e),c.push(t)):c[n]=t:0===t&&-1!==n&&(s.splice(n,1),c.splice(n,1))}function k(e,t,n,i,o,r,a,c,p,h){if(!e)return;const f=e.trim().toLowerCase(),m=t?.trim().toLowerCase()||"",v=n?.trim().toLowerCase()||"",g=m?`${f} ${m}`:f;let y=null,w=[],S=0,b=0,$=0;i.forEach((e=>{let t=e.dataset.addonVariantGroupName?.trim().toLowerCase()||"";t=t.replace(/\s*\/\s*/g," ");const n=e.querySelector(".addons-products__item-quantity-input"),r=Number(e.dataset.addonVariantPrice)||0,a=parseInt(n?.value)||0;if(t.includes(g)){if(e.classList.remove("hidden"),"slim"!==v&&t.includes("slim"))return e.classList.add("hidden"),n.value=0,l="",void _(e.dataset.addonVariantId,0);if("slim"===v&&!t.includes("slim"))return e.classList.add("hidden"),n.value=0,l="",void _(e.dataset.addonVariantId,0);y||(y=r);const s=Number(e.dataset.addonVariantQtyLimit)||1;S+=r*s,$+=s;const f=e.querySelector('button[name="minus"]'),m=e.querySelector('button[name="plus"]');if(f&&!f.hasEventListener&&(f.addEventListener("click",(e=>function(e,t,n,i,o,r,a){const s=e.target.closest(".addons-products__item").querySelector(".addons-products__item-quantity-input"),c=s.closest(".addons-products__item").dataset.add
1onVariantId;let u=parseInt(s.value)||0,p=u>0?u-1:0;p>=0&&(s.value=p,E(s),t[c]=s.value);_(c,p);let h=0,f=0;i.forEach((e=>{if(!e.classList.contains("hidden")){const t=e.querySelector(".addons-products__item-quantity-input"),n=parseInt(t?.value)||0,i=parseInt(e.dataset.addonVariantPrice)||0;h+=n,f+=i*n}})),o.forEach((e=>{const t=e.querySelector('input[type="checkbox"]');if(t&&t.checked){const t=parseFloat(e.dataset.crossSellingProductsPrice||"0");f+=t}})),n?.checked&&h<r&&(n.checked=!1);0===h&&x(d,l="");q(a,f)}(e,p,c,i,o,$,h))),f.hasEventListener=!0),m&&!m.hasEventListener&&(m.addEventListener("click",(e=>function(e,t,n,i,o,r,a){l=e.target.closest(".addons-products__item").querySelector("span")?.innerText.trim();const s=e.target.closest(".addons-products__item").querySelector(".addons-products__item-quantity-input"),c=s.closest(".addons-products__item").dataset.addonVariantId;let u=(parseInt(s.value)||0)+1;const p=parseInt(s.max)||0;u<=p&&(s.value=u,E(s),t[c]=s.value,_(c,u),x(d,l));let h=0,f=0;i.forEach((e=>{if(!e.classList.contains("hidden")){const t=e.querySelector(".addons-products__item-quantity-input"),n=parseInt(t?.value)||0,i=parseInt(e.dataset.addonVariantPrice)||0;h+=n,f+=i*n}})),o.forEach((e=>{const t=e.querySelector('input[type="checkbox"]');if(t&&t.checked){const t=parseFloat(e.dataset.crossSellingProductsPrice||"0");f+=t}})),n&&h===r&&(n.checked=!0);q(a,f)}(e,p,c,i,o,$,h))),m.hasEventListener=!0),n.addEventListener("change",(()=>{E(n),l=e.querySelector("span")?.innerText.trim(),p[e.dataset.addonVariantId]=n.value,_(e.dataset.addonVariantId,n.value),x(d,l),q(h,L(i,o))})),p[e.dataset.addonVariantId]||(p[e.dataset.addonVariantId]=n.value),c&&c.checked){const t=e.dataset.addonVariantId;n.value=s,w.push({id:t,qty:s,name:e.querySelector("span")?.innerText.trim()})}else n.value=0,_(e.dataset.addonVariantId,0),l="",x(d,u||l);b+=r*a}else n.value=0,e.classList.add("hidden"),l="",_(e.dataset.addonVariantId,0)}));w.some((e=>!s?.includes(e.id)))&&w.forEach((e=>{_(e.id,e.qty),x(d,e.name)})),o.forEach((e=>{let t=e.dataset.crossSellingProductsGroupName?.trim().toLowerCase()||"";t=t.replace(/\s*\/\s*/g," ");const n=e.querySelector('input[type="checkbox"]'),r=e.dataset.crossSellingProductsId;if(!t.includes(g))return e.classList.add("hidden"),n.checked=!1,void n.dispatchEvent(new Event("change",{bubbles:!0}));e.classList.remove("hidden"),n.addEventListener("change",(()=>{n.checked?(u=e.dataset.crossSellingProductVariantName||"",o.forEach((n=>{if(n===e)return;let i=n.dataset.crossSellingProductsGroupName?.trim().toLowerCase()||"";if(i=i.replace(/\s*\/\s*/g," "),i===t){const e=n.querySelector('input[type="checkbox"]');if(e&&e.checked){e.checked=!1,e.dispatchEvent(new Event("change",{bubbles:!0}));_(n.dataset.crossSellingProductsId,0)}}})),_(r,1)):(_(r,0),u=""),l||x(d,u),q(h,L(i,o))}))})),r&&y&&(r.textContent="$"+y/100),a&&(a.textContent="$"+S/100),q(h,L(i,o))}function L(e,t){let n=0;return e.forEach((e=>{const t=parseInt(e.querySelector(".addons-products__item-quantity-input")?.value)||0,i=Number(e.dataset.addonVariantPrice)||0;n+=t*i})),t.forEach((e=>{const t=e.querySelector('input[type="checkbox"]');if(t&&t.checked){const t=parseFloat(e.dataset.crossSellingProductsPrice||"0");n+=t}})),n}function q(e,t){const n=e+t;document.querySelectorAll(".price-container").forEach((e=>{const t=e.querySelector(".product-price.current .money")||e.querySelector(".product-price");t&&(t.textContent=T(n))})),function(e){const t=document.querySelector(".klarna-affirm-osm");if(!t)return;const n=parseInt(t.dataset.month)||1,i=.15/12,o=e/100*i*Math.pow(1+i,n),r=Math.pow(1+i,n)-1,a=o/r,s=Math.round(a).toLocaleString();t.innerHTML=t.innerHTML.replace(/Starting at \$[0-9,.]+\/mo\./,`Starting at $${s}/mo.`);const c=document.querySelector(".pdb-affirm__title--amount");c&&(c.innerText="$"+s);const l=document.querySelector(".affirm-as-low-as");l&&(l.setAttribute("data-amount",Math.round(e)),window.affirm&&affirm.ui&&"function"==typeof affirm.ui.refresh&&affirm.ui.ready((()=>affirm.ui.refresh())),initFinancePopups());initLearnMoreLink(t)}(n)}function E(e){let t=parseInt(e.value)||0;const n=parseInt(e.max)||0,i=parseInt(e.min)||0;t<i?e.value=i:t>n&&(e.value=n),isNaN(t)&&(e.value=0)}function C(e,t,i,o){if(!e||!t)return null;let r;if(null!=i){e.find((e=>e.parent_option_name===i))&&(r=e.find((e=>e.option_name===t&&e.parent_option_name===i)))}if(r||(r=e.find((e=>e.option_name===t))),!r)return null;const a=function(e,t){const n=e=>{const t=e.match(/\d+/g);return t?Math.max(...t.map(Number)):0};return n(e)>n(t)?e:t}(r.conditional_handle&&n.handle.includes(r.conditional_handle)?r.priority_message:r.message,o);return{message:a,color:r.color}}function x(e,t){if(!e||!window.messageVariantFormat)return;let i="",a="",s="";const c=e.option1.toLowerCase().replace(/ /g,"_").replace(/\s?\(\s?/g,"(").replace(/\s?\)\s?/g,")"),l=window.messageVariantFormat[c];if(!l)return;const d=C(l.level_one,e.option1,null,a);d&&(i=d.message,a=i,s=d.color);const u=C(l.level_one,e.option2,e.option1,a);u&&(i=u.message,a=i,s=u.color);const p=C(l.level_two,e.option3,e.option2,a);if(p&&(i=p.message,a=i,s=p.color),t){const n=C(l.level_three,t,e.option3,a);n&&(i=n.message,a=i,s=n.color)}!function(e,t,i,a,s){const c=document.querySelector("inventory-message");if(!c)return!1;const l=c.querySelector(".inventory__message");if(l){const n=l.querySelector(".inventory__signal");n&&t&&(n.style.backgroundColor=t);const i=l.querySelector(".inventory__text");i&&e&&(i.textContent=e)}c.style.display=e&&t?"block":"none";o=e,r=""===o?"":[n.title,i,a,s,o].filter((e=>e&&"null"!==e)).join(" | ")}
1(i,s,e.option1,e.option2,e.option3)}if(function(){var n=e.querySelector(".product-quantity");if(!n)return!1;t.on("quantitycontrol:plus",(function(){var e=n.value,t=n.max;if(parseInt(e)>=parseInt(t)){var i=$(".product-add"),o=theme.strings.qtyErrorFirst+"Â "+t+"Â "+theme.strings.qtyErrorLast,r=theme.strings.qtySoldOut;t>0?i.before('<div class="errors qty-error">'+o+"</div>"):i.before('<div class="errors qty-error">'+r+"</div>"),setTimeout((function(){$(".qty-error").fadeOut(),$(".qty-error").remove()}),2e3)}else{if((e=parseInt(n.value)+1)<1)return!1;n.value=e}})),t.on("quantitycontrol:minus",(function(){var e=parseInt(n.value)-1;if(e<1)return!1;n.value=e})),function(){var n=e.querySelector(".quantity-control-up");if(!n)return!1;n.addEventListener("click",(function(e){e.preventDefault(),t.trigger("quantitycontrol:plus")}))}(),function(){var n=e.querySelector(".quantity-control-down");if(!n)return!1;n.addEventListener("click",(function(e){e.preventDefault(),t.trigger("quantitycontrol:minus")}))}()}(),1==n.variants.length)return!1;function T(e){if(a.currency_switcher_enabled){var t=Currency.convert(e,defaultCurrency,Currency.currentCurrency),n=Currency.moneyFormats[Currency.currentCurrency][Currency.format];return Currency.formatMoney(t,n)}return Shopify.formatMoney(e,a.money_format)}new Shopify.OptionSelectors("product-select-"+n.id,{product:n,onVariantSelected:function(a){if(!a)return void t.trigger("variantunavailable");if(1==n.variants.length)return;const u=new CustomEvent("tabChange",{detail:a});window.dispatchEvent(u);const w=new CustomEvent("reviewChange",{detail:a});window.dispatchEvent(w),t.trigger("variantchange",a),t.trigger("variantchange:option1:"+a.option1),t.trigger("variantchange:option2:"+a.option2),t.trigger("variantchange:option3:"+a.option3),MainVariantTitle=a.title,function(e){p=e;for(let t of y.options)if(e==t.value){const e=t.dataset.offeredProductId,n=t.dataset.offeredQuantity;e&&(s=JSON.parse(e),c=JSON.parse(n));break}}(a.id),k(a.option1,a.option2,a.option3,h,f,m,v,g,i,a.price),g&&g.addEventListener("change",(()=>{k(a.option1,a.option2,a.option3,h,f,m,v,g,i,a.price)})),d=a,t.on("variantchange",(function(e){x(e,l),d=e})),e.querySelectorAll(".price-container").forEach((function(e){var t=e.querySelector(".was"),n=e.querySelector(".product-price.current"),i=e.querySelector(".money_save");t&&i&&(!a.compare_at_price||a.compare_at_price<=a.price||!a.available?(t.style.display="none",i.style.display="none",n.classList.remove("sale")):(t.removeAttribute("style"),i.removeAttribute("style"),n.classList.add("sale")))})),a.featured_image&&(t.trigger("variantchange:image",a.featured_image.id),setTimeout((()=>{const e=Number(a?.featured_image?.position-1);if(!isNaN(e)){const t=document.querySelector("product-media-gallery");e!==t?.mainSlider?.realIndex&&t?.bindVariantChange(e)}}),200),setTimeout((function(){$(".main-product-gallery-slider").slick("slickGoTo",+a.featured_image.position-1),$("#thumbnail-gallery .main-product-thumbnail-slider").slick("slickGoTo",+a.featured_image.position-1)}),200));document.querySelectorAll(".custom-checkout-button").forEach((e=>{e.href=`/cart/${a.id}:1`,e.setAttribute("data-variant-id",a.id)})),r=""===o?"":[n.title,a.option1,a.option2,a.option3,o].filter((e=>e&&"null"!==e)).join(" | ");const S=document.querySelector(".product_title");if(S){let e=a.title;e&&e.includes("Extra-Deep")?S.textContent=`${window.productSpecification.title_extra_deep}`:e&&e.includes("Classic")&&(S.textContent=`${window.productSpecification.title}`)}const b=document.querySelectorAll(".product__description .expandable_text");b.length>0&&b.forEach((e=>{let t=a.title;t&&t.includes("Extra-Deep")?e.innerHTML=`${window.productDescription.description_extra_deep}`:t&&t.includes("Classic")&&(e.innerHTML=`${window.productDescription.description}`)}));const _=document.querySelectorAll("tab-container .tab-product-description");_.length>0&&_.forEach((e=>{let t=a.title;t&&t.includes("Extra-Deep")?e.innerHTML=`${window.productDescription.description_extra_deep}`:t&&t.includes("Classic")&&(e.innerHTML=`${window.productDescription.description}`)}
1));const L=document.querySelector(".product-special-feature__container.only-extra-deep");if(L){let e=a.title;e&&e.includes("Extra-Deep")?L.classList.add("active"):L.classList.remove("active")}},enableHistoryState:a.enable_history}),t.on("variantchange",(function(t,n){if(!(n=e.querySelector(".product-quantity")))return!1;n.max=t.inventory_quantity,n.max<1?n.value="0":n.value="1"})),e.querySelectorAll(".single-option-selector").forEach((function(e,n){var i=n+1;t.on("swatch:change:"+i,(function(t){$(e).val(t).trigger("change")}))})),e.querySelectorAll(".price-container").forEach((function(n){var i=n.querySelector(".product-price.current .money")||n.querySelector(".product-price");t.on("variantchange",(function(e){var t=T(e.price);e.available||(t=a.sold_out),i.innerHTML=t})),t.on("variantunavailable",(function(){i.innerHTML=a.unavailable;const t=e.querySelector("inventory-message");t&&(t.style.display="none");const o=n.querySelector(".product-price.current");o&&o.classList.contains("sale")&&o.classList.remove("sale")}))})),e.querySelectorAll(".price-container").forEach((function(e){var n=e.querySelector(".was");t.on("variantchange",(function(t){n||(e.querySelector(".product-price.current").insertAdjacentHTML("beforebegin",'<span class="product-price was"></span>'),n=e.querySelector(".was"));var i="";t.compare_at_price>t.price&&"undefined"!==n?(i=T(t.compare_at_price),n.removeAttribute("style")):n.style.display="none",t.available||"undefined"===n||(i="",n.style.display="none"),n.innerHTML='<span class="money">'+i+"</span>"})),t.on("variantunavailable",(function(){n||(e.querySelector(".product-price.current").insertAdjacentHTML("beforebegin",'<span class="product-price was"></span>'),n=e.querySelector(".was")),n.style.display="none"}))})),e.querySelectorAll(".price-container").forEach((function(e){var n=e.querySelector(".money_save");t.on("variantchange",(function(t){n||(e.querySelector(".product-price.current").insertAdjacentHTML("afterend",'<span class="money_save money_save_col"></span>'),n=e.querySelector(".money_save"));var i,o="";if(t.compare_at_price>t.price){var r=(t.compare_at_price/100).toFixed(2);o=100*(r-(t.price/100).toFixed(2))/r,n.removeAttribute("style")}t.available||void 0===n||(o="",n.style.display="none"),n.innerHTML=`(${i=o,i%1==0?i:parseFloat(i.toFixed(2))}% OFF)`})),t.on("variantunavailable",(function(){n||(e.querySelector(".product-price.current").insertAdjacentHTML("afterend",'<span class="money_save money_save_col"></span>'),n=e.querySelector(".money_save")),n.style.display="none"}))})),function(){var n=e.querySelector(".variant_sku");if(!n)return!1;t.on("variantchange",(function(e){var t=e.sku;n.innerHTML=t})),t.on("variantunavailable",(function(){var e=a.unavailable;n.innerHTML=e}))}(),function(){const e=document.querySelectorAll(".checkout-buy-now-btn");e.length&&e.forEach((e=>{e.addEventListener("click",(async function(e){try{e.preventDefault();const t=this.dataset.variantId,n=Number(t);s.push(n),c.push(1),b(s,c,r,!1).finally((()=>{window.location.href="/checkout"}))}catch(e){alert("Failed to Add Cart Notes")}}))}))}(),document.querySelectorAll(".add").forEach((function(e){"drawer"==theme.settings.ajaxCartMethod?e.addEventListener("click",(function(e){e.preventDefault();const t=Number(p);s.length,s.push(t),c.push(1),b(s,c,r,!0),s.pop(),c.pop()})):e.addEventListener("click",(function(e){e.preventDefault();const t=Number(p);s.length,s.push(t),c.push(1),b(s,c,r,!1).finally((()=>{window.location.href="/cart"}))})),t.on("variantchange",(function(t){var n=a.button,i=!1;t.available||(n=a.sold_out,i=!0),e.value=n,e.disabled=i})),t.on("variantunavailable",(function(){e.value=a.unavailable,e.disabled=!0}))}
1)),function(){var e=$(".checkout-buy-now-btn");if(!e)return!1;t.on("variantchange",(function(t){t.available?e.attr("style","display: block !important;"):e.attr("style","display: none !important;")})),t.on("variantunavailable",(function(){e.attr("style","display: none !important;")}))}(),function(){var n=e.querySelector(".shopify-payment-button");if(!n)return!1;t.on("",(function(e){e.available?n.style.display="block":n.style.display="none"}))}(),function(){var n=e.querySelector(".back_in_stock");if(!n)return!1;t.on("variantchange",(function(e){e.available?n.style.display="none":(n.style.display="block",document.getElementById("hidden_variant").value="SKU: "+e.sku,document.getElementById("hidden_title").value="Variant: "+e.title)})),$(".back_in_stock").click((function(){stopPropagation(),$(".back-in-stock-snippet").show()})),$(".back-in-stock-snippet").click((function(){stopPropagation()})),$(document).on("click",(function(){$(".back-in-stock-snippet").hide()}))}(),initMainSwatches(document),function(e){var i=e.querySelectorAll("[type=radio]"),o=!1;function r(e){if(!o&&"3"==e.dataset.position){o=!0,e.parentElement.classList.add("soldout");const t=document.querySelectorAll('[data-position="3"]');for(let n of t)if(n!==e){const e=n.parentElement.querySelector("label");e&&e.click();break}o=!1}}function a(e){e.parentElement.classList.remove("soldout")}i.forEach((function(e){var o=e.dataset.position,s="option"+o,c=["option1","option2","option3"].filter((function(e){return e!=s}));e.addEventListener("change",(function(r){t.trigger("swatch:change:"+o,e.value),n.deselect&&(r.target.classList.add("active"),i.forEach((t=>{t.dataset.position==o&&t.value!=e.value&&t.classList.contains("active")&&t.classList.remove("active")})))})),n.deselect&&e.addEventListener("click",(function(e){e.target.classList.contains("active")&&"2"===o&&(t.trigger("swatch:change:"+o,"No Selection"),e.target.classList.remove("active"))})),t.on("variantchange:option"+o+":"+e.value,(function(){e.checked=!0})),t.on("variantchange",(function(t){var i=!1;
1n.variants.forEach((function(n){n.available&&n[s]==e.value&&n[c[0]]==t[c[0]]&&n[c[1]]==t[c[1]]&&(i=!0)})),i?a(e):r(e)}))})),t.on("variantunavailable",(function(){var e={};$(i).filter(":checked").toArray().forEach((function(t){var n="option"+t.dataset.position,i=t.value;e[n]=i})),i.forEach((function(t){var i=!1,o="option"+t.dataset.position,s=t.value,c=["option1","option2","option3"].filter((function(t){return e[t]&&t!=o}));n.variants.forEach((function(t){t.available&&t[o]==s&&t[c[0]]==e[c[0]]&&t[c[1]]==e[c[1]]&&(i=!0)})),i?a(t):r(t)}))}))}(document)},theme.ScrollGallery=function(e,t){t.trigger=t.emit;$(e);var n=JSON.parse(e.dataset.galleryConfig||"{}"),i=$(".product-image-container",e);!function(){function o(){var o=!1,r=!1;if("arrows"===n.sliderControls)o=!0;else if("dots"===n.sliderControls)r=!0;$(i).not(".slick-initialized").slick({fade:!0,infinite:!0,mobileFirst:!0,slidesToShow:1,vertical:!1,slidesToScroll:1,fade:!1,arrows:o,nextArrow:'<a class="slick-next slick-arrow"><i class="la la-angle-right" aria-hidden="true"></i></a>',prevArrow:'<a class="slick-prev slick-arrow"><i class="la la-angle-left" aria-hidden="true"></i></a>',dots:r});var a=$(".slick-slide",e);t.on("variantchange:image",(function(e){var t=a.find("[data-image-id]"),n=t.filter("[data-image-id="+e+"]"),o=t.index(n);$(i).slick("slickGoTo",o-1)}))}function r(){i.hasClass("slick-initialized")&&$(i).slick("unslick")}function a(){var n=$(".product-main-image",e);t.on("variantchange:image",(function(t){var i=n.filter("[data-image-id="+t+"]");if(!i.length)return!1;if(n.removeClass("selected").filter(i).addClass("selected"),"index"===template){e.querySelector(".selected").scrollIntoView()}else{var o=document.querySelector("header").offsetHeight;$("html, body").animate({scrollTop:$(".selected").offset().top-o},"slow")}}))}Events.on("mediaquery:desktop",(function(){a(),r()})),Events.on("mediaquery:mobile",o),Events.on("mediaquery:tablet",o),Events.on("editor:section:select",(function(){desktop.matches?(a(),r()):o()}))}(),function(){var t=e.querySelectorAll(".product-main-image");function n(){t.forEach((function(e){var t=(t=(t=e.querySelector("img")).dataset.zoomSrc).replace("{width}","2000");$(e).zoom({url:t})}))}function i(){t.forEach((function(e){$(e).trigger("zoom.destroy")}))}Events.on("mediaquery:desktop",n),Events.on("mediaquery:tablet",i),Events.on("mediaquery:mobile",i),Events.on("editor:section:select",(function(){desktop.matches&&n()}))}(),function(){function e(){const e=$("#sticky-item");if(e.length&&(e.trigger("sticky_kit:detach"),$(window).width()>980)){const t=$("header").height(),n=Number(t)+Number(20);e.stick_in_parent({parent:"#sticky-container",offset_top:n})}}$(window).on("load resize orientationchange",e),window.visualViewport&&(window.visualViewport.addEventListener("resize",e),window.visualViewport.addEventListener("scroll",e))}(),$.fancybox.defaults.btnTpl.fb='<button data-fancybox-fb class="fancybox-button fancybox-button--fb" title="Facebook"><svg viewBox="0 0 24 24"><path d="M22.676 0H1.324C.594 0 0 .593 0 1.324v21.352C0 23.408.593 24 1.324 24h11.494v-9.294h-3.13v-3.62h3.13V8.41c0-3.1 1.894-4.785 4.66-4.785 1.324 0 2.463.097 2.795.14v3.24h-1.92c-1.5 0-1.793.722-1.793 1.772v2.31h3.584l-.465 3.63h-3.12V24h6.115c.733 0 1.325-.592 1.325-1.324V1.324C24 .594 23.408 0 22.676 0"/></svg></button>',$.fancybox.defaults.btnTpl.tw='<button data-fancybox-tw class="fancybox-button fancybox-button--tw" title="Twitter"><svg viewBox="0 0 24 24"><path d="M23.954 4.57c-.885.388-1.83.653-2.825.774 1.013-.61 1.793-1.574 2.162-2.723-.95.556-2.005.96-3.127 1.185-.896-.96-2.173-1.56-3.59-1.56-2.718 0-4.92 2.204-4.92 4.918 0 .39.044.765.126 1.124C7.69 8.094 4.067 6.13 1.64 3.16c-.427.723-.666 1.562-.666 2.476 0 1.71.87 3.213 2.188 4.096-.807-.026-1.566-.248-2.228-.616v.06c0 2.386 1.693 4.375 3.946 4.828-.413.11-.85.17-1.296.17-.314 0-.615-.03-.916-.085.63 1.952 2.445 3.376 4.604 3.416-1.68 1.32-3.81 2.105-6.102 2.105-.39 0-.78-.022-1.17-.066 2.19 1.394 4.768 2.21 7.557 2.21 9.054 0 14-7.497 14-13.987 0-.21 0-.42-.016-.63.962-.69 1.8-1.56 2.46-2.548l-.046-.02z"/></svg></button>',$("body").on("click","[data-fancybox-fb]",(function(){window.open("https://www.facebook.com/sharer/sharer.php?u="+encodeURIComponent(window.location.href)+"&t="+encodeURIComponent(document.title),"","left=0,top=0,width=600,height=300,menubar=no,toolbar=no,resizable=yes,scrollbars=yes")})),$("body").on("click","[data-fancybox-tw]",(function(){window.open("http://twitter.com/share?url="+encodeURIComponent(window.location.href)+"&text="+encodeURIComponent(document.title),"","left=0,top=0,width=600,height=300,menubar=no,toolbar=no,resizable=yes,scrollbars=yes")})),$('[data-fancybox="images"]').fancybox({loop:!0,transitionDuration:100,animationDuration:500,animationEffect:"fade",buttons:["fb","tw","zoom","fullScreen","slideShow","thumbs","close"]})},theme.Product=function(){function e(e){var t=new EventEmitter3;t.trigger=t.emit;var n=document.getElementById("product-json");if(!n)return!1;var i=n.innerHTML;i=JSON.parse(i||"{}");e.querySelectorAll("[data-product-form]").forEach((function(e){theme.ProductForm(e,t,i)})),e.querySelectorAll("[data-scroll-gallery]").forEach((function(e){theme.ScrollGallery(e,t)}))}return e.prototype=_.assignIn({},e.prototype,{}),e}(),theme.settings.showMultipleCurrencies&&Events.on("quickview:load",(function(e){Currency.convertAll(defaultCurrency,Currency.currentCurrency)}));class CustomCornerLinkedProduct extends HTMLElement{constructor(){super(),this.sectionId=this.dataset.sectionId,this.addEventListener("change",this.onChange.bind(this))}async onChange(e){if("INPUT"!==e.target.tagName)return;const t=e.target.dataset.productUrl;if(!t)return;const n=t.startsWith("/")?t:`/${t}`;if(window.location.pathname===n)return;const i=e.target.nextElementSibling?.querySelector(".loader");i?.classList.remove("hidden");try{const e=await fetch(`${n}?view=variant-id-ajax`);let t;if(e.ok){const n=await e.text(),i=(new DOMParser).parseFromString(n,"text/html").querySelector(".fetch-id-detection");if(i){t=Array.from(i.options).find((e=>e.textContent.includes(MainVariantTitle)))?.value}}const o=this.sectionId.replace("__main","__product_details"),r=this.sectionId.replace("__main","__sofa-review"),a=await fetch(`${n}?section_id=${o}`);let s=`${n}?section_id=${r}&view=sofa-ajax`,c=`${n}?section_id=${this.sectionId}&view=sofa-ajax`;t&&(c=`${n}?variant=${t}§ion_id=${this.sectionId}&view=sofa-ajax`,s=`${n}?variant=${t}§ion_id=${r}&view=sofa-ajax`);const l=await fetch(c),d=await fetch(s);let u=l.ok?await l.text():"",p=(new DOMParser).parseFromString(u,"text/html"),h=getFetchedSection(p,this.sectionId);if(!h?.querySelector(".product_title")){const e=t?`${n}?variant=${t}§ion_id=${this.sectionId}`:`${n}?section_id=${this.sectionId}`,i=await fetch(e);i.ok&&(u=await i.text(),p=(new DOMParser).parseFromString(u,"text/html"),h=getFetchedSection(p,this.sectionId))}if(h){const e=document.querySelector(`#shopify-section-${this.sectionId}`);if(e){e.innerHTML=h.innerHTML;const i=applyProductTitle(h,e);t?history.pushState({},"",`${n}?variant=${t}`):history.pushState({},"",`${n}`),this.initializeSection(e,i),initVariantInfo(e),initExpandableText(),initShopPayPopups(e)}}if(a.ok){const e=await a.text(),t=getFetchedSection((new DOMParser).parseFromString(e,"text/html"),o);if(t){const e=document.querySelector(`#shopify-section-${o}`);e&&(e.innerHTML=t.innerHTML),"function"==typeof TabmakeSameHeight&&TabmakeSameHeight(e)}}if(d.ok){const e=await d.text(),t=getFetchedSection((new DOMParser).parseFromString(e,"text/html"),r);if(t){const e=document.querySelector(`#shopify-section-${r}`);e&&(e.innerHTML=t.innerHTML),window.okeWidgetApi&&"function"==typeof window.okeWidgetApi.initAllWidgets&&(window.okeWidgetApi.initAllWidgets(),initOkendoReviewHandling())}}}catch(e){}finally{i?.classList.add("hidden")}}initializeSection(e,t){e&&setTimeout((()=>{"function"==typeof TypewriterHandler&&TypewriterHandler(e),e.querySelectorAll(".color-swatch-tab-title").forEach((e=>{e.addEventListener("click",(t=>{t.preventDefault();const n=e.closest(".color-swatch-tab");n.querySelectorAll(".color-swatch-tab-title").forEach((e=>e.classList.remove("active"))),n.querySelectorAll(".color-swatch-tab-content").forEach((e=>e.classList.remove("active"))),e.classList.add("active");const i=e.getAttribute("href").replace("#",""),o=n.querySelector(`#${i}`);o&&o.classList.add("active")}))})),e.querySelectorAll(".swatch-element.color input").forEach((e=>{e.addEventListener("change",(()=>{const t=e.value,n=e.closest(".swatch-color-groups-with-title")?.querySelector(".selected_color");n&&(n.innerText=t)}))}
1)),window.theme?.Product&&theme.Product(e),"function"==typeof FabricInfoHandler&&FabricInfoHandler(e),t&&e.querySelectorAll(".product_title").forEach((e=>{e.textContent=t}))}),30)}}function debounce(e,t,n){var i;return t||(t=100),function(){var o=this,r=arguments,a=function(){i=null,n||e.apply(o,r)},s=n&&!i;clearTimeout(i),i=setTimeout(a,t),s&&e.apply(o,r)}}customElements.define("custom-corner-linked-product",CustomCornerLinkedProduct),document.addEventListener("section:reloaded",(e=>{const t=e.detail.sectionId,n=document.querySelector(`#shopify-section-${t}`);n&&setTimeout((()=>{window.theme?.Product&&theme.Product(n),"function"==typeof FabricInfoHandler&&FabricInfoHandler(n),$(n).find("[data-fancybox]").fancybox?.(),$(n).find("select").each((function(){"function"==typeof SlimSelect&&new SlimSelect({select:this})}))}),50)})),theme.Header=function(){function e(e){var t,n;!function(){if("true"===e.dataset.announcementBar){var t=parseInt(e.dataset.announcementAutoplaySpeed),n=$(e).find(".announcement_slider").not(".slick-initialized");n.on("init reInit",(function(){document.dispatchEvent(new CustomEvent("theme:header:refresh"))}));var i=n.slick({autoplay:!0,autoplaySpeed:t,infinite:!0,fade:!0,arrows:!1,adaptiveHeight:!1,dots:!1});$(window).resize((function(){i.slick("resize")}))}}(),$("a#search_trigger").click((function(e){return e.stopPropagation(),$("#search_reveal").slideToggle("500"),!1})),$("#search_reveal").on("click",(function(e){e.stopPropagation()})),$(document).on("click",(function(){$("body").hasClass("search")||$("#search_reveal").slideUp("500")})),$("ul.submenu li").on("mouseenter mouseleave",(function(e){if($("ul",this).length){var t=$("ul:first",this);t.offset().left+t.width()<=$("#PageContainer").width()?$(this).removeClass("edge"):$(this).addClass("edge")}})),t=e.dataset.sticky,n=$("header"),$(window).scroll((function(){$(window).scrollTop()>=1&&"true"==t?n.removeClass("scrollheader").addClass("coverheader"):n.removeClass("coverheader").addClass("scrollheader")})),$(".has_sub_menu").hover((function(){$(this).attr("aria-expanded",(function(e){return"false"==e||"false"}))})),jQuery(window).trigger("resize").trigger("scroll")}return e.prototype=_.assignIn({},e.prototype,{}),e}(),theme.FeaturedCollection=function(e){this.$container=$(e);var t=$(".collection-carousel",e),n=t.data("grid");if(t.find(".reveal"),!(i=document.querySelector(".collection-carousel")))return!1;var i=i.dataset.sliderControls,o=!1,r=!1;"arrows"===i?o=!0:"dots"===i&&(r=!0);function a(){t.not(".slick-initialized").slick({infinite:!0,autoplaySpeed:4e3,lazyLoad:"progressive",speed:600,arrows:o,nextArrow:'<a class="slick-next slick-arrow"><i class="la la-angle-right" aria-hidden="true"></i></a>',prevArrow:'<a class="slick-prev slick-arrow"><i class="la la-angle-left" aria-hidden="true"></i></a>',dots:r,slidesToShow:n,slidesToScroll:2,responsive:[{breakpoint:740,settings:{slidesToShow:2,slidesToScroll:2}}]})}a(),$(document).on("shopify:section:load",(function(e){a()})),$(document).on("shopify:section:unload",(function(e){$(e.target).find(".collection-carousel").slick("destroy"),$(document).off(".collection-carousel")}))},theme.Slideshow=function(e){(this.$container=$(e)).attr("data-section-id");var t=$(".flexslider").data("speed");$(".flexslider").flexslider({animation:"fade",slideshowSpeed:t,animationSpeed:600,directionNav:!0,controlNav:!0,pauseOnHover:!0,pauseOnAction:!0,prevText:"",nextText:""})},theme.Slideshow.prototype=_.assignIn({},theme.Slideshow.prototype,{onBlockSelect:function(e){var t=$(e.target).closest(".flexslider").data("flexslider"),n=$(e.target).data("flexslider-index");t.flexslider(n),t.flexslider("pause")},onBlockDeselect:function(){$(event.target).closest(".flexslider").data("flexslider").flexslider("play")}}),theme.newSlideshow=function(e){var t=$(".main-slider"),n=t.find(".embed-player"),i=t.find(".slide-image"),o=0,r=document.querySelector(".main-slider").dataset.videoAudio,a=document.querySelector(".main-slider").dataset.sliderControls;function s(e,t){null!=e&&null!=t&&e.contentWindow.postMessage(JSON.stringify(t),"*")}function c(e,t){var n,i,o,a,c;if(n=e.find(".slick-current"),i=document.querySelector(".slick-current .item").dataset.slideType,a=n.find("iframe").get(0),o=n.data("video-start"),"off"===r)var l="mute";if("vimeo"===i)switch(t){case"play":null!=o&&o>0&&!n.hasClass("started")&&(n.addClass("started"),s(a,{method:"setCurrentTime",value:o})),s(a,{method:"play",value:1});break;case"pause":s(a,{method:"pause",value:1});break}else if("youtube"===i)switch(t){case"play":s(a,{event:"command",func:l}),s(a,{event:"command",func:"playVideo"});break;case"pause":s(a,{event:"command",func:"pauseVideo"});break}else"video"===i&&(currentItem=document.querySelector(".slick-current .item"),null!=(c=currentItem.querySelector("video"))&&("play"===t?c.play():c.pause()))}function l(e,t){if(e[0]){var n,i,o=$(".main-slider"),r=o.width(),a=o.height();
1t=t||16/9,e.each((function(){var e=$(this);r/t<a?(n=Math.ceil(a*t),e.width(n).height(a).css({left:(r-n)/2,top:0})):(i=Math.ceil(r/t),e.width(r).height(i).css({left:0,top:(a-i)/2}))}))}}$((function(){t.on("init",(function(e){e=$(e.currentTarget),setTimeout((function(){c(e,"play")}),1e3),l(n,16/9)})),t.on("beforeChange",(function(e,t){c(t=$(t.$slider),"pause")})),t.on("afterChange",(function(e,t){c(t=$(t.$slider),"play")})),t.on("lazyLoaded",(function(e,t,n,r){++o===i.length&&i.addClass("show")}));var e=!1,r=!1;"arrows"===a?e=!0:"dots"===a&&(r=!0),t.slick({autoplaySpeed:4e3,lazyLoad:"progressive",speed:600,arrows:e,nextArrow:'<a class="slick-next slick-arrow"><i class="la la-angle-right" aria-hidden="true"></i></a>',prevArrow:'<a class="slick-prev slick-arrow"><i class="la la-angle-left" aria-hidden="true"></i></a>',dots:r,cssEase:"cubic-bezier(0.87, 0.03, 0.41, 0.9)"})})),$(window).on("resize.slickVideoPlayer",(function(){l(n,16/9)}))},theme.newSlideshow.prototype=_.assignIn({},theme.newSlideshow.prototype,{onBlockSelect:function(e){var t=$(e.target).closest(".main-slider"),n=$(e.target).data("slider-index");t.slick("slickGoTo",n),t.slick("slickPause")},onBlockDeselect:function(){$(event.target).closest(".main-slider").slick("slickPlay")}}),theme.Maps=function(){var e="",t="",n="",i="",o=!1;function r(r){var a=new EventEmitter3;a.trigger=a.emit,window.gm_authFailure=function(){o=!1,Shopify.designMode?a.trigger("gmauthfailure:themeeditor"):a.trigger("gmauthfailure")};var s,c=r.querySelector("[data-map-config]").innerHTML;if(!(c=JSON.parse(c)).api_key)return!1;!function(){var e=r;function t(){e.classList.add("map-section-load-error")}a.on("gmauthfailure:themeeditor",t),a.on("map:error",t)}(),s=r.querySelector("[data-bg-image]"),a.on("gmauthfailure",(function(){s.classList.add("show-image")})),function(){var e=r.querySelector("[data-map-overlay]");function t(t){t=t||i,e.innerHTML='<div class="map-section-error errors text-center">'+t+"</div>"}a.on("gmauthfailure:themeeditor",t),a.on("map:error",t)}(),function(){var o=r.querySelector("[data-map]");a.on("ready",(function(){(new google.maps.Geocoder).geocode({address:c.address},(function(r,s){s==google.maps.GeocoderStatus.OK?function(e){o.innerHTML="";var t=new google.maps.Map(o,{zoom:c.zoom,center:e[0].geometry.location,draggable:!1,clickableIcons:!1,scrollwheel:!1,disableDoubleClickZoom:!0,styles:c.styles,disableDefaultUI:!0}),n=t.getCenter();new google.maps.Marker({map:t,position:n}),google.maps.event.addDomListener(window,"resize",$.debounce(250,(function(){google.maps.event.trigger(t,"resize"),t.setCenter(n)}))),$(document).on("shopify:section:unload",(function(){google.maps.event.clearListeners(t,"resize")}))}(r):function(o){var r=n;switch(o){case"ZERO_RESULTS":r=e;break;case"OVER_QUERY_LIMIT":r=t;break;case"REQUEST_DENIED":r=i;break}Shopify.designMode&&a.trigger("map:error",r)}(s)}))}))}(),o?a.trigger("ready"):$.getScript("https://maps.googleapis.com/maps/api/js?key="+c.api_key,(function(){o=!0,a.trigger("ready")}))}return r.prototype=_.assignIn({},r.prototype,{}),r}(),theme.Instagram=function(){function e(e){var t=(this.$container=$(e)).attr("data-section-id"),n=this.instagram=$("#instafeed-"+t),i=this.instagram="instafeed-"+t,o=$("#instagram-template").html(),r=n.attr("data-item-limit"),a=new Instafeed({get:"user",limit:r,userId:"self",target:i,accessToken:n.attr("data-access-token"),resolution:"standard_resolution",template:o});_.isUndefined(a.options.accessToken)||a.run()}return e.prototype=_.assignIn({},e.prototype,{onSelect:function(){e()}}),e}(),theme.CollectionReview=function(){function e(e){if(e){var t=parseInt(e.dataset.speed)||3e3,n=e.querySelector("[data-dynamic-review-container]"),i=e.querySelector(".slider__controller--prev"),o=e.querySelector(".slider__controller--next"),r=n?n.querySelectorAll("[data-fancybox]"):[];n&&($(n).slick({infinite:!0,autoplay:!0,autoplaySpeed:t,speed:300,slidesToShow:7,slidesToScroll:1,prevArrow:i,nextArrow:o,responsive:[{breakpoint:3420,settings:{slidesToShow:6}},{breakpoint:2820,settings:{slidesToShow:5}},{breakpoint:2220,settings:{slidesToShow:4}},{breakpoint:1920,settings:{slidesToShow:3}},{breakpoint:740,settings:{slidesToShow:2}},{breakpoint:480,settings:{slidesToShow:1,slidesToScroll:1}}]}),$(r).fancybox({loop:!0,transitionDuration:100,animationDuration:500,animationEffect:"fade",buttons:["close"]}))}}return e.prototype=Object.assign({},e.prototype,{}),e}(),theme.Parallax=function(){function e(e){(this.$container=$(e)).attr("data-section-id");var t=function(e){e.each((function(){var e=this.dataset.bgset.trim().split(","),t=e.map((function(e){return e.trim().split(" ")[0]})),n=e.map((function(e){return e.trim().split(" ")[1].replace("w","")+"px"})),i=null;
1n.forEach((function(e,n){!i&&matchMedia("(max-width: "+e+")").matches&&(i=t[n])})),i||(i=t[t.length-1]),$(this).parallax({imageSrc:i})}))},n=$(".parallax-window");t(n),window.addEventListener("resize",debounce((function(){n.parallax("destroy"),t(n)}),1e3)),$(document).on("shopify:section:unload",(function(e){$(e.target).find(".parallax-window").parallax("destroy"),$(document).off(".parallax-window")})),$(document).on("shopify:section:load",(function(e){t($(e.target).find(".parallax-window"))}))}return e.prototype=_.assignIn({},e.prototype,{}),e}(),theme.InfoSlider=function(){function e(e){var t=$(".info-bar-content").data("speed"),n=$(".info-bar-content").data("arrows"),i=$(".info-bar-content").data("autoplay"),o=$(".info-bar-content").data("shown"),r=$(".info-bar-content"),a=function(e){r.not(".slick-initialized").slick({mobileFirst:!0,slidesToShow:1,vertical:!1,slidesToScroll:1,autoplay:i,autoplaySpeed:t,arrows:n,fade:!1,nextArrow:'<a class="slick-next slick-arrow"><i class="la la-angle-right" aria-hidden="true"></i></a>',prevArrow:'<a class="slick-prev slick-arrow"><i class="la la-angle-left" aria-hidden="true"></i></a>',dots:!1,responsive:[{breakpoint:740,settings:{slidesToShow:o,slidesToScroll:1}}]})};a($(".info-bar-content"));var s=$(".info-bar-content .slick-track").height();$(".info-bar-content .slick-slide").css("height",s+"px"),$(document).on("shopify:section:unload",(function(e){r.hasClass("slick-initialized")&&(r.slick("unslick"),$(document).off(".info-bar-content"))})),$(document).on("shopify:section:load",(function(e){a($(".info-bar-content"))}))}return e.prototype=_.assignIn({},e.prototype,{}),e}(),theme.mobileNav=function(e){$.shifter({maxWidth:1/0}),$("#accordion").find(".accordion-toggle").click((function(){$(this).next().addClass("boom"),$(this).addClass("open"),$(this).attr("aria-expanded",(function(e,t){return"false"==t||"false"})),$(".accordion-content").not($(this).next()).slideUp("fast")})),$("#accordion").find(".menu__child--back").click((function(){$(this).closest(".menu__child--leayer").removeClass("boom"),$(this).closest(".menu__child--leayer").prev().removeClass("open"),$(this).closest(".menu__child--leayer").prev().attr("aria-expanded",(function(e,t){return"false"==t||"false"}))})),$("#accordion").find(".accordion-toggle2").click((function(){$(this).toggleClass("open"),$(this).next().slideToggle("fast"),$(this).attr("aria-expanded",(function(e,t){return"false"==t||"false"})),$(".accordion-content2").not($(this).next()).slideUp("fast")}))},theme.mobileNav.prototype=_.assignIn({},theme.mobileNav.prototype,{onSelect:function(e){!1===e.detail.load&&$.shifter("open")},onDeselect:function(e){$.shifter("close")}}),theme.Collection=function(){function e(e){!function(){var t=e.querySelectorAll(".filter");if(!t)return!1;t.forEach((function(t){var n=t.querySelector(".filter-menu"),i=t.querySelector("ul.filter-list");n.addEventListener("click",(function(){"block"===i.style.display?i.style.display="none":i.style.display="block"})),$(document).on("click",(function(e){e.stopPropagation(),$(e.target).closest(".filter").length||$(i).hide(400)})),t.querySelectorAll("ul.filter-list li").length>20&&i.classList.add("lg");var o=t.querySelectorAll("#full-width-filter ul.filter-list li.current a"),r=e.querySelector("#current-filters");o.length&&(r.style.display="block",$(o).clone().appendTo(r).show(300))}));var n=e.querySelectorAll("#full-width-filter ul.filter-list li.current a"),i=e.querySelector("#current-filters");n.length<1&&$(i).hide(250)}(),function(){var t=e.querySelector("#full-width-filter");if(!t);}(),function(){let e;function t(t){e=$(t).find(".paginate_next").attr("href")||""}function n(){const n=$(".is_infinite");n.data("infiniteScroll")&&n.infiniteScroll("destroy"),t(document),n.infiniteScroll({path:()=>e,checkLastPage:".paginate_next",append:".is_infinite .product-index",hideNav:"#pagination",history:!1,status:".page-load-status"}),n.on("load.infiniteScroll",((e,n)=>{t(n)})),n.on("append.infiniteScroll",((e,t,n,i)=>{publish(PUB_SUB_EVENTS.infiniteScrollHappen,{}),i.length&&publish(PUB_SUB_EVENTS.collectionProductChange,{data:i})}))}n();subscribe(PUB_SUB_EVENTS.collectionPaginationChange,function(e,t){let n;return(...i)=>{clearTimeout(n),n=setTimeout((()=>e.apply(this,i)),t)}}((()=>{n()}),300))}()}return e.prototype=_.assignIn({},e.prototype,{}),e}(),theme.FeatContent=function(){function e(e){var t=new EventEmitter3;t.trigger=t.emit,e.querySelectorAll(".featured-collection").forEach((function(e){theme.FeaturedCollection(e,t)})),e.querySelectorAll(".instagram-feed").forEach((function(e){theme.Instagram(e,t)}))}return e.prototype=_.assignIn({},e.prototype,{}),e}(),$(document).ready((function(){$(".read_more_btn a").on("click",(function(e){var t=$(this).parent(),n=$(".product_excerpt_less_part");return t.toggleClass("expanded"),t.hasClass("expanded")?$(this).text("Read Less"):$(this).text("Read More"),n.toggleClass("close"),$("#read_more").toggleClass("close"),!1}))})),$(document).ready((function(){$(".accordian_item >
1 .accordia_header h5").on("click",(function(){var e=$(this).closest(".accordia_header").siblings(".accordian_body");$(this).hasClass("open")?(e.removeClass("opens").slideUp("fast"),$(this).removeClass("open")):(e.addClass("opens").slideDown("fast"),$(this).addClass("open"))}));var e=$(window).width();$(window).on("resize",(function(t){$(window).width()!==e&&(e=$(window).width())}))})),$(document).ready((function(){$(".faq .question").on("click",(function(e){if(!$(e.target).closest("share-url").length){let e=$(this).attr("id");history.pushState?history.pushState(null,null,`#${e}`):location.hash=`#${e}`;var t=$(this).siblings(".answer");$(this).hasClass("open")?(t.removeClass("opens").slideUp("fast"),$(this).removeClass("open")):(t.addClass("opens").slideDown("fast"),$(this).addClass("open"))}}));const e=new URL(window.location).hash;if(e){let t=document.querySelector(e);if(!t&&0===e.indexOf("#faq-")){const n=e.slice(1);t=document.getElementById(n)||document.querySelector('[id^="'+n+'-"]')}if(t){$(t).siblings(".answer").addClass("opens").slideDown("fast"),$(t).addClass("open"),t.scrollIntoView({behavior:"smooth",block:"start",inline:"nearest"})}}$(".faq-dropdown-btn").on("click",(function(){let e=$(this).siblings(".faq-dropdown-content");$(this).hasClass("open")?(e.removeClass("opens").slideUp("fast"),$(this).removeClass("open")):(e.addClass("opens").slideDown("fast"),$(this).addClass("open"))})),$(".faq-dropdown-link").on("click",(function(){let e=$(this).closest(".faq-dropdown").children(".faq-dropdown-btn"),t=$(this).closest(".faq-dropdown").children(".faq-dropdown-content");$(e).hasClass("open")?(t.removeClass("opens").slideUp("fast"),$(e).removeClass("open")):(t.addClass("opens").slideDown("fast"),$(e).addClass("open"))})),$(document).on("click",(function(e){var t=$(".faq-dropdown");t.is(e.target)||0!==t.has(e.target).length||$(".faq-dropdown-content").slideUp("fast")}));const t=Array.from(document.querySelectorAll(".faq-main"));if(!t.length)return;const n=e=>{if(!e)return;document.querySelectorAll(".faq-sidebar-linklist .faq-sidebar-link.current").forEach((e=>e.classList.remove("current")));const t=document.querySelector(`.faq-sidebar-linklist [href="#${CSS.escape(e)}"]`);t&&(t.classList.add("current"),t.scrollIntoView({block:"nearest",inline:"nearest"}))},i=()=>{const e=(document.querySelector("header")?.offsetHeight||0)+24;let i=null;var o;t.forEach((t=>{const n=t.querySelector(".faq-section-title");n&&n.getBoundingClientRect().top-e<=0&&(i=n.id)})),i||(o=t[0],i=o?.querySelector(".faq-section-title")?.id),n(i)};let o=!1;const r=()=>{o||(o=!0,window.requestAnimationFrame((()=>{i(),o=!1})))};window.addEventListener("scroll",r,{passive:!0}),window.addEventListener("resize",r),$(document).on("click",".faq-sidebar-link, .faq-dropdown-link",(function(){const e=$(this).attr("href")||"",t="#"===e.charAt(0)?e.slice(1):"";t&&n(t)})),i()}));class shareUrl extends HTMLElement{constructor(){super()}connectedCallback(){this.addEventListener("click",(async()=>{const e=this.dataset.url;await navigator.clipboard.writeText(e),this.querySelector(".copied-tooltip").classList.add("show")})),this.addEventListener("mouseout",(()=>{this.querySelector(".copied-tooltip").classList.remove("show")}))}}function initMainSwatches(e=document){var t=$(e).find(".swatch-element.color"),n=$(e).find(".swatch-element");$.each(n,(function(){$.each($(this).find("input"),(function(){if(!0===$(this).prop("checked")){let e=$(this).val(),t=document.querySelectorAll(`input[type="radio"][value="${e}"]`);t.length>1&&t.forEach((t=>{t.value===e&&t.nextElementSibling.classList.add("selected-color")}))}}))})),$.each(t,(function(){$(this).find("label").on("click",(function(){var e=$
1(this).siblings("input").val();let t=document.querySelectorAll('.swatch-element input[name="color"]');t.length&&t.forEach((e=>{let t=e.closest(".swatch-color-groups-with-title");t&&(t.querySelector(".fabric-option-divider").classList.remove("selected"),t.querySelector(".fabric-option-info").classList.remove("selected")),e.nextElementSibling.classList.remove("selected-color")}));let n=document.querySelectorAll(`input[type="radio"][value="${e}"]`);n.length>0&&n.forEach((t=>{if(t.value===e){let e=t.closest(".swatch-color-groups-with-title");e.querySelector(".fabric-option-divider").classList.add("selected"),e.querySelector(".fabric-option-info").classList.add("selected"),t.nextElementSibling.classList.add("selected-color")}})),$("span.selected_color").text(e),$(".fabric__info-icon").attr("title","More information about "+e)}))}));var i=$(e).find(".size .swatch-element"),o="Small";$.each(i,(function(){$(this).find("label").on("click",(function(){var e=$(this).siblings("input").val();switch(parseInt(e.match(/\d/g).join(""))){case 1824:o="Small";break;case 2432:o="Medium";break;case 3040:o="Large";break;case 3648:o="Extra-Large";break;default:o=e}$("span.selected_size").text(o)}))}
1)),$(window).on("load",(function(){$.each(i,(function(){var e=$(this).find("input");switch(parseInt(e.val().match(/\d/g).join(""))){case 1824:o="Small";break;case 2432:o="Medium";break;case 3040:o="Large";break;case 3648:o="Extra-Large";break;default:o=$size}!0===e.prop("checked")&&$("span.selected_size").text(o)}))}))}function FabricInfoHandler(e=document){function t(e,t=!0){e.classList.add("show"),t&&document.body.classList.add("variant-details-open")}function n(e){e.classList.remove("show"),document.body.classList.remove("variant-details-open")}!function(){const i=e.querySelectorAll(".swatch-element.color label"),o=e.querySelector(".variant-details-wrapper"),r=e.querySelector(".variant-details-wrapper-inner");i.length&&o&&r&&i.forEach((e=>{e.removeEventListener("mouseover",e._fabricMouseOver),e.removeEventListener("mouseout",e._fabricMouseOut),e._fabricMouseOver=()=>{const n=e.parentElement.querySelector(".option-info");n&&""!==n.innerHTML.trim()&&(r.innerHTML=n.innerHTML,t(o,!1))},e._fabricMouseOut=()=>n(o),e.addEventListener("mouseover",e._fabricMouseOver),e.addEventListener("mouseout",e._fabricMouseOut)}))}(),function(){const i=e.querySelectorAll(".fabric-option-info .fabric__info-icon"),o=e.querySelector(".variant-details-close"),r=e.querySelector(".variant-details-wrapper-mobile"),a=e.querySelector(".variant-details-wrapper-mobile-main");i.length&&r&&a&&(i.forEach((n=>{n.removeEventListener("click",n._fabricClick),n._fabricClick=()=>{const n=e.querySelector(".swatch-element input:checked")?.parentElement.querySelector(".option-info");n&&""!==n.innerHTML.trim()&&(a.innerHTML=n.innerHTML,a.scrollTop=0,t(r))},n.addEventListener("click",n._fabricClick)})),o&&(o.removeEventListener("click",o._fabricClose),o._fabricClose=()=>n(r),o.addEventListener("click",o._fabricClose)),window.addEventListener("resize",(()=>n(r))),r.addEventListener("click",(e=>{a.contains(e.target)||n(r)})))}()}function OverlapFixHandler(){function e(){const e=document.querySelector(".product-form"),t=document.querySelector(".variant-details-wrapper");if(e&&t){const n=function(e,t){const n=e.getBoundingClientRect(),i=t.getBoundingClientRect();return Math.max(0,Math.min(n.right,i.right)-Math.max(n.left,i.left))}(e,t);t.style.setProperty("--x-overlap",`${n}px`),t.classList.add("ready")}}document.addEventListener("DOMContentLoaded",e),window.addEventListener("resize",e),window.addEventListener("orientationchange",e)}function StickyActionHandler(){let e=document.querySelector(".product__form--button-wrapper"),t=document.querySelector(".sticky__act--mobile"),n=document.querySelector("#footer-wrapper");null!==e&&null!==t&&window.addEventListener("scroll",(()=>{let i=e.getBoundingClientRect().y,o=n.getBoundingClientRect().top,r=i<0&&o>window.innerHeight;t.classList.toggle("active",r)}))}function TabmakeSameHeight(e){var t,n;t=$(window).width(),n=$(".product-details__accordian--content.opens .product-details__accordian--content--inner").outerHeight()+15;const i=$(".product-details__accordian").outerHeight()-$(".product-details__accordian--content.opens").outerHeight();function o(e){var n,o;return n=$(".product-details__image--inner.active").outerHeight(),e-((o=i+e)>n&&t>980?o-n:0)+"px"}$(".product-details__accordian--content.opens").css("max-height",o(n));let r=$(".product-details__image--inner.active").data("index");e.querySelectorAll(".product-details__accordian--title").forEach((e=>{e.addEventListener("click",(e=>{const t=$(e.currentTarget),n=t.siblings(".product-details__accordian--content"),i=t.hasClass("open");if($(".product-details__accordian--title").removeClass("open"),$(".product-details__accordian--content").css("max-height","0px").removeClass("opens"),!i){const e=n.find(".product-details__accordian--content--inner").outerHeight()+15;t.addClass("open"),n.addClass("opens").css("max-height",o(e))}$(".product-details__image [data-index="+r+"]").removeClass("active");const a=t.data("index");$(".product-details__image [data-index="+a+"]").addClass("active"),r=a}))})),window.addEventListener("tabChange",(e=>{let t,n=e.detail.title.toLowerCase(),i=n.split("/").slice(1).map((e=>e.trim())).join(" "),a=[...document.querySelectorAll(".product-details__accordian--title")],s=a.find((e=>i.includes(e.dataset.id?.toLowerCase())));if(s)t=s;else{let e=i.split(" ");t=a.find((t=>(t.dataset.id?.toLowerCase().split(" ")||[]).some((t=>e.includes(t)))))}if(!t)return;a.forEach((e=>{let n=e.dataset.id?.toLowerCase();if(i.includes(n)||e===t){let t=$(e.nextElementSibling);e.classList.add("open");var a=t.find(".product-details__accordian--content--inner").outerHeight()+15;t.css("max-height",o(a)),$(".product-details__image [data-index="+r+"]").removeClass("active");const n=$(e).data("index");$(".product-details__image [data-index="+n+"]").addClass("active"),r=n}else if(e.classList.contains("open")){let t=$(e.nextElementSibling);e.classList.remove("open"),t.removeClass("opens").css("max-height","0px")}}));let c=[...document.querySelector(".product-details__image--inner.active").querySelectorAll(".product-details__image--single")];if(2===c.length){let e=c.find((e=>n.includes(e.dataset.imageTitle)));
1c.forEach((t=>{t===e?t.classList.add("active"):t.classList.contains("active")&&t.classList.remove("active")}))}}),!1)}function getCookie(e){let t=e+"=",n=decodeURIComponent(document.cookie).split(";");for(let e=0;e<n.length;e++){let i=n[e];for(;" "==i.charAt(0);)i=i.substring(1);if(0==i.indexOf(t))return i.substring(t.length,i.length)}return""}function setStorage(e,t,n=30){const i={value:t,expires:(new Date).getTime()+24*n*60*60*1e3};localStorage.setItem(e,JSON.stringify(i))}function getStorage(e){const t=localStorage.getItem(e);if(!t)return null;const n=JSON.parse(t);return(new Date).getTime()>n.expires?(localStorage.removeItem(e),null):n.value}function initVariantInfo(e){const t=(e||document).querySelectorAll(".variant--info");0!==t.length&&t.forEach((function(e){const t=e.querySelector(".variant-info--icon"),n=e.querySelector(".variant-info-wrapper");t&&n&&(t.addEventListener("mouseover",(function(){n.classList.add("open")})),t.addEventListener("mouseout",(function(){n.classList.contains("open")&&n.classList.remove("open")})))}))}customElements.define("share-url",shareUrl),document.addEventListener("DOMContentLoaded",(function(){$(".sizing_chart_slider").slick({centerMode:!0,autoplay:!1,autoplaySpeed:3e3,centerPadding:"60px",slidesToShow:3,infinite:!0,nextArrow:'<i class="la la-angle-right" aria-hidden="true"></i>',prevArrow:'<i class="la la-angle-left" aria-hidden="true"></i>',responsive:[{breakpoint:576,settings:{centerMode:!0,centerPadding:"20px",slidesToShow:1}}]})})),$(window).on("scroll resize",(function(){if($(window).width()>980){var e=$(".advance_content_section");
1$.each(e,(function(){var e=$(this).closest(".advance_content_section"),t=$(this).position().top,n=$(this).height(),i=$(window).scrollTop()+n;i>t?(e.addClass("focused"),i>t+n&&e.removeClass("focused")):e.removeClass("focused")}))}})),document.addEventListener("DOMContentLoaded",(function(){var e=$("body"),t=$(window);if(e.hasClass("product")){var n=$(".pdpqd_content_wrapper"),i=$(".pdpqd_content"),o=t.width()-n.width(),r=t.height()-n.height(),a=i.width();0!=n.length&&t.on("load scroll resize",(function(){var e=$(this).scrollTop(),t=n.position().top,s=(n.height()-i.height())/2,c=r/2+s,l=o/2,d=t+s-c;if(e>d){var u="rect(0px, auto, "+(i.height()+s-(e-d))+"px, 0px)";i.css({position:"fixed",top:c,right:l,clip:u,width:a,zIndex:1})}else i.removeAttr("style")}))}})),document.addEventListener("DOMContentLoaded",(function(){var e=$(window),t=$("body");if(t.hasClass("collection")||t.hasClass("list-collections")){var n=$(".collection_inner"),i=$(".collection_info");n.width(),i.width(),e.height(),n.height(),$("div#shopify-section-header > header").height();0!=n.length&&$(window).on("load scroll resize",(function(){var e=$
1(this).scrollTop(),t=n.position().top,o=(n.height()-i.height())/2,r=t;if(e>r){var a="rect(0px, auto, "+(i.height()+o-(e-r))+"px, 0px)";i.css({position:"fixed",clip:a,zIndex:1})}else i.removeAttr("style")}))}})),KlaviyoSubscribe.attachToForms("#newsletter_popup",{hide_form_on_success:!0,custom_success_message:!0,extra_properties:{$source:"7th Avenue",$method_type:"7th Avenue form",source:"Popup newsletter"},success:function(e){$(".form_data").hide()}}),KlaviyoSubscribe.attachToForms("#newsletter_popup_footer",{hide_form_on_success:!0,custom_success_message:!0,extra_properties:{$source:"7th Avenue",$method_type:"7th Avenue newsletter form",source:"Footer newsletter"},success:function(e){$(".footer_form_data").hide()}}),document.addEventListener("DOMContentLoaded",(function(){var e=$(".home_image_slider")||null;if(e){let n=e.data("autoplaySpeed");var t=$(".home_image_slider").not(".slick-initialized").slick({autoplay:!0,autoplaySpeed:n,adaptiveHeight:!0,cssEase:"ease",slidesToShow:1,slidesToScroll:1,infinite:!0,nextArrow:'<a class="slick-next slick-arrow"><i class="la la-angle-right" aria-hidden="true"></i></a>',prevArrow:'<a class="slick-prev slick-arrow"><i class="la la-angle-left" aria-hidden="true"></i></a>'});$(window).resize((function(){t.slick("resize")}))}})),document.addEventListener("themeJSFastLoaded",(function(){if($(".customer_testimonials_slider")||null)var e=$(".customer_testimonials_slider").bxSlider({speed:800,pause:7500,tickerHover:!1,adaptiveHeight:!0,prevText:'<i class="la la-angle-left" aria-hidden="true"></i>',nextText:'<i class="la la-angle-right" aria-hidden="true"></i>',slideWidth:1200,moveSlides:1,pager:!0,auto:!0,onSlideBefore:function(){e.stopAuto(),e.startAuto()},onSlideAfter:function(){e.stopAuto(),e.startAuto()}})})),function(){function e(e){const t=decodeURIComponent(String(e).replace(/\+/g," ")).trim();return(t.includes("_")?t.split("_").pop():t).toLowerCase().replace(/\s+/g,"-")}function t(e,t){const n=[e.dataset.option1,e.dataset.option2,e.dataset.option3].filter(Boolean);return t.every((e=>n.some((t=>t===e||t.includes(e)||e.includes(t)))))}function n(n){const i=n?.detail?.searchParams??null;document.querySelectorAll(".product-index").forEach((n=>{try{const c=Array.from(n.querySelectorAll(".color__swatch li")),l=n.querySelector(".color__swatch--container ul"),d=n.querySelector(".price__container");let u=n.querySelector(".reveal .variant__image.open");if(!c.length||!u)return;let p=n.querySelector(".color__swatch li.open"),h={option1:u.dataset.option1||"",option2:u.dataset.option2||"",option3:u.dataset.option3||""};function o(e){e&&(h={option1:e.dataset.option1||"",option2:e.dataset.option2||"",option3:e.dataset.option3||""})}function r(e,t){if(!e)return;const{variantId:i,variantUrl:o}=e.dataset;n.querySelectorAll("a").forEach((e=>{const t=new URL(o,window.location.origin);t.searchParams.set("variant",i),e.href=t.toString()}))}function a(e,t){if(!e)return;const n=e.dataset.imageRatio||"",i=e.dataset.imageSizes||"",o=e.dataset.imageAlt||"";function r(t,r,a){if(!t||!r||t.querySelector("img"))return;let s=t.classList.contains("box-ratio")?t:t.querySelector(".box-ratio");s?n&&!s.style.paddingBottom&&(s.style.paddingBottom=n):(s=document.createElement("div"),s.className="box-ratio",s.style.paddingBottom=n||"",t.appendChild(s));const c=document.createElement("img");c.className="lazyload-fade lazyloaded",c.loading="lazy",c.decoding="async",c.alt=o,e.dataset.imageWidth&&(c.width=e.dataset.imageWidth),e.dataset.imageHeight&&(c.height=e.dataset.imageHeight),i&&(c.sizes=i),c.src=r,a&&(c.srcset=a),s.appendChild(c)}"true"===e.dataset.lazyVariantImage&&(r(e.querySelector(".product-featured-image .variant-image-placeholder")||e.querySelector(".variant-image-placeholder"),e.dataset.imageSrc,e.dataset.imageSrcset),delete e.dataset.lazyVariantImage),"true"===e.dataset.lazyDualImage&&t?.loadSecondary&&r(function(){const t=e.querySelector(".variant-featured-image");return t?.querySelector(".variant-secondary-placeholder")||t}(),e.dataset.secondaryImageSrc,e.dataset.secondaryImageSrcset)}function s(e,t){if(!e)return;const i=parseInt(e.dataset.position,10),s=e.dataset.optionName,c=n.querySelector(".variant__image.open"),d=function(e,t){const i={1:`[data-option1="${t}"]`,2:`[data-option2="${t}"]`,3:`[data-option3="${t}"]`}[e];return n.querySelector(`.variant__image${i}[data-option2="${h.option2}"][data-option3="${h.option3}"]`)||n.querySelector(`.variant__image${i}[data-option2="${h.option2}"]`)||n.querySelector(`.variant__image${i}[data-option3="${h.option3}"]`)||n.querySelector(`.variant__image${i}`)}(i,s);if(!d)return;if(a(d,{loadSecondary:t}),c?.classList.remove("open"),d.classList.add("open"),o(d),t){const e=d.querySelector(".variant-featured-image"),t=d.querySelector(".product-featured-image");e&&e.classList.contains("hidden")&&e.classList.remove("hidden"),e&&t&&t.classList.add("hidden")}r(d,t),p&&n.querySelectorAll(`li.open[data-option-name="${p.dataset.optionName}"]`).forEach((t=>{t.isSameNode(e)||t.classList.remove("open")}));const u=n.querySelectorAll(`li[data-option-name="${e.dataset.optionName}"]`);u.length>1?u.forEach((e=>{t&&e.classList.contains("deselect")&&e.classList.remove("deselect");let n=e.closest(".slick-slide");if(n&&!n.classList.contains("slick-cloned"))if(e.classList.add("open"),t){const e=parseInt(n.dataset.slickIndex,10);isNaN(e)||$(l).slick("slickGoTo",e)}else $(l).slick("slickGoTo",0)})):(e.classList.add("open"),t&&e.classList.contains("deselect")&&e.classList.remove("deselect")),p=e}let f=p&&!p.classList.contains("deselect");if(!function(){const e=i?new URLSearchParams(i):new URLSearchParams(window.location.search);for(const t of e.keys())if(t.startsWith("filter."))return!0;return!1}()?s(p,f):(!function(){const s=function(t){const n=t?new URLSearchParams(t):new URLSearchParams(window.location.search),i=[];
1for(const[t,o]of n.entries())(t.startsWith("filter.v.option.")||t.startsWith("filter.p.option."))&&i.push(e(o));return i}(i),l=function(e,n){if(!n.length)return null;for(const i of e.querySelectorAll(".reveal .variant__image"))if(t(i,n))return i;return null}(n,s)||u;var d;(d=l)&&(n.querySelectorAll(".reveal .variant__image.open").forEach((e=>{e.isSameNode(d)||e.classList.remove("open")})),d.classList.add("open"),o(d)),u=l,function(e){if(!e)return;a(e,{loadSecondary:!0});const t=e.querySelector(".variant-featured-image"),n=e.querySelector(".product-featured-image");t&&t.classList.contains("hidden")&&t.classList.remove("hidden"),t&&n&&n.classList.add("hidden")}(l),r(l,!0),function(e){if(!e)return;const t=c.find((t=>{const n=parseInt(t.dataset.position,10);return!Number.isNaN(n)&&t.dataset.optionName===e.dataset[`option${n}`]}));t&&(c.forEach((e=>{e.isSameNode(t)||e.classList.remove("open")})),t.classList.add("open"),t.classList.remove("deselect"),p=t)}(l)}(),f=!0),"true"===n.dataset.swatchClickBound)return;n.dataset.swatchClickBound="true",n.addEventListener("click",(e=>{const t=e.target.closest(".color__swatch li");t&&s(t,f=!0)}))}catch(e){}}))}n(),window.addEventListener("filterFormSubmit",n),subscribe(PUB_SUB_EVENTS.infiniteScrollHappen,n)}(),function(){function e(e){if(!e)return"";const t=e.match(/^\d+_(.*)/);let n=t?t[1]:e;return n=n.replace(/\(([^)]+)\)/g," $1"),n.replace(/\s+/g,"-").toLowerCase()}subscribe(PUB_SUB_EVENTS.collectionProductChange,debounce((({data:t})=>{!function(t){const n=getCookie("selected_color")?JSON.parse(getCookie("selected_color")):[];if(0===n.length)return;const i=e(n[0]);t.forEach((t=>{n.length>1&&function(t,n){n.forEach(((n,i)=>{let o=e(n);t.querySelectorAll("li").forEach((e=>{e.dataset.optionName.includes(o)&&e.style.setProperty("--order",i+1)}))}))}(t,n);const o=t.querySelector(`.color__swatch [data-option-name="${i}"]`);o&&!o.classList.contains("open")&&o.click()}))}(t)}),150))}(),$((function(){const e=document.querySelector(".strip__buy-button"),t=document.querySelector(".product__form--button-wrapper");if(null==e)return;new IntersectionObserver((t=>{t[0].intersectionRatio<=0?e.style.display="block":e.style.display="none"})).observe(t)})),window.addEventListener("DOMContentLoaded",(function(){FabricInfoHandler(),OverlapFixHandler(),StickyActionHandler(),TabmakeSameHeight(document)})),$('.custom-gallery__grid [data-fancybox="custom-gallery"]').fancybox({loop:!0,transitionDuration:100,animationDuration:500,buttons:["close"]}),(()=>{let e=document.querySelectorAll(".help-desk__btn.reamaze__open");e.length<=0||(e.forEach((e=>{e.addEventListener("click",(e=>{e.preventDefault(),GorgiasChat.open()}))})),$('[data-fancybox="help-desk"]').fancybox({loop:!0,transitionDuration:100,animationDuration:500,animationEffect:"fade",buttons:["close"]}))})(),(()=>{function e(){var e=document.querySelector(".pdp-sofa-compare__table--mobile");if(null!==e)for(var t=1;t<=14;t++){var n=`.table__row--${t}`,i=e.querySelectorAll(n),o=0;i.forEach((function(e){e.clientHeight>o&&(o=e.clientHeight)})),i.forEach((function(e){e.style.height=`${o}px`}))}}function t(){window.addEventListener("scroll",(function(){var e=document.querySelector(".scrollheader").clientHeight,t=document.querySelector(".pdp-sofa-compare__table--header");if(null!==t){var n=t.clientWidth,i=t.clientHeight,o=document.querySelector(".pdp-sofa-compare__table"),r=o.getBoundingClientRect().top,a=(o.getBoundingClientRect().top,o.clientHeight,document.querySelector(".pdp-sofa-compare__table--row.table__last--row").getBoundingClientRect().top);r<e?(t.classList.add("sticky"),t.style.cssText=`width:${n}px; top:${e}px;`,o.style.paddingTop=i+"px"):(t.classList.remove("sticky"),t.style.cssText="width:100%; top:unset;",o.style.paddingTop=0),a<i+e?t.classList.add("hide"):t.classList.remove("hide")}}))}window.addEventListener("DOMContentLoaded",(function(){e(),t()})),window.addEventListener("resize",(function(){e(),t()}))})(),document.querySelectorAll(".collection__review").forEach((e=>{var t=e.dataset.sectionId,n=document.querySelector(`.collection__review--${t} .collection__review--slider`),i=parseInt(e.dataset.speed);$(n).slick({infinite:!0,autoplay:!0,autoplaySpeed:i,speed:300,slidesToShow:7,slidesToScroll:1,prevArrow:$(".slider__controller--prev"),nextArrow:$(".slider__controller--next"),responsive:[{breakpoint:3420,settings:{slidesToShow:6}},{breakpoint:2820,settings:{slidesToShow:5}},{breakpoint:2220,settings:{slidesToShow:4}},{breakpoint:1920,settings:{slidesToShow:3}},{breakpoint:740,settings:{slidesToShow:2}},{breakpoint:480,settings:{slidesToShow:1,slidesToScroll:1}}]}),$(".collection__review .slick-slide:not(.slick-cloned) [data-fancybox]").fancybox({loop:!0,transitionDuration:100,animationDuration:500,animationEffect:"fade",buttons:["close"]})})),document.querySelectorAll(".sofa-page-feature-product").forEach((e=>{const t=`.sofa-page-feature-product__${e.dataset.sectionId}`,n=document.querySelector(`${t}
1 .sofa-page-feature-product-slider`);if(!n)return;const i=document.querySelector(`${t} .slider__controller--prev`),o=document.querySelector(`${t} .slider__controller--next`),r=document.querySelectorAll(`${t} .color__swatch`),a=()=>{$(n).hasClass("slick-initialized")||$(n).slick({infinite:!0,speed:300,slidesToShow:7,slidesToScroll:1,prevArrow:$(i),nextArrow:$(o),responsive:[{breakpoint:3420,settings:{slidesToShow:6}},{breakpoint:2820,settings:{slidesToShow:5}},{breakpoint:2220,settings:{slidesToShow:4}},{breakpoint:1920,settings:{slidesToShow:3}}]})},s=()=>{$(n).hasClass("slick-initialized")&&($(n).slick("slickSetOption","draggable",!1,!1),$(n).slick("slickSetOption","swipe",!1,!1),$(n).slick("slickPause"))},c=()=>{$(n).hasClass("slick-initialized")&&($(n).slick("slickSetOption","draggable",!0,!1),$(n).slick("slickSetOption","swipe",!0,!1))};Events.on("mediaquery:desktop",a),Events.on("mediaquery:tablet",a),Events.on("mediaquery:mobile",(()=>{$(n).hasClass("slick-initialized")&&$(n).slick("unslick")})),r.forEach((e=>{e.addEventListener("mouseenter",s),e.addEventListener("mouseleave",c),e.addEventListener("touchstart",s,{passive:!1}),e.addEventListener("touchend",c)}))})),(()=>{function e(){var e=window.innerHeight||document.documentElement.clientHeight||document.body.clientHeight,t=document.querySelector("#navigation").offsetHeight;document.querySelectorAll(".product-special-feature__video video").forEach((function(n){var i=n.offsetHeight,o=n.getBoundingClientRect().top;n&&o+i/2<t||o+i/2>e?n.pause():n.play()}))}function t(){var e=window.innerWidth||document.documentElement.clientWidth||document.body.clientWidth,t=document.querySelector("#navigation").offsetHeight,n=document.querySelectorAll(".product-special-feature__container");window.addEventListener("resize",(function(){e=window.innerWidth||document.documentElement.clientWidth||document.body.clientWidth})),window.addEventListener("scroll",(function(){var i,o,r,a,s,c,l,d,u;n.forEach((function(n){i=n.offsetHeight,o=n.getBoundingClientRect().top,r=n.getBoundingClientRect().bottom,a=n.querySelector(".product-special-feature__content--inner"),s=a.offsetHeight,c=a.getBoundingClientRect().top,l=a.getBoundingClientRect().bottom,contentBlankSpace=i-s,d=e-(n.getBoundingClientRect().right+(window.innerWidth-document.documentElement.clientWidth)),o<t&&e>751?(u=r<l?`${r-l+s}px`:"auto",a.style.cssText=`position: fixed; top: ${c}px; right: ${d}px; clip: rect(0px,auto, ${u},0px)`):a.removeAttribute("style")}))}))}e(),window.addEventListener("scroll",e),document.body.addEventListener("touchstart",e),t(),window.addEventListener("resize",(function(){t()}))})(),$(window).on("scroll resize",(function(){if($(window).width()>980){var e=$(".pdp-advanced-content__row");
1$.each(e,(function(){var e=$(this).closest(".pdp-advanced-content__row"),t=$(this).position().top,n=$(this).height(),i=$(window).scrollTop()+n;i>t?(e.addClass("focused"),i>t+n&&e.removeClass("focused")):e.removeClass("focused")}))}})),document.body.addEventListener("touchstart",(function(){let e=document.querySelectorAll(".pdp-advanced-content__image video");e.length<=0||e.forEach((function(e){e.play()}))})),initVariantInfo(),document.querySelectorAll(".feature-in").forEach((e=>{const t=e.querySelector(".grid_wrapper");if(!t||0===t.children.length)return;if($(t).hasClass("slick-initialized"))return;const n={mobileFirst:!0,infinite:!0,autoplay:!0,autoplaySpeed:5e3,speed:300,slidesToShow:1,slidesToScroll:1,prevArrow:$(e).find(".slider__controller--prev"),nextArrow:$(e).find(".slider__controller--next"),responsive:[{breakpoint:600,settings:{slidesToShow:2,slidesToScroll:1}},{breakpoint:740,settings:{slidesToShow:3,slidesToScroll:1}}]};$(t).slick(n),$(window).on("resize",(function(){$(window).width()>740||$(t).hasClass("slick-initialized")||$(t).slick(n)}))})),document.querySelectorAll(".image-with-text__btn").forEach((function(e){let t=e.href;t.includes("calendly")&&e.addEventListener("click",(function(e){e.preventDefault(),Calendly.initPopupWidget({url:t})}))}));let handleAffirmClick=null;function initFinancePopups(){const e=document.querySelector(".affirm__button.affirm-popup-opener"),t=document.querySelector(".finance-logo-affirm.affirm-popup-opener");document.querySelector(".affirm-osm")&&(handleAffirmClick||(handleAffirmClick=()=>{const e=document.querySelector(".affirm-osm .affirm-modal-trigger");e&&e.click()}),t&&(t.removeEventListener("click",handleAffirmClick),t.addEventListener("click",handleAffirmClick)),e&&(e.removeEventListener("click",handleAffirmClick),e.addEventListener("click",handleAffirmClick)))}let handleShopPayClick=null;function initShopPayPopups(e){const t=e||document;if(!t.querySelector("shopify-payment-terms"))return;handleShopPayClick||(handleShopPayClick=()=>{const e=t.querySelector("shopify-payment-terms");if(!e)return;const n=e.shadowRoot;if(!n)return;const i=n.querySelector("#shopify-installments-cta");i&&i.click()});const n=document.querySelector(".affirm__button.shoppay-popup-opener"),i=document.querySelector(".finance-logo-shoppay.shoppay-popup-opener");n&&(n.removeEventListener("click",handleShopPayClick),n.addEventListener("click",handleShopPayClick)),i&&(i.removeEventListener("click",handleShopPayClick),i.addEventListener("click",handleShopPayClick))}function initLearnMoreLink(e){const t=setInterval((()=>{const n=e?.querySelector("a");function i(t){t.preventDefault();const n=e.dataset.section;if(!n)return;const i=document.querySelector(n);i&&i.scrollIntoView({behavior:"smooth",block:"start"})}n&&(clearInterval(t),n.removeEventListener("click",i),n.addEventListener("click",i))}),100)}function initExpandableText(){const e=document.querySelectorAll(".expandable_container");e.length&&e.forEach((e=>{const t=e.querySelector(".expand");e.querySelector(".read-more");window.addEventListener("click",(n=>{n.target.classList.contains("read-more")&&(e.classList.toggle("expanded"),e.classList.contains("expanded")?t.innerHTML='<span class="read-more">Read less</span>':t.innerHTML='... <span class="read-more">Read more</span>')}))}))}function TypewriterHandler(e=document){class t{constructor(e,t,n){this.toRotate=t,this.el=e,this.loopNum=0,this.period=parseInt(n,10)||2e3,this.txt="",this.isDeleting=!1,this.tick()}tick(){if(!this.el)return;let e=this.el.querySelector(".wrap");e||(e=document.createElement("span"),e.className="wrap",this.el.appendChild(e));const t=this.loopNum%this.toRotate.length,n=this.toRotate[t];this.txt=this.isDeleting?n.substring(0,this.txt.length-1):n.substring(0,this.txt.length+1),e.innerText=this.txt;let i=200-100*Math.random();this.isDeleting&&(i/=3),this.isDeleting||this.txt!==n?this.isDeleting&&""===this.txt&&(this.isDeleting=!1,this.loopNum++,i=500):(i=this.period,this.isDeleting=!0),setTimeout((()=>this.tick()),i)}}!function(){const n=e.getElementsByClassName("typewrite");if(n&&0!==n.length)for(let e=0;e<n.length;e++){const i=n[e].getAttribute("data-type"),o=n[e].getAttribute("data-period");i&&new t(n[e],JSON.parse(i),o)}}()}initShopPayPopups(document),initExpandableText(),TypewriterHandler(),document.addEventListener("DOMContentLoaded",(function(){const e=document.querySelector(".product-recommendations");
1if(null==e)return;let t,n,i;function o(e){t=e.querySelector(".sofa-page-feature-product-slider"),n=e.querySelectorAll(".product-index"),i=e.querySelectorAll(".product-index"),function(e){function t(){window.matchMedia("(min-width: 741px)").matches&&$(e).not(".slick-initialized").slick({infinite:!0,speed:300,slidesToShow:3,slidesToScroll:1,prevArrow:$(".product-recommendations .slider__controller--prev"),nextArrow:$(".product-recommendations .slider__controller--next")}),window.matchMedia("(max-width: 740px)").matches&&$(e).hasClass("slick-initialized")&&$(e).slick("unslick")}function n(){$(e).not(".slick-initialized").slick({infinite:!0,speed:300,slidesToShow:3,slidesToScroll:1,prevArrow:$(".product-recommendations .slider__controller--prev"),nextArrow:$(".product-recommendations .slider__controller--next")})}function i(){$(e).hasClass("slick-initialized")&&$(e).slick("unslick")}return Events.on("mediaquery:desktop",(function(){n()})),Events.on("mediaquery:tablet",(function(){n()})),Events.on("mediaquery:mobile",(function(){i()})),t}(t)(),function(e){function t(){e.length>0&&e.forEach((e=>{e.querySelectorAll(".color__swatch li").forEach((e=>{let t=e.dataset.optionName.toString().replace(/-/g,"_");void 0!==colorDetails[t]&&void 0!==colorDetails[t].thumbnail&&(e.querySelector(".color__swatch--bg").style.backgroundImage=`url(${colorDetails[t].thumbnail})`)}))}))}return t}(n)(),function(e){e.forEach((function(e){var t=e.querySelectorAll(".color__swatch li"),n=e.querySelector(".color__swatch li.open"),i=e.querySelectorAll("a"),o=e.querySelector(".price__container .variant__price"),r=e.querySelector(".price__container .monthly__price");t.forEach((function(t,a){t.addEventListener("click",(function(t){var a,s=e.querySelector(".variant__image.open"),c=s.dataset.option1,l=s.dataset.option2,d=s.dataset.option3,u=parseInt(t.currentTarget.dataset.position);if(1==u&&(a=e.querySelector(`.variant__image[data-option1="${t.currentTarget.dataset.optionName}"][data-option2=${l}][data-option3="${d}"]`)),2==u&&(a=e.querySelector(`.variant__image[data-option2="${t.currentTarget.dataset.optionName}"][data-option1=${c}][data-option3="${d}"]`)),3==u&&(a=e.querySelector(`.variant__image[data-option3="${t.currentTarget.dataset.optionName}"][data-option1=${c}][data-option2="${l}"]`)),s!==a){var p,h,f,m;a.classList.contains("open")||a.classList.add("open"),a.classList.contains("open")&&s.classList.remove("open"),p=a.dataset.variantId,h=a.dataset.variantUrl,f=a.dataset.variantPrice,m=a.dataset.monthlyPrice;var v=h.split("?")[1];const e=new URLSearchParams(v);e.set("variant",p);var g=h.split("?")[0]+"?"+e.toString();i.forEach((function(e){e.href=g})),null!=f&&null!=o&&(o.innerText=f),null!=m&&null!=r&&(r.innerText=m)}n.classList.contains("open")&&n.classList.remove("open"),t.currentTarget.classList.add("open"),n=t.currentTarget}))}))}))}(i)}function r(){if("true"===e.dataset.recommendationsLoaded)return;e.dataset.recommendationsLoaded="true";const t=e.dataset.url;t&&fetch(t).then((e=>e.text())).then((t=>{const n=document.createElement("div");n.innerHTML=t;const i=n.querySelector(".product-recommendations");
1i&&i.innerHTML.trim().length&&(e.innerHTML=i.innerHTML),o(e)})).catch((t=>{e.dataset.recommendationsLoaded=""}))}if(e.querySelector(".sofa-page-feature-product-slider"))o(e);else if("IntersectionObserver"in window){const t=new IntersectionObserver((e=>{e[0].isIntersecting&&(t.disconnect(),r())}),{rootMargin:"200px 0px"});t.observe(e)}else r()})),$(".relavant-article-slider").not(".slick-initialized").slick({infinite:!1,speed:300,slidesToShow:3,slidesToScroll:1,prevArrow:$(".relevant-article-prev"),nextArrow:$(".relevant-article-next"),responsive:[{breakpoint:740,settings:{slidesToShow:2}}]}),$(document).ready((function(){const e=$(window),t=$(document),n=$(".reading-progress-indicator progress"),i=()=>$(".article.article-main").height(),o=()=>e.scrollTop()>i()?i():e.scrollTop();n&&(n.attr({value:o(),max:i()}),t.on("scroll",(()=>{n.attr({value:o()})})),e.on("resize",(()=>{n.attr({value:o(),max:i()})})))}));class TabContainer extends HTMLElement{constructor(){super(),this.addEventListener("click",this.clickHandler.bind(this)),this.addEventListener("keydown",this.KeyDownHandler.bind(this)),this.activeButton=this.querySelector('[role="tablist"] a[aria-selected="true"]'),this.tabButtons=this.querySelectorAll('[role="tablist"] a'),this.tabPanels=this.querySelectorAll(".tabs__panels > div"),this.tabListContainer=this.querySelector(".product-tabs-tablist-container"),this.tabIndicator=this.querySelector(".product-tab-indicator"),document.addEventListener("DOMContentLoaded",this.updateTabIndicator(this.activeButton)),this.makeScrollable()}updateTabIndicator(e){const t=e.offsetLeft,n=e.offsetWidth;this.tabIndicator.style.cssText=`\n width: ${n}px; \n left: ${t}px;\n `,this.scrollToCenter(e)}scrollToCenter(e){Array.from(this.tabButtons).indexOf(e);const t=this.tabListContainer.offsetWidth,n=e.offsetWidth,i=this.tabListContainer.getBoundingClientRect().left,o=e.getBoundingClientRect().left-i-(t-n)/2;this.tabListContainer.scrollTo({left:this.tabListContainer.scrollLeft+o,behavior:"smooth"})}makeScrollable(){let e,t,n=this.tabListContainer.clientWidth<this.tabListContainer.scrollWidth,i=!1;n&&(this.tabListContainer.addEventListener("mousedown",(n=>{i=!0,this.tabListContainer.classList.add("slider-ready"),e=n.pageX-this.tabListContainer.offsetLeft,t=this.tabListContainer.scrollLeft})),this.tabListContainer.addEventListener("mouseleave",(()=>{i=!1,this.tabListContainer.classList.remove("slider-ready"),this.tabListContainer.classList.remove("slider-scrolling")})),this.tabListContainer.addEventListener("mouseup",(()=>{i=!1,this.tabListContainer.classList.remove("slider-ready"),this.tabListContainer.classList.remove("slider-scrolling")})),this.tabListContainer.addEventListener("mousemove",(n=>{if(!i)return;n.preventDefault(),this.tabListContainer.classList.add("slider-scrolling");const o=3*(n.pageX-this.tabListContainer.offsetLeft-e);this.tabListContainer.scrollLeft=t-o})))}clickHandler(e){const t=e.target.closest("a");t&&(e.preventDefault(),this.switchTab(t))}KeyDownHandler(e){switch(e.key){case"ArrowLeft":this.moveLeft();break;case"ArrowRight":this.moveRight();break;case"Home":e.preventDefault(),this.switchTab(this.tabButtons[0]);break;case"End":e.preventDefault(),this.switchTab(this.tabButtons[this.tabButtons.length-1]);break}}moveLeft(){const e=this.querySelector(":focus");e.parentElement.previousElementSibling?this.switchTab(e.parentElement.previousElementSibling.querySelector("a")):this.switchTab(this.tabButtons[this.tabButtons.length-1])}moveRight(){const e=this.querySelector(":focus");e.parentElement.nextElementSibling?this.switchTab(e.parentElement.nextElementSibling.querySelector("a")):this.switchTab(this.tabButtons[0])}switchTab(e){const t=e.getAttribute("href"),n=this.querySelector(t);this.tabButtons.forEach((e=>{e.setAttribute("aria-selected",!1),e.setAttribute("tabindex","-1")})),this.tabPanels.forEach((e=>{e.setAttribute("hidden",!0)})),n.removeAttribute("hidden",!1),e.setAttribute("aria-selected",!0),e.setAttribute("tabindex","0"),e.focus(),this.updateTabIndicator(e)}}customElements.define("tab-container",TabContainer);class productInfoSlider extends HTMLElement{constructor(){super(),this.addEventListener("click",this.clickHandler.bind(this)),this.titleListContainer=this.querySelector(".product-info-titles-container"),this.contentList=this.querySelector(".product-info-contents"),this.tabIndicator=this.querySelector(".product-tab-indicator"),this.contentSlider(this.contentList),this.makeScrollable()}clickHandler(e){const t=e.target.closest("li[role=presentation]");t&&(e.preventDefault(),this.switchTab(t))}makeScrollable(){let e,t,n=this.titleListContainer.clientWidth<this.titleListContainer.scrollWidth,i=!1;n&&(this.titleListContainer.addEventListener("mousedown",(n=>{i=!0,this.titleListContainer.classList.add("slider-ready"),e=n.pageX-this.titleListContainer.offsetLeft,t=this.titleListContainer.scrollLeft})),this.titleListContainer.addEventListener("mouseleave",(()=>{i=!1,this.titleListContainer.classList.remove("slider-ready"),this.titleListContainer.classList.remove("slider-scrolling")})),this.titleListContainer.addEventListener("mouseup",(()=>{i=!1,this.titleListContainer.classList.remove("slider-ready"),this.titleListContainer.classList.remove("slider-scrolling")})),this.titleListContainer.addEventListener("mousemove",(n=>{if(!i)return;n.preventDefault(),this.titleListContainer.classList.add("slider-scrolling");const o=3*(n.pageX-this.titleListContainer.offsetLeft-e);this.titleListContainer.scrollLeft=t-o})))}updateTabIndicator(e){const t=e.offsetLeft,n=e.offsetWidth;this.tabIndicator.style.cssText=`width: ${n}px; left: ${t}px;`,this.scrollToCenter(e)}switchTab(e){const t=e.getAttribute("id"),n=this.querySelector(`[data-id="${t}"]`).closest(".slick-slide").dataset.slickIndex;$(this.contentList).slick("slickGoTo",n)}updateCurrentTitle(e){const t=document.querySelector(`.product-info-titles #${e}`);this.updateTabIndicator(t)}scrollToCenter(e){const t=this.titleListContainer.offsetWidth,n=e.offsetWidth,i=this.titleListContainer.getBoundingClientRect().left,o=e.getBoundingClientRect().left-i-(t-n)/2;this.titleListContainer.scrollTo({left:this.titleListContainer.scrollLeft+o,behavior:"smooth"})}contentSlider(e){const t=this;$(e).slick({draggable:!0,accessibility:!1,centerMode:!1,slidesToShow:1,arrows:!1,dots:!1,swipeToSlide:!0,infinite:!0,adaptiveHeight:!0,mobileFirst:!0,responsive:[{breakpoint:980,settings:{draggable:!1}}]});const n=this.querySelector(`[data-slick-index="${$(e).slick("slickCurrentSlide")}"]`).querySelector(".product-info-content").dataset.id;this.updateCurrentTitle(n),$(e).on("afterChange",(function(e,n,i){let o=n.$slides[i].querySelector(".product-info-content").dataset.id,r=t.querySelector(`.product-info-titles #${o}`);t.updateCurrentTitle(o),t.updateTabIndicator(r)}))}}function initOkendoReviewHandling(){function e(){let e=document.querySelector("#product-reviews");if(e){let t,r=!1;const a=(e,a)=>{r&&clearTimeout(t),r=!0,t=setTimeout((()=>{const e=document.querySelector("#filter-toggle.oke-w-reviews-filterToggle");let t=document.querySelector('[data-filter-review-with-variant="true"]');e&&(a.disconnect(),function(e){return new Promise(((t,n)=>{if(!e)return n("No filterToggle found");let i=e.getAttribute("aria-expanded");if("false"===i){e.click();const n=new MutationObserver((()=>{i=e.getAttribute("aria-expanded"),"true"===i&&(e.click(),n.disconnect(),t())}));n.observe(e,{attributes:!0,attributeFilter:["aria-expanded"]})}else"true"===i&&(e.click(),t())}))}(e).then((()=>function(){const e=document.querySelector(".oke-w-reviews-head .oke-w-reviews-filterToggle .oke-button-text");e&&(e.textContent=e.textContent.replace("Filters","Filter by Color"));document.querySelectorAll(".oke-w-filter-title").forEach((e=>{const t=e.childNodes[0];t&&t.nodeType===Node.TEXT_NODE&&(t.textContent.includes("Rating")&&e.closest(".oke-w-filter").setAttribute("hidden",!0),t.textContent.includes("Color")&&e.setAttribute("hidden",!0))}))}())).then((()=>function(){const e=document.querySelector("#filter-options");e&&(e.style.display="block");const t=document.querySelector("#filter-toggle");t&&(t.style.display="inline-block")}())).then((()=>{t&&function(){const e=document.querySelectorAll('.oke-w-filter-options input[name="Color"]'),t=Array.from(e).map((e=>e.value));window.addEventListener("reviewChange",(r=>{const a=document.querySelector("#filter-toggle.oke-w-reviews-filterToggle"),s=n(r.detail.title,t);o(a).then((()=>i(s,e))).catch((e=>{}))}))}()})).then((()=>{const e=new URLSearchParams(window.location.search),t=e.get("scrollToSection"),r=e.get("variant");t&&function(e,t,r){const a=document.querySelector("#filter-toggle.oke-w-reviews-filterToggle");if(document.querySelector('[data-filter-review-with-variant="true"]')&&e&&t){const e=document.querySelector("[data-current-variant]").dataset.currentVariant,t=document.querySelectorAll('.oke-w-filter-options input[name="Color"]'),r=n(e,Array.from(t).map((e=>e.value)));o(a).then((()=>i(r,t))).catch((e=>{}))}if(e){const t=document.getElementById(e);if(t){t.scrollIntoView({behavior:"smooth"}),r.delete("scrollToSection");const e=window.location.pathname+"?"+r.toString();window.history.replaceState({},"",e)}}}(t,r,e)}
1)).catch((e=>{}))),r=!1}),2e3)},s={childList:!0,attributes:!0,subtree:!0};new MutationObserver(a).observe(e,s)}}const t=["Velvet","Outdoor"];function n(e,n){const i=function(e){return e.replace(/\s*\(.*?\)/g,"").split("/")[0].trim()}(e);return function(e,n){for(const t of n)if(e===t)return t;for(const i of t){const t=e.replace(`${i} `,"").trim();for(const e of n)if(t===e||t===e.replace(`${i} `,""))return e}return e}(i,n)}function i(e,t){const n=document.querySelector(`.oke-w-filter-options input[name="Color"][value="${e}"]`);if(t.forEach((e=>{e.checked&&e.nextElementSibling.click()})),n){n.setAttribute("inert","true");const e=document.querySelector(`label[for="${n.id}"]`);e&&e.click()}}function o(e){return new Promise(((t,n)=>{if(!e)return n("No filterToggle found");let i=e.getAttribute("aria-expanded");if("false"===i){e.click();const n=new MutationObserver((()=>{i=e.getAttribute("aria-expanded"),"true"===i&&(n.disconnect(),t())}));n.observe(e,{attributes:!0,attributeFilter:["aria-expanded"]})}else"true"===i&&t()}))}document.addEventListener("oke-rendered",(t=>{"reviews-widget"===t.detail.widget&&e()}))}function initStickySection(){const e=new URLSearchParams(window.location.search).get("scrollToSection"),t=document.querySelector("#product-content .product-photos"),n=document.querySelector("#sticky-container");if(!t||!n)return;const i=()=>{const e=document.querySelector("header")?.clientHeight||0,n=window.innerWidth>1024&&t.clientHeight+e>(window.visualViewport?.height??window.innerHeight);t.classList.toggle("bottom-sticky",n)},o=()=>{n.removeAttribute("style"),i(),"undefined"!=typeof $&&$("#sticky-container").length&&$("#sticky-container").trigger("sticky_kit:recalc")},r=()=>{o(),window.addEventListener("resize",o),window.addEventListener("orientationchange",o),window.visualViewport&&(window.visualViewport.addEventListener("resize",o),window.visualViewport.addEventListener("scroll",o))};if(e){const e=setInterval((()=>{window.location.search.includes("scrollToSection")||(clearInterval(e),r())}),500)}else{const e=setInterval((()=>{clearInterval(e),r()}),500)}}customElements.define("product-info-slider",productInfoSlider),(()=>{function e(){const e=document.querySelector(".homepage-section.slideshow-section"),t=document.querySelector(".mobile_hero_image");if(t){const n=t.getBoundingClientRect().height;e.style.cssText=`\n --top: ${n/2}px;\n `}}e(),window.addEventListener("resize",e)})(),function(){let e=document.querySelector(".color-swatch-tab-titles .color-swatch-tab-title.active");const t=document.querySelectorAll(".color-swatch-tab-titles .color-swatch-tab-title");t.forEach((n=>{n.addEventListener("click",(n=>{if(n.preventDefault(),n.target.isSameNode(e))return;t.forEach((e=>{e.classList.contains("active")&&e.classList.remove("active")})),n.target.classList.add("active"),document.querySelectorAll(".color-swatch-tab-content").forEach((e=>{e.classList.contains("active")&&e.classList.remove("active")}));document.querySelector(`.color-swatch-tab-content${n.target.hash}`).classList.add("active"),e=n.target}))}))}(),document.addEventListener("DOMContentLoaded",(function(){const e=document.querySelector(".product-sticky-button"),t=document.querySelector("#product-content .product-photos.make-product-gallery-sticky")||document.querySelector("#siteHeader:not(.hide-header-on-pdp-on-scroll)"),n=document.querySelector("#button-sticky-indicator"),i=window.matchMedia("(max-width: 980px)");if(!e||!n)return;const o=()=>{const i=t?t.getBoundingClientRect().bottom:null,o=n.getBoundingClientRect().bottom,r=e.offsetHeight;t?o<=i?(e.classList.add("open"),t.classList.contains("act-position-above")&&(t.style.paddingTop=`${r}px`)):(e.classList.remove("open"),t.style.paddingTop="0px"):o<=0?e.classList.add("open"):e.classList.remove("open")},r=t=>{t.matches?(window.addEventListener("scroll",o),o()):(window.removeEventListener("scroll",o),e.classList.remove("open"))};r(i),i.addEventListener("change",r)})),function(){const e=document.querySelectorAll(".swatch-element"),t=document.querySelector(".product-photos");0!==e.length&&t&&e.forEach((e=>{e.addEventListener("click",(()=>{t.getBoundingClientRect().bottom>window.innerHeight&&t.scrollIntoView({block:"end",behavior:"smooth"})}))}))}(),function(){class e extends HTMLElement{constructor(){super()}connectedCallback(){this._tooltip=this.querySelector(".tooltip"),this.addEventListener("click",(()=>{this.copyText()}))}copyText(){const e=this.childNodes[0].textContent.trim();navigator.clipboard.writeText(e).then((()=>{this._tooltip&&this.showTooltip()})).catch((e=>{}))}showTooltip(){this._tooltip&&(this._tooltip.classList.add("show-tooltip"),setTimeout((()=>{this._tooltip.classList.remove("show-tooltip")}),2e3))}}customElements.define("copy-text",e)}(),document.addEventListener("galleryReady:covetPics",(function(e){document.querySelectorAll("covet-pics-widget").forEach((t=>{if(!t.shadowRoot)return;const n=document.createElement("style");215738===e.detail.galleryId?n.textContent="\n .gallery.grid {\n gap: 5px;\n grid-template-columns: repeat(3, 1fr);\n }\n\n covet-pics-gallery-item.grid-item,\n covet-pics-gallery-item.grid-item.highlighted {\n margin-bottom: 0;\n }\n\n @media (min-width: 800px) {\n .gallery.grid {\n gap: 10px;\n grid-template-columns: repeat(8, 1fr);\n }\n\n covet-pics-gallery-item.grid-item,\n covet-pics-gallery-item.grid-item.highlighted {\n margin-bottom: 0;\n }\n }\n ":n.textContent="\n covet-pics-gallery-item.grid-item:nth-child(3),\n covet-pics-gallery-item.grid-item:nth-child(12) {\n grid-column-end: span 2;\n grid-row-end: span 2;\n margin-bottom: calc(var(--covet-desktop-grid-space) * 0.5%);\n }\n @media screen and (max-width:799px) { \n covet-pics-gallery-item.grid-item:nth-child(3),\n covet-pics-gallery-item.grid-item:nth-child(12) {\n margin-bottom: calc(var(--covet-mobile-grid-space) * 0.5%);\n }\n }\n ",t.shadowRoot.appendChild(n)}))})),(()=>{const e=document.getElementById("toggleButton");
1e&&!e._filterToggleBound&&(e._filterToggleBound=!0,e.addEventListener("click",(function(){this.classList.toggle("open"),document.querySelectorAll(".js-filter-wrapper.should-hide").forEach((e=>{e.classList.contains("hide")?(e.classList.remove("hide"),e.offsetWidth,e.classList.add("show")):(e.classList.remove("show"),setTimeout((()=>{e.classList.add("hide")}),300))}))})))})(),window.addEventListener("DOMContentLoaded",(function(){initOkendoReviewHandling(),initStickySection()})),window.addEventListener("pageshow",(e=>{e.persisted&&theme.refreshAfterBfcacheRestore()})),document.querySelectorAll(".product-main-image").forEach((e=>{const t=e.querySelector(".product__image").getAttribute("alt");e.setAttribute("data-alt",t)})),customElements.get("swatch-scroller")||customElements.define("swatch-scroller",class extends HTMLElement{constructor(){super(),this.centerSwatch=this.centerSwatch.bind(this),this.centerSwatchDebounced=debounce(this.centerSwatch,100),this.swatchWrapper=this.querySelector(".color__swatch"),this.activeSwatch=this.querySelector("li.open"),this._onResize=()=>this.centerSwatchDebounced(this.activeSwatch)}connectedCallback(){this.querySelectorAll("li").forEach((e=>{e.addEventListener("click",(()=>{this.centerSwatch(e)}))})),window.addEventListener("resize",this._onResize),this.centerSwatchDebounced(this.activeSwatch)}disconnectedCallback(){this.querySelectorAll("li").forEach((e=>{e.removeEventListener("click",this.centerSwatch)})),window.removeEventListener("resize",this._onResize)}centerSwatch(e){if(!e||!this.swatchWrapper)return;const t=this.swatchWrapper.clientWidth,n=e.offsetWidth,i=e.offsetLeft+n/2-t/2;this.swatchWrapper.scrollTo({left:i,behavior:"smooth"}),this.activeSwatch=e}}),$(document).ready((function(){var e=new theme.Sections;e.register("header-section",theme.Header),e.register("slideshow-section",theme.Slideshow),e.register("new-slideshow",theme.newSlideshow),e.register("carousel-section",theme.FeaturedCollection),e.register("product-section",theme.Product),e.register("instagram",theme.Instagram),e.register("mobile-navigation",theme.mobileNav),e.register("collection-section",theme.Collection),e.register("map",theme.Maps),e.register("scrolling-announcements",theme.InfoSlider),e.register("featured-content",theme.FeatContent),e.register("parallax-section",theme.Parallax),e.register("collection-review",theme.CollectionReview)})),$(document).ready((function(){var e=window.matchMedia("(max-width: 465px)"),t=window.matchMedia("(max-width: 740px)"),n=window.matchMedia("(max-width: 980px) and (min-width: 741px)"),i=window.matchMedia("(min-width: 981px)");e.matches&&Events.trigger("mediaquery:smallMobile"),t.matches&&Events.trigger("mediaquery:mobile"),n.matches&&Events.trigger("mediaquery:tablet"),i.matches&&Events.trigger("mediaquery:desktop"),window.addEventListener("resize",(function(){e.matches&&Events.trigger("mediaquery:smallMobile"),t.matches&&Events.trigger("mediaquery:mobile"),n.matches&&Events.trigger("mediaquery:tablet"),i.matches&&Events.trigger("mediaquery:desktop")})),document.addEventListener("shopify:section:select",(function(e){Events.trigger("editor:section:select",e)})),document.addEventListener("shopify:section:deselect",(function(e){Events.trigger("editor:section:deselect",e)})),document.addEventListener("shopify:section:load",(function(e){Events.trigger("editor:section:load",e)})),document.addEventListener("shopify:section:unload",(function(e){Events.trigger("editor:section:unload",e)})),document.addEventListener("shopify:block:select",(function(e){Events.trigger("editor:block:select",e)})),document.addEventListener("shopify:block:deselect",(function(e){Events.trigger("editor:block:deselect",e)})),document.addEventListener("lazyloaded",(function(e){Events.trigger("lazyLoad:complete")}
1))})),document.addEventListener("DOMContentLoaded",(()=>{Shopify?.OptionSelectors?.HistoryState?.prototype&&(Shopify.OptionSelectors.HistoryState.prototype.onVariantChange=function(){})}));
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.