(function ($) {
    "use strict";

    $(window).on('elementor/frontend/init', () => {
        elementorFrontend.hooks.addAction('frontend/element_ready/pakrco-search.default', ($scope) => {
            $('.button-search-popup',$scope).on('click', function (e) {
                e.preventDefault();
                $('html').addClass('search-popup-active');
            });

            $('.site-search-popup-close').on('click', function (e) {
                e.preventDefault();
                $('html').removeClass('search-popup-active');
            });
        });
    });

})(jQuery);
