"use strict";
(self.webpackChunk_N_E = self.webpackChunk_N_E || []).push([
    [144], {
        17090: function(n, e, t) {
            var r = t(828),
                i = t(7297),
                o = t(85893),
                a = t(67294),
                l = t(5152),
                s = t.n(l),
                u = t(11163),
                d = t(86896),
                c = t(95321),
                m = t(10136),
                h = t(31666),
                f = t(45509),
                p = t(23107),
                x = t(74427),
                g = t(92177),
                v = t(28994),
                b = t(54797),
                y = t(94510),
                _ = t(79002),
                j = t(58457),
                w = t(38679),
                k = t(87304),
                C = t(31199),
                Z = t(60197),
                N = t(71969),
                T = t(71205),
                M = t(1649);

            function O() {
                var n = (0, i.Z)(["\n  border: ", ";\n"]);
                return O = function() {
                    return n
                }, n
            }

            function G() {
                var n = (0, i.Z)(["\n  background: #0057ff;\n  width: fit-content;\n  padding: 0 8px;\n  font-size: 14px;\n  color: white;\n  z-index: 1;\n  position: absolute;\n"]);
                return G = function() {
                    return n
                }, n
            }
            var P = s()(function() {
                    return t.e(2524).then(t.bind(t, 72524))
                }, {
                    loadableGenerated: {
                        webpack: function() {
                            return [72524]
                        }
                    },
                    ssr: !1
                }),
                z = s()(function() {
                    return t.e(2855).then(t.bind(t, 32855))
                }, {
                    loadableGenerated: {
                        webpack: function() {
                            return [32855]
                        }
                    },
                    ssr: !1
                }),
                D = h.default.div(O(), function(n) {
                    return n.highlight ? "solid 3px #0057FF" : "none"
                }),
                E = h.default.div(G()),
                F = function(n) {
                    var e, t, i, l, s, h, O, G, F, S, H, U = n.homeProps,
                        I = n.children,
                        B = U.fundraisingTotals,
                        A = U.categoryNav,
                        L = U.assetlyUrl,
                        R = U.dealer,
                        K = U.store,
                        J = U.cartCount,
                        q = void 0 === J ? 0 : J,
                        V = U.domainAuth,
                        Y = U.giftCards,
                        W = U.paymentMethods,
                        X = U.firstLoad,
                        Q = U.gcCode,
                        $ = V.storeDomainAuthEnabled,
                        nn = V.isAuthenticatedToStore,
                        ne = V.domainAuthRejectCode,
                        nt = V.shouldShowSuccessfulAuthModal,
                        nr = (0, f.JG)(Y),
                        ni = (null == W ? void 0 : W.length) === 1 && (null === (e = W[0]) || void 0 === e ? void 0 : e.payment_method_type) === "redemption",
                        no = (0, u.useRouter)(),
                        na = (0, d.Z)().formatMessage,
                        nl = (0, c.Fg)(),
                        ns = (null == no ? void 0 : null === (t = no.query) || void 0 === t ? void 0 : t.success) === "true",
                        nu = ni && q > nr,
                        nd = (null == no ? void 0 : null === (i = no.query) || void 0 === i ? void 0 : i.bundle) === "true",
                        nc = (null == no ? void 0 : null === (l = no.query) || void 0 === l ? void 0 : l.message) || "",
                        nm = a.useContext(m.NI).state,
                        nh = a.useContext(N.G9).state,
                        nf = null == nm ? void 0 : null === (s = nm.template) || void 0 === s ? void 0 : s.name,
                        np = "/_preview" === no.pathname,
                        nx = (null == Y ? void 0 : Y.length) === 0 && (null == W ? void 0 : W.length) === 1 && (null === (h = W[0]) || void 0 === h ? void 0 : h.payment_method_type) === "redemption" && !np && nf !== p.I,
                        ng = (0, r.Z)(a.useState(nc), 2),
                        nv = ng[0],
                        nb = ng[1],
                        ny = (0, r.Z)(a.useState(ns), 2),
                        n_ = ny[0],
                        nj = ny[1],
                        nw = (0, r.Z)(a.useState(nu), 2),
                        nk = nw[0],
                        nC = nw[1],
                        nZ = (0, r.Z)(a.useState(nt), 2),
                        nN = nZ[0],
                        nT = nZ[1],
                        nM = (0, r.Z)(a.useState(nx), 2),
                        nO = nM[0],
                        nG = nM[1];
                    return !$ || nn || np ? (0, o.jsxs)(o.Fragment, {
                        children: [(0, o.jsx)(g.M, {
                            sale: K
                        }), (0, o.jsxs)(D, {
                            highlight: "header" === nm.scrollTo,
                            children: ["header" === nm.scrollTo ? (0, o.jsx)(E, {
                                children: " Editing "
                            }) : null, (0, o.jsx)(M.I, {}), (0, o.jsx)(v.D, {
                                isRedemptionStore: ni,
                                giftCards: Y,
                                dealer: R,
                                cartCount: q,
                                categories: A,
                                store: K,
                                firstLoad: X
                            }), (0, o.jsx)(j.jL, {
                                assetlyUrl: L,
                                store: K,
                                timezone: R.timezone,
                                isCodeGroups: nh.isCodeGroup,
                                availableProducts: nh.products || [],
                                storeUrl: K.url,
                                hasBundles: Object.values((null == nh ? void 0 : null === (O = nh.codeGroupStore) || void 0 === O ? void 0 : O.filteredBundles) || {}).length > 0,
                                filterCategories: (null == nh ? void 0 : null === (G = nh.codeGroupStore) || void 0 === G ? void 0 : null === (F = G.filteredCategoriesNav) || void 0 === F ? void 0 : F.map(function(n) {
                                    return n.id
                                })) || []
                            }), (0, o.jsx)(b.i, {
                                store: K,
                                headerType: null == nl ? void 0 : null === (S = nl.theme) || void 0 === S ? void 0 : S.bannerType,
                                timezone: R.timezone
                            })]
                        }), nl.fundraising && !ni ? (0, o.jsx)(y.r, {
                            store: K,
                            totals: B
                        }) : null, n_ && !nu && (0, o.jsx)(k._2, {
                            children: (0, o.jsx)(w.o, {
                                notification: {
                                    status: "success",
                                    message: "",
                                    children: (0, C.k)({
                                        formatMessage: na,
                                        isBundle: nd
                                    })
                                },
                                setNotification: function() {
                                    return nj(!1)
                                }
                            })
                        }), nk && (0, o.jsx)(k._2, {
                            children: (0, o.jsx)(w.o, {
                                notification: {
                                    status: "warn",
                                    title: "Redemption Limit Met",
                                    message: "",
                                    children: (0, o.jsxs)("span", {
                                        children: ["Your item has been added to your cart, but you’ve passed your redemption limit. You can continue to shop, but you’ll have to adjust your cart to", " ", (0, o.jsx)("b", {
                                            style: {
                                                fontWeight: "500"
                                            },
                                            children: (0, T._6)(nr, "Item")
                                        }), " ", "before you can check out."]
                                    })
                                },
                                setNotification: function() {
                                    return nC(!1)
                                }
                            })
                        }), nc && (0, o.jsx)(k._2, {
                            children: (0, o.jsx)(w.o, {
                                notification: {
                                    status: "warn",
                                    message: "",
                                    children: (0, C.J)({
                                        formatMessage: na,
                                        reason: nv
                                    })
                                },
                                setNotification: function() {
                                    return nb("")
                                }
                            })
                        }), !nO && (0, o.jsx)(P, {
                            message: K.message,
                            type: K.message_type,
                            saleId: K.id
                        }), I, (0, o.jsx)(_.h, {
                            dealer: R,
                            store: K
                        }), nN && (0, o.jsx)(z, {
                            storeName: K.name,
                            closeModal: function() {
                                return nT(!1)
                            }
                        }), nO && (0, o.jsx)(Z.Y, {
                            setShowRedemptionModal: nG,
                            primaryLogo: null === (H = K.primary_logo) || void 0 === H ? void 0 : H.asset_url,
                            name: K.name,
                            service_email: K.service_email,
                            service_email_user_id: K.service_email_user_id,
                            service_email_is_dealer: K.service_email_is_dealer,
                            custom_service_email: K.custom_service_email,
                            gcCode: null != Q ? Q : ""
                        })]
                    }) : (0, o.jsx)(x.K, {
                        adminLink: R.service_email,
                        rejectCode: ne,
                        storeCode: K.sale_code
                    })
                };
            e.Z = F
        },
        75309: function(n, e, t) {
            t.d(e, {
                Z: function() {
                    return nK
                }
            });
            var r = t(14924),
                i = t(26042),
                o = t(69396),
                a = t(828),
                l = t(7297),
                s = t(85893),
                u = t(31666),
                d = t(84950),
                c = t(10136),
                m = t(71969),
                h = t(67294),
                f = t(45509),
                p = t(95321),
                x = t(99747),
                g = t(29815),
                v = t(41664),
                b = t.n(v),
                y = t(34435);

            function _() {
                var n = (0, l.Z)(["\n  flex: 1;\n  display: flex;\n  flex-direction: column;\n  @media only screen and (min-width: ", ") {\n    flex-direction: row;\n  }\n"]);
                return _ = function() {
                    return n
                }, n
            }

            function j() {
                var n = (0, l.Z)(["\n  position: relative;\n  display: inline-block;\n  flex: 1;\n  height: 200px;\n  margin: 32px 0 0 0;\n\n  &:first-of-type {\n    margin: 0;\n  }\n  &:hover {\n    .title-container {\n      background-color: #212530;\n    }\n  }\n\n  @media only screen and (min-width: ", ") {\n    margin: 0 0 0 32px;\n  }\n\n  a {\n    height: 200px;\n    display: inherit;\n  }\n"]);
                return j = function() {
                    return n
                }, n
            }

            function w() {
                var n = (0, l.Z)(["\n  width: 100%;\n  height: 100%;\n  ", ";\n  background-position: center;\n  background-repeat: no-repeat;\n  background-size: cover;\n"]);
                return w = function() {
                    return n
                }, n
            }

            function k() {
                var n = (0, l.Z)(["\n  position: absolute;\n  display: flex;\n  justify-content: center;\n  align-items: center;\n  bottom: 0;\n  height: 64px;\n  width: 100%;\n  background-color: rgba(53, 58, 72, 0.7);\n  padding: 0 10px;\n  margin: 0;\n"]);
                return k = function() {
                    return n
                }, n
            }

            function C() {
                var n = (0, l.Z)(["\n  color: white;\n  font-size: 24px;\n  font-weight: 600;\n  line-height: 30px;\n  text-align: center;\n  max-height: 64px;\n  overflow: hidden;\n"]);
                return C = function() {
                    return n
                }, n
            }
            var Z = d.OMGTheme.breakpoints,
                N = (0, u.default)(y.rz)(_(), Z.sm),
                T = u.default.div(j(), Z.sm),
                M = u.default.div(w(), function(n) {
                    var e = n.backgroundUrl;
                    return e && "background: url(".concat(e, ");")
                }),
                O = u.default.div(k()),
                G = u.default.p(C()),
                P = function(n) {
                    var e = n.components,
                        t = n.assetlyUrl,
                        r = n.availableProducts,
                        i = n.storeUrl,
                        o = void 0 === i ? "" : i,
                        a = n.isCodeGroups,
                        l = void 0 !== a && a,
                        u = n.hasBundles,
                        d = void 0 === u || u,
                        c = n.filterCategories,
                        m = (0, h.useMemo)(function() {
                            return e.filter(function(n) {
                                var e, t, i = (null == n ? void 0 : null === (e = n.cta_button_url) || void 0 === e ? void 0 : e.split("/")) || "",
                                    a = i[i.length - 1] || "";
                                return !!(!l || n.cta_button_url && !(null == n ? void 0 : n.cta_button_url.includes("".concat(o, "shop/product"))) && !(null == n ? void 0 : n.cta_button_url.includes("bundle")) && !(null == n ? void 0 : n.cta_button_url.includes("".concat(o, "shop/category"))) || d && (null == n ? void 0 : null === (t = n.cta_button_url) || void 0 === t ? void 0 : t.includes("bundle")) || c && n.cta_button_url && n.cta_button_url.includes("".concat(o, "shop/category")) && c.includes(a)) || r && n.cta_button_url && n.cta_button_url.includes("".concat(o, "shop/product")) && (null == r ? void 0 : r.includes(a))
                            })
                        }, [r, e, c, d, l, o, ]);
                    return m.filter(function(n) {
                        return !n.is_hidden
                    }).length < 2 && l ? null : (0, s.jsx)(N, {
                        children: m.map(function(n) {
                            var e;
                            return n.is_hidden ? null : (0, s.jsx)(T, {
                                children: (0, s.jsx)(b(), {
                                    href: null !== (e = n.cta_button_url) && void 0 !== e ? e : "",
                                    passHref: !0,
                                    children: (0, s.jsx)("a", {
                                        children: (0, s.jsx)(M, {
                                            backgroundUrl: "".concat(t, "/images/w_448/").concat(n.links.logo_asset),
                                            children: (0, s.jsx)(O, {
                                                className: "title-container",
                                                children: (0, s.jsx)(G, {
                                                    children: n.cta_button_text
                                                })
                                            })
                                        })
                                    })
                                })
                            }, n.id)
                        })
                    })
                };

            function z() {
                var n = (0, l.Z)(["\n  box-sizing: border-box;\n  display: grid;\n  text-align: center;\n  min-width: 328px;\n  width: 100%;\n  max-height: ", ";\n  grid-template-columns: 1fr;\n  grid-template-rows: repeat(\n    ", ",\n    ", "\n  );\n  @media only screen and (min-width: ", ") {\n    grid-template-columns: repeat(\n      ", ",\n      1fr\n    );\n  }\n  @media only screen and (min-width: ", ") {\n    grid-template-columns: repeat(", ", 1fr);\n  }\n  @media only screen and (min-width: ", ") {\n    grid-template-columns: repeat(", ", 1fr);\n  }\n  @media only screen and (min-width: ", ") {\n    grid-template-columns: repeat(", ", 1fr);\n    max-width: 1504px;\n  }\n"]);
                return z = function() {
                    return n
                }, n
            }

            function D() {
                var n = (0, l.Z)(["\n  justify-content: center;\n  display: grid;\n  height: 100%;\n  min-height: 160px;\n  max-height: 200px;\n  @media only screen and (min-width: ", ") {\n    min-height: 200px;\n  }\n  overflow: hidden;\n  width: 100%;\n  grid-template-columns: 1fr;\n"]);
                return D = function() {
                    return n
                }, n
            }

            function E() {
                var n = (0, l.Z)(["\n  background: ", ";\n  grid-row-start: 1;\n  grid-column-start: 1;\n  z-index: 0;\n  width: 100%;\n"]);
                return E = function() {
                    return n
                }, n
            }

            function F() {
                var n = (0, l.Z)(["\n  background: ", ";\n  z-index: 1;\n  @media only screen and (min-width: ", ") and (max-width: 1023px) {\n    ", ";\n  }\n"]);
                return F = function() {
                    return n
                }, n
            }

            function S() {
                var n = (0, l.Z)(["\n  display: grid;\n  min-height: 100%;\n  grid-template-columns: '1fr';\n  grid-template-rows: '1fr 1fr';\n  @media only screen and (min-width: ", ") {\n    grid-template-columns: ", ";\n    grid-template-rows: ", ";\n  }\n"]);
                return S = function() {
                    return n
                }, n
            }

            function H() {
                var n = (0, l.Z)(["\n  grid-row-start: 1;\n  grid-column-start: 1;\n  margin: auto;\n  width: 32px;\n  @media only screen and (min-width: ", ") {\n    width: ", ";\n    margin-right: ", ";\n  }\n"]);
                return H = function() {
                    return n
                }, n
            }

            function U() {
                var n = (0, l.Z)(["\n  font-family: ", ";\n  font-size: 16px;\n  font-weight: 600;\n  color: ", ";\n  grid-row-start: 2;\n  grid-column-start: 1;\n  margin: 0vh 4vh;\n  text-align: center;\n  @media only screen and (min-width: ", ") {\n    ", ";\n  }\n  word-wrap: break-word;\n  overflow: hidden;\n"]);
                return U = function() {
                    return n
                }, n
            }
            var I = d.OMGTheme.breakpoints,
                B = (0, u.default)(y.rz)(z(), function(n) {
                    return 2 === n.boxesNumber ? "448px" : "".concat(160 * n.boxesNumber, "px")
                }, function(n) {
                    return n.boxesNumber
                }, function(n) {
                    return 2 === n.boxesNumber ? "maxmin(224px, 1fr)" : "maxmin(160px, 1fr)"
                }, I.sm, function(n) {
                    return 4 === n.boxesNumber ? "2" : n.boxesNumber
                }, I.md, function(n) {
                    return n.boxesNumber
                }, I.lg, function(n) {
                    return n.boxesNumber
                }, I.xl, function(n) {
                    return n.boxesNumber
                }),
                A = (0, u.default)(y.rx)(D(), d.OMGTheme.breakpoints.sm),
                L = (0, u.default)(y.rx)(E(), function(n) {
                    return n.backgroundColor
                }),
                R = (0, u.default)(L)(F(), function(n) {
                    return n.position % 2 == 0 ? "transparent" : "rgba(255,255,255,.4)"
                }, I.sm, function(n) {
                    return 4 === n.boxesNumber ? 0 === n.position || 3 === n.position ? "background: transparent; !important" : "background: rgba(255,255,255,.4) !important;" : null
                }),
                K = (0, u.default)(y.rx)(S(), d.OMGTheme.breakpoints.sm, function(n) {
                    return 2 === n.boxesNumber ? "1fr 4fr" : "1fr"
                }, function(n) {
                    return 2 === n.boxesNumber ? "1fr" : "1fr 1fr"
                }),
                J = (0, u.default)(y.rx)(H(), d.OMGTheme.breakpoints.sm, function(n) {
                    return 4 === n.boxesNumber ? "48px" : "56px"
                }, function(n) {
                    return 2 === n.boxesNumber ? "0px" : "auto"
                }),
                q = (0, u.default)(y.rx)(U(), function(n) {
                    return n.theme.default.fontFamilyBase
                }, function(n) {
                    return n.textColor
                }, d.OMGTheme.breakpoints.sm, function(n) {
                    return 2 === n.boxesNumber ? "\n      grid-row-start: 1;\n      grid-column-start: 2;\n      margin: auto 4vh auto 24px;\n      text-align: left;\n      " : "\n      grid-row-start: 2;\n      grid-column-start: 1;\n      margin: 0vh 4vh;\n      text-align: center;\n      "
                }),
                V = t(95727),
                Y = function(n) {
                    var e = n.backgroundColor,
                        t = n.icon,
                        r = n.text,
                        i = n.textColor,
                        o = n.position,
                        a = n.boxesNumber;
                    return (0, s.jsxs)(A, {
                        children: [(0, s.jsx)(L, {
                            backgroundColor: e
                        }), (0, s.jsx)(R, {
                            position: o,
                            boxesNumber: a,
                            children: (0, s.jsxs)(K, {
                                boxesNumber: a,
                                children: [(0, s.jsx)(J, {
                                    boxesNumber: a,
                                    children: (0, s.jsx)(V.JO, {
                                        icon: t,
                                        color: i,
                                        size: "100%"
                                    })
                                }), (0, s.jsx)(q, {
                                    textColor: i,
                                    boxesNumber: a,
                                    children: r
                                })]
                            })
                        })]
                    })
                },
                W = function(n) {
                    var e = n.backgroundColor,
                        t = n.textColor,
                        r = n.boxesData;
                    return r.map(function(n, i) {
                        return (0, s.jsx)(Y, {
                            backgroundColor: e,
                            icon: n.icon,
                            text: n.text,
                            textColor: t,
                            position: i,
                            boxesNumber: r.length
                        }, n.key)
                    })
                },
                X = function(n) {
                    var e = n.backgroundColor,
                        t = n.textColor,
                        r = n.components,
                        i = r.filter(function(n) {
                            return !n.is_hidden
                        });
                    if (!r || 0 === i.length) return null;
                    var o = i.sort(function(n, e) {
                        return n.column - e.column
                    }).map(function(n) {
                        var e = n.id,
                            t = n.links.logo_asset;
                        return {
                            key: e,
                            text: n.header_text,
                            icon: t
                        }
                    });
                    return (0, s.jsx)(B, {
                        boxesNumber: i.length,
                        children: W({
                            backgroundColor: e,
                            textColor: t,
                            boxesData: o
                        })
                    })
                },
                Q = t(80188),
                $ = t(71205);

            function nn() {
                var n = (0, l.Z)(["\n  margin: 0;\n"]);
                return nn = function() {
                    return n
                }, n
            }
            var ne = (0, u.default)(y.rz)(nn()),
                nt = function(n) {
                    var e = n.components,
                        t = n.bundleData,
                        r = n.hidePrice,
                        i = (0, a.Z)(e, 1)[0],
                        o = (0, $.tk)(t).slice(i.start_index && i.start_index > 0 ? i.start_index - 1 : 0, i.end_index && i.end_index > 0 ? i.end_index - 1 : 1 / 0);
                    return (0, s.jsx)(ne, {
                        children: o.map(function(n) {
                            var e;
                            return (0, s.jsx)("div", {
                                children: (0, s.jsx)(Q.Z, {
                                    bundleMap: n,
                                    hidePrices: r || n.hide_price
                                })
                            }, null === (e = n.bundle) || void 0 === e ? void 0 : e.id)
                        })
                    })
                },
                nr = t(24237),
                ni = t(60249),
                no = t(86896);

            function na() {
                var n = (0, l.Z)(["\n  color: ", ";\n  font-weight: 700;\n  font-size: 32px;\n  padding: 24px 16px 16px;\n  font: ", ";\n  margin: 0 auto;\n  @media (max-width: ", ") {\n    display: flex;\n    flex-direction: column;\n    text-align: center;\n  }\n"]);
                return na = function() {
                    return n
                }, n
            }

            function nl() {
                var n = (0, l.Z)(["\n  justify-items: center;\n  @media (min-width: ", ") {\n    max-width: ", ";\n  }\n  @media (min-width: ", ") {\n    max-width: ", ";\n  }\n  @media (min-width: ", ") {\n    max-width: ", ";\n  }\n  @media (min-width: ", ") {\n    max-width: ", ";\n  }\n  @media (min-width: ", ") {\n    max-width: ", ";\n  }\n  min-width: unset;\n  margin: 0 auto;\n"]);
                return nl = function() {
                    return n
                }, n
            }
            var ns = d.OMGTheme.breakpoints,
                nu = u.default.div(na(), function(n) {
                    var e = n.theme;
                    return e.theme.backgroundAssetId ? "#FCFCFCFC" : e.theme.textMain
                }, d.OMGTheme.fontFamilyBase, ns.xs),
                nd = (0, u.default)(ni.GridWrap)(nl(), ns.xs, ns.xs, ns.sm, ns.sm, ns.md, ns.md, ns.lg, ns.lg, ns.xl, ns.lg),
                nc = function(n) {
                    var e, t, r, i, o, a = n.components,
                        l = n.productArray,
                        u = n.storeHidePrices,
                        d = n.priceDisplay,
                        c = n.priceDisplayKlarna,
                        m = (0, no.Z)().formatMessage,
                        h = null !== (o = !(null === (e = a[0]) || void 0 === e ? void 0 : e.is_hidden) && (null === (t = a[0]) || void 0 === t ? void 0 : t.header_text)) && void 0 !== o ? o : m({
                            id: "featuredProducts",
                            defaultMessage: "Featured Products"
                        });
                    return (0, s.jsxs)(y.rz, {
                        children: [(null === (r = a[0]) || void 0 === r ? void 0 : r.header_text) && !(null === (i = a[0]) || void 0 === i ? void 0 : i.is_hidden) ? (0, s.jsx)(nu, {
                            children: h
                        }) : null, (0, s.jsx)(nd, {
                            children: l.map(function(n, e) {
                                var t;
                                return n && !(null === (t = a[0]) || void 0 === t ? void 0 : t.is_hidden) && (0, s.jsx)(ni.GridSpan, {
                                    xs: "1",
                                    sm: "3",
                                    md: "4",
                                    lg: "3",
                                    xl: "3",
                                    children: (0, s.jsx)(nr.lo, {
                                        product: n,
                                        saleHidePrices: u,
                                        priceDisplayType: d,
                                        priceDisplayKlarna: c,
                                        disableClick: !1,
                                        ribbonText: a[e].subheader_text || "Featured"
                                    })
                                }, "Component-product-".concat(a[e].id, "-").concat(n.id))
                            })
                        })]
                    })
                },
                nm = t(26341),
                nh = t(99551),
                nf = function(n) {
                    var e, t = n.components,
                        r = n.assetlyUrl,
                        i = n.availableProducts,
                        o = n.storeUrl,
                        a = void 0 === o ? "" : o,
                        l = n.isCodeGroups,
                        u = void 0 !== l && l,
                        d = n.hasBundles,
                        c = void 0 === d || d,
                        m = n.filterCategories,
                        f = t[0].composition ? JSON.parse(null === (e = t[0]) || void 0 === e ? void 0 : e.composition) : {},
                        p = "".concat(r, "/images/w_1680/").concat(t[0].links.logo_asset),
                        x = t[0],
                        g = x.header_text,
                        v = x.subheader_text,
                        y = x.cta_button_text,
                        _ = x.cta_button_url,
                        j = x.is_hidden,
                        w = h.useMemo(function() {
                            var n = (null == _ ? void 0 : _.split("/")) || "",
                                e = n[n.length - 1] || "";
                            return !!u && (!_ || (_.includes("bundle") ? !c : _.includes("".concat(a, "shop/category")) ? !(m && m.includes(e)) : !!_.includes("".concat(a, "shop/product")) && !(_.includes("".concat(a, "shop/product")) && (null == i ? void 0 : i.includes(e)))))
                        }, [i, _, m, c, u, a, ]),
                        k = (0, nm.p)(null == f ? void 0 : f.gravity),
                        C = (0, nm.C)(null == f ? void 0 : f.gravity);
                    return j ? null : (0, s.jsx)(nh.QV, {
                        positionX: k,
                        positionY: C,
                        image: p,
                        children: (0, s.jsx)(nh.nP, {
                            opacity: null == f ? void 0 : f.opacity,
                            children: (0, s.jsxs)(nh.M5, {
                                alignment: (null == f ? void 0 : f.alignment) ? f.alignment : "center",
                                children: [g && (0, s.jsx)(nh.z, {
                                    children: g
                                }), v && (0, s.jsx)(nh.wP, {
                                    children: v
                                }), _ && y && !w && (0, s.jsx)(b(), {
                                    href: _,
                                    children: (0, s.jsx)("a", {
                                        children: (0, s.jsx)(nh.m3, {
                                            children: y
                                        })
                                    })
                                })]
                            })
                        })
                    })
                },
                np = t(33913),
                nx = t(78420),
                ng = t(23107),
                nv = t(33689),
                nb = t.n(nv);

            function ny() {
                var n = (0, l.Z)(["\n  display: grid;\n  grid-template-columns: repeat(1, 1fr);\n  grid-column-gap: 24px;\n  grid-row-gap: 24px;\n\n  @media (min-width: ", ") {\n    grid-template-columns: repeat(3, 1fr);\n  }\n"]);
                return ny = function() {
                    return n
                }, n
            }

            function n_() {
                var n = (0, l.Z)(["\n  ", ";\n  max-width: 100%;\n"]);
                return n_ = function() {
                    return n
                }, n
            }

            function nj() {
                var n = (0, l.Z)(["\n  width: 100%;\n  height: 64px;\n\n  // In this range, button text regularly make the buttons way too big, so we limit\n  // the width. In all other breakpoints there is enough room to let the buttons behave normally\n  @media (min-width: ", ") and (max-width: ", ") {\n    span > span {\n      max-width: 160px;\n    }\n  }\n"]);
                return nj = function() {
                    return n
                }, n
            }
            var nw = d.OMGTheme.breakpoints,
                nk = u.default.div(ny(), d.OMGTheme.breakpoints.sm),
                nC = u.default.a(n_(), function(n) {
                    return n.is_disabled && "pointer-events: none;"
                }),
                nZ = (0, u.default)(nb())(nj(), nw.sm, nw.md),
                nN = t(34155),
                nT = /^[^a-zA-Z0-9]+.*$/,
                nM = function(n, e) {
                    var t, r, i = null !== (t = n.cta_button_text) && void 0 !== t ? t : "",
                        o = null !== (r = e.cta_button_text) && void 0 !== r ? r : "";
                    return nT.test(i) && nT.test(o) ? n.column - e.column : nT.test(i) ? 1 : nT.test(o) ? -1 : n.column - e.column
                },
                nO = function(n, e) {
                    if (null !== n.cta_button_text && null !== e.cta_button_text) {
                        var t;
                        return null === (t = n.cta_button_text) || void 0 === t ? void 0 : t.localeCompare(e.cta_button_text)
                    }
                    return n.cta_button_text && nT.test(n.cta_button_text) ? 1 : e.cta_button_text && nT.test(e.cta_button_text) ? -1 : 0
                },
                nG = function(n) {
                    var e, t = n.components,
                        r = n.dealer,
                        i = n.frontendHostName,
                        o = n.expirationDates,
                        a = n.subdomains,
                        l = (0, p.Fg)().theme,
                        u = (0, h.useContext)(c.NI).state,
                        d = (null == u ? void 0 : null === (e = u.template) || void 0 === e ? void 0 : e.name) === ng.I,
                        m = function(n, e) {
                            return d ? nO(n, e) : nM(n, e)
                        };
                    return (0, s.jsx)(nk, {
                        children: t.sort(m).map(function(n) {
                            var e = n.cta_button_url,
                                t = n.cta_button_text,
                                u = n.id,
                                c = n.composition,
                                m = {};
                            try {
                                c && (m = JSON.parse(c))
                            } catch (h) {
                                console.warn("Failed to parse ".concat(c, ", defaulting to empty object"), h)
                            }
                            var f = e,
                                p = {},
                                x = null,
                                g = !1,
                                v = "";
                            if (null == m ? void 0 : m.saleCode) {
                                var b = a.find(function(n) {
                                    return Object.keys(n)[0] === m.saleCode && null !== n[m.saleCode]
                                });
                                f = b ? "//".concat(b[null == m ? void 0 : m.saleCode], ".").concat(i) : !b && d ? "//".concat(r.slug, ".").concat(i, "/shop/") : "//".concat(r.slug, ".").concat(i, "/shop/?saleCode=").concat(m.saleCode), v = null == m ? void 0 : m.saleCode
                            } else f.toLocaleLowerCase().includes(nN.env.FRONTEND_HOSTNAME) && (v = f.split(".")[0].split("//")[1]);
                            o.length > 0 && (p = o.find(function(n) {
                                return Object.keys(n)[0] === v
                            })), p && (x = p[v]), "www." === f.slice(0, 4).toLowerCase() && (f = "//".concat(f));
                            try {
                                null !== x && (g = (0, np.Z)((0, nx.Z)(x)))
                            } catch (y) {
                                console.warn("Failed to parse expired_date, leaving button enabled", x)
                            }
                            return (0, s.jsx)(nC, {
                                href: f,
                                is_disabled: g,
                                children: (0, s.jsx)(nZ, {
                                    color: l.primary,
                                    textColor: l.primaryReadableTextColor,
                                    disabled: g,
                                    children: t
                                })
                            }, u)
                        })
                    })
                },
                nP = t(68096),
                nz = t(44012),
                nD = t(87304);

            function nE() {
                var n = (0, l.Z)(["\n  margin: 0;\n"]);
                return nE = function() {
                    return n
                }, n
            }
            var nF = (0, u.default)(y.rz)(nE()),
                nS = function(n) {
                    var e = n.components,
                        t = n.categories,
                        r = n.hidePrices,
                        i = n.productsPerCategory,
                        o = n.priceDisplayKlarna,
                        l = (0, a.Z)(e, 1)[0],
                        u = (0, p.Fg)().theme,
                        d = Object.keys(t).slice(l.start_index && l.start_index > 0 ? l.start_index - 1 : 0, l.end_index && l.end_index > 0 ? l.end_index - 1 : 1 / 0),
                        c = Object.keys(t).length;
                    return (0, s.jsx)(nF, {
                        children: d.map(function(n) {
                            return (0, s.jsxs)("div", {
                                children: [(0, s.jsx)(nD.Wt, {
                                    children: (0, s.jsxs)(nD.xc, {
                                        children: [(0, s.jsx)(nD.SZ, {
                                            children: n
                                        }), (0, s.jsx)(b(), {
                                            href: "/category/".concat(t[n][0].category_id),
                                            passHref: !0,
                                            children: (0, s.jsx)(nD.pv, {
                                                children: (0, s.jsx)(nD.pz, {
                                                    fill: "transparent",
                                                    children: (0, s.jsx)(nz.Z, {
                                                        id: "viewCategoryPage",
                                                        defaultMessage: "View Category Page"
                                                    })
                                                })
                                            })
                                        })]
                                    })
                                }), (0, s.jsx)(nP.qG, {
                                    saleHidePrices: r,
                                    priceDisplayType: u.priceDisplayType,
                                    priceDisplayKlarna: o,
                                    products: t[n],
                                    cardLimit: i,
                                    limitCards: c > 1 && 12 === i || 12 !== i
                                })]
                            }, n)
                        })
                    })
                };

            function nH() {
                var n = (0, l.Z)(["\n    display: flex;\n    flex-direction: column;\n    width: 100%;\n    margin: 0 auto;\n    padding: 30px 16px 32px;\n    flex-grow: 1;\n    @media (min-width: ", ") {\n      max-width: ", ";\n    }\n    @media (min-width: ", ") {\n      max-width: 668px;\n    }\n    @media (min-width: ", ") {\n      max-width: ", ";\n    }\n    @media (min-width: ", ") {\n      max-width: ", ";\n    }\n    @media (min-width: ", ") {\n      max-width: ", ";\n    }\n  "]);
                return nH = function() {
                    return n
                }, n
            }

            function nU() {
                var n = (0, l.Z)(["\n  display: ", ";\n  border: ", ";\n  margin: 40px 0;\n"]);
                return nU = function() {
                    return n
                }, n
            }

            function nI() {
                var n = (0, l.Z)(["\n  background: #0057ff;\n  width: fit-content;\n  padding: 0 8px;\n  font-size: 14px;\n  color: white;\n  z-index: 1;\n  position: absolute;\n"]);
                return nI = function() {
                    return n
                }, n
            }
            var nB = d.OMGTheme.breakpoints,
                nA = {
                    TemplateContainer: u.default.div(nH(), nB.xs, nB.xs, nB.sm, nB.md, nB.md, nB.lg, nB.lg, nB.xl, nB.lg)
                },
                nL = u.default.div(nU(), function(n) {
                    return n.isHidden ? "none" : "block"
                }, function(n) {
                    return n.highlight ? "solid 3px #0057FF" : "none"
                }),
                nR = u.default.div(nI()),
                nK = function(n) {
                    var e, t, l = n.bundles,
                        u = n.categories,
                        d = n.store,
                        v = n.assetlyUrl,
                        b = n.paymentMethods,
                        y = n.allPaymentMethods,
                        _ = n.dealer,
                        j = n.frontendHostName,
                        w = n.categoriesNavBar,
                        k = n.branding,
                        C = h.useContext(c.NI),
                        Z = C.selectors,
                        N = C.state,
                        T = h.useContext(m.G9).state,
                        M = (0, a.Z)(h.useState(u), 2),
                        O = M[0],
                        G = M[1],
                        z = (0, a.Z)(h.useState(l), 2),
                        D = z[0],
                        E = z[1],
                        F = N.template.products_per_category,
                        S = Z.getComponentsByRow(),
                        H = (0, p.Fg)().theme,
                        U = h.useMemo(function() {
                            return function(n, e, t) {
                                var r, a, l, s = function(e) {
                                    if (n[e]) {
                                        var t = n[e].map(function(n) {
                                            return (0, o.Z)((0, i.Z)({}, n), {
                                                row: e + 1
                                            })
                                        });
                                        u[e + 1] = t
                                    }
                                };
                                if ((null == e ? void 0 : e.featured_category_id) == null || "Premium Layout 3" !== t || Object.values(n).some(function(n) {
                                        return n.some(function(n) {
                                            return "featured-category" === n.type
                                        })
                                    })) return n;
                                var u = (0, i.Z)({}, n);
                                u[3] = [{
                                    id: "featured-category-pl3",
                                    type: "featured-category",
                                    row: 3,
                                    column: 1,
                                    composition: null,
                                    links: {
                                        logo_asset: null,
                                        product: null
                                    },
                                    header_text: "Featured Category",
                                    subheader_text: "",
                                    cta_button_text: "",
                                    cta_button_url: "#",
                                    start_index: null,
                                    end_index: null,
                                    is_hidden: !1
                                }];
                                for (var d = (r = Math).max.apply(r, (0, g.Z)(Object.keys(n).map(Number))), c = d; c >= 3; c -= 1) s(c);
                                return u
                            }(S, k, N.template.name || "")
                        }, [S, k, N.template.name]),
                        I = (null == b ? void 0 : b.length) === 1 && (null === (e = b[0]) || void 0 === e ? void 0 : e.payment_method_type) === "redemption",
                        B = (0, f.bM)(null == d ? void 0 : null === (t = d.payment_method) || void 0 === t ? void 0 : t.hide_prices, I),
                        A = 0 === Object.keys(l).length,
                        L = N.expirationDates || [],
                        R = N.subdomains || [],
                        K = (0, x.R)(I, y, _.klarna_enabled, _.klarna_all_stores_enabled, H.priceDisplayKlarna, d),
                        J = (null == w ? void 0 : w.map(function(n) {
                            return n.id
                        })) || [],
                        q = h.useCallback(function(n) {
                            return Object.keys(u).reduce(function(e, t) {
                                var r = u[t].filter(function(e) {
                                    return n.includes(e.id)
                                });
                                return r.length > 0 && (e[t] = r), e
                            }, {})
                        }, [u]),
                        V = h.useCallback(function(n) {
                            return Object.keys(l).reduce(function(e, t) {
                                var r = l[t],
                                    a = r.products.filter(function(e) {
                                        return n.includes(e.id)
                                    });
                                return a.length > 1 && (e[t] = (0, o.Z)((0, i.Z)({}, r), {
                                    products: a
                                })), e
                            }, {})
                        }, [l]);
                    return (0, h.useEffect)(function() {
                        var n, e = null,
                            t = Object.keys(U).map(function(n) {
                                var e = U[Number(n)];
                                return "mid-page-banner" === e[0].type ? "".concat(e[0].type, "-").concat(e[0].id) : null
                            });
                        t.length > 1 && (e = (0, a.Z)(t, 1)[0]), N.scrollTo && ("header" === N.scrollTo ? window.scrollTo({
                            top: 0,
                            left: 0,
                            behavior: "smooth"
                        }) : N.scrollTo === e ? window.scrollTo({
                            top: 200,
                            left: 0,
                            behavior: "smooth"
                        }) : document.getElementsByClassName(N.scrollTo)[0] && document.getElementsByClassName(N.scrollTo)[0].scrollIntoView({
                            behavior: "smooth",
                            block: "center"
                        }))
                    }, [N.scrollTo, U]), (0, h.useEffect)(function() {
                        var n = N.disablePointerEvents ? "none" : "auto";
                        return document.body.style.pointerEvents = n,
                            function() {
                                document.body.style.pointerEvents = "auto"
                            }
                    }, [N.disablePointerEvents]), (0, h.useEffect)(function() {
                        if (T.isCodeGroup && T.products) {
                            var n = q(T.products),
                                e = [],
                                t = [],
                                r = !0,
                                i = !1,
                                o = void 0;
                            try {
                                for (var a, s = Object.keys(n)[Symbol.iterator](); !(r = (a = s.next()).done); r = !0) {
                                    var d = u[a.value],
                                        c = !0,
                                        m = !1,
                                        h = void 0;
                                    try {
                                        for (var f, p = d[Symbol.iterator](); !(c = (f = p.next()).done); c = !0) {
                                            var x = f.value;
                                            e.push(x.category_id), (null == x ? void 0 : x.subcategory_id) && t.push(null == x ? void 0 : x.subcategory_id)
                                        }
                                    } catch (g) {
                                        m = !0, h = g
                                    } finally {
                                        try {
                                            c || null == p.return || p.return()
                                        } finally {
                                            if (m) throw h
                                        }
                                    }
                                }
                            } catch (v) {
                                i = !0, o = v
                            } finally {
                                try {
                                    r || null == s.return || s.return()
                                } finally {
                                    if (i) throw o
                                }
                            }
                            var b = V(T.products);
                            n && G(n), E(b)
                        } else G(u), E(l)
                    }, [l, u, q, V, d.sale_code, T.isCodeGroup, T.products, I, ]), (0, s.jsx)(nA.TemplateContainer, {
                        children: Object.keys(U).sort(function(n, e) {
                            return Number.parseInt(n, 10) - Number.parseInt(e, 10)
                        }).map(function(n) {
                            var e = U[Number(n)],
                                t = {
                                    components: e,
                                    key: e[0].id,
                                    "data-test-id": e[0].id,
                                    assetlyUrl: v
                                },
                                a = e[0].id,
                                l = "".concat(e[0].type, "-").concat(e[0].id);
                            switch (e[0].type) {
                                case "image-blocks":
                                    return (0, s.jsxs)(nL, {
                                        isHidden: e[0].is_hidden,
                                        className: l,
                                        highlight: l === N.scrollTo,
                                        children: [l === N.scrollTo ? (0, s.jsx)(nR, {
                                            children: " Editing "
                                        }) : null, (0, s.jsx)(P, (0, o.Z)((0, i.Z)({}, t), {
                                            assetlyUrl: v,
                                            isCodeGroups: T.isCodeGroup,
                                            availableProducts: T.products,
                                            storeUrl: d.url,
                                            hasBundles: Object.values(D || {}).length > 0,
                                            filterCategories: J
                                        }))]
                                    }, a);
                                case "info-bar":
                                    return (0, s.jsxs)(nL, {
                                        isHidden: e[0].is_hidden,
                                        className: l,
                                        highlight: l === N.scrollTo,
                                        children: [l === N.scrollTo ? (0, s.jsx)(nR, {
                                            children: " Editing "
                                        }) : null, (0, s.jsx)(X, (0, o.Z)((0, i.Z)({}, t), {
                                            backgroundColor: H.secondary,
                                            textColor: H.secondaryReadableTextColor
                                        }))]
                                    }, a);
                                case "bundle":
                                    return (0, s.jsxs)(nL, {
                                        isHidden: e[0].is_hidden || A,
                                        className: l,
                                        highlight: l === N.scrollTo,
                                        children: [l === N.scrollTo ? (0, s.jsx)(nR, {
                                            children: " Editing "
                                        }) : null, (0, s.jsx)(nt, (0, o.Z)((0, i.Z)({}, t), {
                                            bundleData: D,
                                            hidePrice: B
                                        }))]
                                    }, a);
                                case "category":
                                    return (0, s.jsxs)(nL, {
                                        isHidden: e[0].is_hidden,
                                        className: l,
                                        highlight: l === N.scrollTo,
                                        children: [l === N.scrollTo ? (0, s.jsx)(nR, {
                                            children: " Editing "
                                        }) : null, (0, s.jsx)(nS, (0, o.Z)((0, i.Z)({}, t), {
                                            categories: O,
                                            hidePrices: B,
                                            productsPerCategory: F,
                                            priceDisplayKlarna: K
                                        }))]
                                    }, a);
                                case "featured-products":
                                    var c, m = Object.keys(u).flatMap(function(n) {
                                            return u[n]
                                        }),
                                        h = t.components.map(function(n) {
                                            return m.find(function(e) {
                                                return e.id === n.links.product
                                            })
                                        }).filter(function(n) {
                                            return void 0 !== n
                                        }),
                                        f = 0 === T.products.length && h ? h : h.filter(function(n) {
                                            return T.products.includes(n.id)
                                        });
                                    return (0, s.jsxs)(nL, {
                                        isHidden: e[0].is_hidden || !(null === (c = f[0]) || void 0 === c ? void 0 : c.id) && !e[0].header_text,
                                        className: l,
                                        highlight: l === N.scrollTo,
                                        children: [l === N.scrollTo ? (0, s.jsx)(nR, {
                                            children: " Editing "
                                        }) : null, (0, s.jsx)(nc, (0, o.Z)((0, i.Z)({}, t), {
                                            productArray: f,
                                            storeHidePrices: B,
                                            priceDisplay: H.priceDisplayType,
                                            priceDisplayKlarna: K
                                        }))]
                                    }, a);
                                case "mid-page-banner":
                                    return (0, s.jsxs)(nL, {
                                        isHidden: e[0].is_hidden,
                                        className: l,
                                        highlight: l === N.scrollTo,
                                        children: [l === N.scrollTo ? (0, s.jsx)(nR, {
                                            children: " Editing "
                                        }) : null, (0, s.jsx)(nf, (0, o.Z)((0, i.Z)({}, t), {
                                            assetlyUrl: v,
                                            isCodeGroups: T.isCodeGroup,
                                            availableProducts: T.products,
                                            storeUrl: d.url,
                                            hasBundles: Object.values(D || {}).length > 0,
                                            filterCategories: J
                                        }))]
                                    }, a);
                                case "link":
                                    return (0, s.jsxs)(nL, {
                                        isHidden: e[0].is_hidden,
                                        className: l,
                                        highlight: l === N.scrollTo,
                                        children: [l === N.scrollTo ? (0, s.jsx)(nR, {
                                            children: " Editing "
                                        }) : null, (0, s.jsx)(nG, (0, o.Z)((0, i.Z)({}, t), {
                                            dealer: _,
                                            frontendHostName: j,
                                            expirationDates: L,
                                            subdomains: R
                                        }))]
                                    }, a);
                                case "featured-category":
                                    var p = null == k ? void 0 : k.featured_category_id,
                                        x = p ? w.find(function(n) {
                                            return String(n.id) === String(p)
                                        }) : null,
                                        g = null == x ? void 0 : x.name,
                                        b = g ? u[g] : null;
                                    return (0, s.jsxs)(nL, {
                                        isHidden: e[0].is_hidden,
                                        className: l,
                                        highlight: l === N.scrollTo,
                                        children: [l === N.scrollTo ? (0, s.jsx)(nR, {
                                            children: " Editing "
                                        }) : null, b && b.length > 0 && (0, s.jsx)(nS, {
                                            components: [(0, o.Z)((0, i.Z)({}, e[0]), {
                                                start_index: 1,
                                                end_index: 2
                                            }), ],
                                            categories: g ? (0, r.Z)({}, g, b) : {},
                                            hidePrices: B,
                                            productsPerCategory: 4,
                                            priceDisplayKlarna: K
                                        })]
                                    }, a);
                                default:
                                    return null
                            }
                        })
                    })
                }
        },
        74307: function(n, e, t) {
            t.d(e, {
                V: function() {
                    return h
                }
            });
            var r = t(7297),
                i = t(85893),
                o = t(31666),
                a = t(95321);

            function l() {
                var n = (0, r.Z)(["\n  ", "\n  background-position: center;\n  background-repeat: no-repeat;\n  background-size: cover;\n  position: fixed;\n  height: 100%;\n  width: 100%;\n"]);
                return l = function() {
                    return n
                }, n
            }

            function s() {
                var n = (0, r.Z)(["\n  position: absolute;\n  left: 50%;\n  transform: translateX(-50%);\n  width: 100%;\n  display: flex;\n  flex-direction: column;\n  min-height: 100vh;\n"]);
                return s = function() {
                    return n
                }, n
            }

            function u() {
                var n = (0, r.Z)(["\n  position: relative;\n  height: 100%;\n  width: 100%;\n  display: flex;\n  justify-content: center;\n  align-items: center;\n  background: rgba(0, 0, 0, 0.4);\n"]);
                return u = function() {
                    return n
                }, n
            }
            t(67294);
            var d = o.default.div(l(), function(n) {
                    return n.url ? "background-image: url(".concat(n.url, ");") : ""
                }),
                c = o.default.div(s()),
                m = o.default.div(u()),
                h = function(n) {
                    var e = n.children,
                        t = n.assetlyUrl,
                        r = (0, a.Fg)().theme.backgroundAssetId;
                    return (0, i.jsxs)(i.Fragment, {
                        children: [r && t && (0, i.jsx)(d, {
                            url: "".concat(t, "/assets/").concat(r),
                            children: (0, i.jsx)(m, {})
                        }), (0, i.jsx)(c, {
                            children: e
                        })]
                    })
                }
        }
    }
]);