!function(e,o){"object"==typeof exports&&"object"==typeof module?module.exports=o():"function"==typeof define&&define.amd?define(["globals"],o):"object"==typeof exports?exports.masterPage=o():e.masterPage=o()}(this,(function(globals){var $w=globals.$w,$ns=globals.$ns,console=(globals.$wixContext,globals.$widget,globals.console);globals.elementorySupport,globals.generateWebMethodUrl;return function(){"use strict";var e={n:function(o){var n=o&&o.__esModule?function(){return o.default}:function(){return o};return e.d(n,{a:n}),n},d:function(o,n){for(var t in n)e.o(n,t)&&!e.o(o,t)&&Object.defineProperty(o,t,{enumerable:!0,get:n[t]})},o:function(e,o){return Object.prototype.hasOwnProperty.call(e,o)},r:function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})}},o={};e.r(o);var n=$ns["wix-storage"],t=$ns["wix-window"],i=e.n(t),r=$ns["wix-location-frontend"],u=$ns["wix-users"],s=e.n(u),g=$ns["wix-members"],l=e.n(g);return $w.onReady((function(){function e(){var e=s().currentUser.loggedIn;console.log("Adjusting signupButton based on login status:",e),e?(console.log("User is logged in, hiding signupButton if it exists."),$w("#signupButton")&&$w("#signupButton").hide()):(console.log("User is logged out, showing signupButton if it exists."),$w("#signupButton")&&$w("#signupButton").show())}console.log("Page loaded and ready."),e(),"Mobile"===i().formFactor&&setTimeout((function(){console.log("Running additional adjustSignUpButton for mobile after delay."),e()}),500),r.query.token?(console.log("Session token found, applying."),s().applySessionToken(r.query.token).then((function(){console.log("Session token applied successfully."),e()})).catch((function(o){console.error("Error applying session token:",o),e()}))):(console.log("No session token found, adjusting signupButton."),e()),n.local.getItem("firstTimePopupShown")||(console.log("Showing first-time popup."),i().openLightbox("FirstTimeSubscriptionPopUp"),n.local.setItem("firstTimePopupShown","yes")),l().authentication.onLogin((function(){console.log("User logged in event triggered."),e()})),l().authentication.onLogout((function(){console.log("User logged out event triggered."),e()}))})),o}()})); //# sourceMappingURL=https://bundler.wix-code.com/8980537a-1633-4e71-a2ca-dd2e84efc99a/3c4e9899-e0c9-4580-ac6a-d583ef0af03c/e2534d14-ba98-42a9-86a7-75a88ad72c2c/pages/masterPage.js.map?get-app-def-id-from-package-name=false&disable-yarn-pnp-mode=false