{"version":3,"file":"BitrixCode.DwMqRE3k.mjs","names":[],"sources":["https:/framerusercontent.com/modules/inWg7xF8ecelmqdJxqQU/b7dMnuvBvZkVymlLRFvr/BitrixCode.js"],"sourcesContent":["import{jsx as _jsx}from\"react/jsx-runtime\";const openBitrixPopup=(e,url,elementName,clarityValue)=>{if(e){e.preventDefault();e.stopPropagation();}// Esto dispara el evento en Clarity\nif(typeof clarity===\"function\"){clarity(\"set\",\"form_open\",clarityValue);}const existing=document.getElementById(\"bitrix-popup-container\");if(existing)existing.remove();const container=document.createElement(\"div\");container.id=\"bitrix-popup-container\";container.setAttribute(\"name\",`popup_${clarityValue}`);container.style.cssText=`\n        position: fixed; top: 0; left: 0; width: 100vw; height: 100vh;\n        background: rgba(0,0,0,0.6); z-index: 999999;\n        display: flex; align-items: center; justify-content: center;\n        backdrop-filter: blur(4px);\n    `;const content=document.createElement(\"div\");content.style.cssText=`\n        position: relative; width: 90%; max-width: 500px; height: 90vh;\n        background: white; border-radius: 12px; overflow: hidden;\n        box-shadow: 0 20px 50px rgba(0,0,0,0.3);\n    `;const closeBtn=document.createElement(\"button\");closeBtn.innerText=\"✕\";closeBtn.style.cssText=`\n        position: absolute; top: 10px; right: 10px; z-index: 10;\n        border: none; background: #eee; border-radius: 50%; width: 30px; height: 30px;\n        cursor: pointer; font-weight: bold;\n    `;closeBtn.onclick=()=>container.remove();const trackingParams=\"?utm_source=framer&utm_campaign=finpay-2026\";const iframe=document.createElement(\"iframe\");iframe.src=`${url}${trackingParams}`;iframe.style.cssText=\"width: 100%; height: 100%; border: none;\";content.appendChild(closeBtn);content.appendChild(iframe);container.appendChild(content);document.body.appendChild(container);container.onclick=event=>{if(event.target===container)container.remove();};};// --- HOCs con el Tracking de Clarity ---\nexport function withBitrixSponsor(Component){return props=>/*#__PURE__*/_jsx(Component,{...props,name:\"btn_sponsor_finpay\",onClick:e=>openBitrixPopup(e,\"https://b24-chqr1u.bitrix24.site/crm_form_ntg6o/\",\"btn_sponsor_finpay\",\"sponsor_finpay\")});}export function withBitrixContacto(Component){return props=>/*#__PURE__*/_jsx(Component,{...props,name:\"btn_contacto_finpay\",onClick:e=>openBitrixPopup(e,\"https://b24-chqr1u.bitrix24.site/crm_form_myjo5/\",\"btn_contacto_finpay\",\"contacto_finpay\")});}// --- AUTO-OPEN POR URL ---\nif(typeof window!==\"undefined\"){window.addEventListener(\"load\",()=>{const params=new URLSearchParams(window.location.search);const openAction=params.get(\"open\");if(openAction===\"contacto\"){openBitrixPopup(null,\"https://b24-chqr1u.bitrix24.site/crm_form_myjo5/\",\"btn_contacto_finpay\",\"contacto_finpay\");}else if(openAction===\"sponsor\"){openBitrixPopup(null,\"https://b24-chqr1u.bitrix24.site/crm_form_ntg6o/\",\"btn_sponsor_finpay\",\"sponsor_finpay\");}});}\nexport const __FramerMetadata__ = {\"exports\":{\"withBitrixContacto\":{\"type\":\"reactHoc\",\"name\":\"withBitrixContacto\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"withBitrixSponsor\":{\"type\":\"reactHoc\",\"name\":\"withBitrixSponsor\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}\n//# sourceMappingURL=./BitrixCode.map"],"mappings":"kHAeA,SAAgB,EAAkB,EAAU,CAAC,MAAO,IAAoB,EAAK,EAAU,CAAC,GAAG,EAAM,KAAK,qBAAqB,QAAQ,GAAG,EAAgB,EAAE,mDAAmD,qBAAqB,iBAAiB,CAAC,CAAC,CAAE,SAAgB,EAAmB,EAAU,CAAC,MAAO,IAAoB,EAAK,EAAU,CAAC,GAAG,EAAM,KAAK,sBAAsB,QAAQ,GAAG,EAAgB,EAAE,mDAAmD,sBAAsB,kBAAkB,CAAC,CAAC,wBAfjc,CAAM,GAAiB,EAAE,EAAI,EAAY,IAAe,CAAI,IAAG,EAAE,gBAAgB,CAAC,EAAE,iBAAiB,EAC7I,OAAO,SAAU,YAAY,QAAQ,MAAM,YAAY,EAAa,CAAE,IAAM,EAAS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