{"version":3,"file":"SweetSpotLetter.BopO2Zdk.mjs","names":["_Fragment"],"sources":["https:/framerusercontent.com/modules/vbACV3sSzHRKMB3P2PWk/pIKRq6ioavtRUGOCzD52/SweetSpotLetter.js"],"sourcesContent":["// Get Started: https://www.framer.com/developers\nimport{jsx as _jsx,jsxs as _jsxs,Fragment as _Fragment}from\"react/jsx-runtime\";import{useEffect}from\"react\";import{addPropertyControls,ControlType}from\"framer\";import NewsletterSignupSmall from\"https://framerusercontent.com/modules/sep7lvaSK28ihG6hxAuV/w66kGQqgaV6HXhFTl3j8/NewsletterSignupSmall.js\";import{useSweetLetterSpot,useQigGatedModal}from\"https://framerusercontent.com/modules/c61m7y27y4l9UUTWlfvc/MyJWl2bkS9Bm96WNq9cP/globalStore.js\";/**\n * @framerSupportedLayoutWidth auto\n * @framerSupportedLayoutHeight auto\n */export default function SweetSpotLetter(props){const{headline,text,image}=props;const[showModal,setShowModal]=useSweetLetterSpot();const[isGatedModal,_]=useQigGatedModal();const sessionKey=\"news-letter-gated-page\";const handleMouseOut=e=>{if(e.clientY<=0&&!showModal&&!isGatedModal){setShowModal(true);}};useEffect(()=>{if(getCookie(sessionKey)||localStorage.getItem(sessionKey)===\"true\")return;document.addEventListener(\"mouseout\",handleMouseOut);return()=>document.removeEventListener(\"mouseout\",handleMouseOut);},[showModal]);function setCookie(name,value,hours){const date=new Date;date.setTime(date.getTime()+hours*60*60*1e3);const expires=\"expires=\"+date.toUTCString();document.cookie=encodeURIComponent(name)+\"=\"+value+\";\"+expires+\";path=/\";}function getCookie(name){const nameEQ=name+\"=\";const cookies=document.cookie.split(\";\");for(let i=0;i<cookies.length;i++){let c=cookies[i].trim();if(c.indexOf(nameEQ)===0){return c.substring(nameEQ.length,c.length);}}return null// not found\n;}const overlay={display:!showModal?\"none\":\"flex\",position:\"fixed\",inset:0,backgroundColor:\"rgba(0,0,0,0.6)\",justifyContent:\"center\",alignItems:\"center\",padding:\"16px\",zIndex:9999};const onModalClose=()=>{setCookie(sessionKey,true,2);document.removeEventListener(\"mouseout\",handleMouseOut);setShowModal(false);};const handleSubmit=data=>{onModalClose();localStorage.setItem(sessionKey,\"true\");if(Array.isArray(window.dataLayer)){window.dataLayer.push({event:\"hubspot-newsletter-signup\"});}};return /*#__PURE__*/_jsxs(_Fragment,{children:[/*#__PURE__*/_jsx(\"style\",{children:`\n.subscribe-newsletter-container > div {\n    position: relative;\n}\n\n.subscribe-newsletter-container input.hs-input {\n    font-family: 'Inter', sans-serif;\n    line-height: 1.75em;\n    border: 1px solid #787777 !important;\n    font-size: 16px;\n    border-radius: 2px;\n    height: 42px !important;\n    width: 100%;\n    padding: 0px 32px;\n    color: #632bfc;\n    box-shadow: 0px 24px 64px -12px rgba(0, 0, 0, 0.08);\n}\n\n.subscribe-newsletter-container input.hs-input:focus {\n    border: 1px solid #632bfc !important;\n}\n\n.subscribe-newsletter-container input.hs-input:placeholder {\n    color: #A2A8B9;\n}\n\n\n.subscribe-newsletter-container ul.inputs-list.hs-error-msgs {\n    font-family: 'Inter', sans-serif;\n    height: 16px !important;\n    line-height: 1.4em;\n    font-size: 12px;\n    font-weight: medium;\n    list-style: none;\n    margin: 4px 32px;\n    padding: 0;\n    color: rgb(211, 47, 47);\n}\n\n.subscribe-newsletter-container input[type=\"submit\"] {\n    position: relative !important;\n    top: 40px;\n    left: 0px !important;\n    font-size: 16px;\n    white-space: nowrap;\n    transition: all 1000ms ease-out;\n    overflow: hidden;\n    height: 42px !important;\n    padding-left: 16px;\n    padding-right: 16px;\n    background-color: #632bfc;\n    color: white;\n    border: none;\n    border-radius: 2px;\n    font-weight: 600;\n    text-transform: none;\n    box-shadow: none;\n    cursor: pointer;\n}\n            `}),/*#__PURE__*/_jsx(\"div\",{style:overlay,children:/*#__PURE__*/_jsxs(\"div\",{style:styles.modal,children:[/*#__PURE__*/_jsx(\"button\",{style:styles.closeBtn,onClick:onModalClose,children:\"✕\"}),/*#__PURE__*/_jsx(\"img\",{src:image,alt:\"sweetspot letter\",style:styles.image}),/*#__PURE__*/_jsxs(\"div\",{style:styles.content,children:[/*#__PURE__*/_jsx(\"h2\",{style:styles.headline,children:headline}),/*#__PURE__*/_jsx(\"p\",{style:styles.text,children:text}),/*#__PURE__*/_jsx(NewsletterSignupSmall,{formId:props?.formId,handleSubmit:handleSubmit})]})]})})]});}const styles={modal:{position:\"relative\",background:\"#fff\",borderRadius:\"12px\",boxShadow:\"0 8px 20px rgba(0,0,0,0.2)\",width:\"100%\",maxWidth:\"600px\",display:\"flex\",overflow:\"hidden\",transform:\"scale(0.95)\",transition:\"transform 0.3s ease-in-out\",maxHeight:\"450px\"},closeBtn:{position:\"absolute\",top:\"12px\",right:\"12px\",background:\"transparent\",border:\"none\",fontSize:\"20px\",cursor:\"pointer\",color:\"#666\",zIndex:10},image:{width:\"40%\",height:\"100%\",objectFit:\"cover\"},content:{width:\"60%\",padding:\"32px\",fontFamily:\"Inter\",paddingTop:\"32px\",display:\"flex\",flexDirection:\"column\",boxSizing:\"border-box\"},headline:{fontSize:\"20px\",fontWeight:\"700\",color:\"#222\",marginBottom:\"12px\",fontFamily:\"Inter\",paddingTop:\"16px\"},text:{fontSize:\"14px\",color:\"#555\",lineHeight:\"1.5\",paddingBottom:\"20px\"}};addPropertyControls(SweetSpotLetter,{headline:{type:ControlType.String,title:\"Headline\",defaultValue:\"Stay Informed, Stay Ahead\"},text:{type:ControlType.String,title:\"Text\",defaultValue:\"Gain access to our latest reports, in-depth industry analysis, and exclusive insights—delivered straight to your inbox in our Sweet Spot Newsletter.\"},image:{type:ControlType.Image,title:\"Image\",defaultValue:\"\"},formId:{type:ControlType.String,title:\"Form ID\",defaultValue:\"2f63e5b4-788f-419c-b818-56c51f3c1c4a\"}});\nexport const __FramerMetadata__ = {\"exports\":{\"default\":{\"type\":\"reactComponent\",\"name\":\"SweetSpotLetter\",\"slots\":[],\"annotations\":{\"framerSupportedLayoutHeight\":\"auto\",\"framerSupportedLayoutWidth\":\"auto\",\"framerContractVersion\":\"1\"}},\"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