{"version":3,"file":"siteMetadata.CJt0O2BJ.mjs","names":[],"sources":["https:/framerusercontent.com/modules/k8BOiG9DtJUKbuqHZhWw/MzMziBgl2UK41Bzxz45Z/siteMetadata.js"],"sourcesContent":["// Generated by Framer (c99c261)\nexport default function metadata(params,activeLocale){return{customHTMLBodyEnd:\"<script>\\n(function(){\\n  // ====== USE YOUR EXISTING FORM IDS ======\\n  const PORTAL_ID = '139631215';     // (keep the same portal from your current form)\\n  const FORM_GUID = 'e0498273-bfac-4e3a-800f-6c50ca833aeb';     // (the exact form your workflow uses)\\n  const MEET_URL  = 'https://meetings-eu1.hubspot.com/tweale'; // HubSpot Meetings\\n\\n  // Helpers\\n  function getEmail(){\\n    const el = document.querySelector('input[type=\\\"email\\\"], input[name=\\\"email\\\"]');\\n    return (el && el.value || '').trim();\\n  }\\n  function isDemoBtn(el){\\n    if (!el) return false;\\n    if (el.matches('[data-role=\\\"footer-demo\\\"]')) return true; // optional attribute if you add it\\n    const t = (el.textContent||'').trim().toLowerCase();\\n    return t === 'book a demo' || /book.*demo/i.test(t);\\n  }\\n  // If you store first-touch UTMs in localStorage, we’ll pass them along\\n  function ft(k){ return localStorage.getItem('ft_'+k) || ''; }\\n  function buildHsPayload(email){\\n    const fields = [{ name:'email', value: email }];\\n    [\\n      ['ft_utm_source',   ft('utm_source')],\\n      ['ft_utm_medium',   ft('utm_medium')],\\n      ['ft_utm_campaign', ft('utm_campaign')],\\n      ['ft_utm_content',  ft('utm_content')],\\n      ['ft_landing_page', localStorage.getItem('ft_landing') || location.pathname]\\n    ].forEach(([name,val])=> { if (val) fields.push({ name, value: val }); });\\n    return { fields, context:{ pageUri: location.href, pageName: document.title } };\\n  }\\n  async function submitHubSpotForm(email){\\n    if (!PORTAL_ID || !FORM_GUID || !email) return;\\n    const url = `https://api.hsforms.com/submissions/v3/integration/submit/${PORTAL_ID}/${FORM_GUID}`;\\n    try {\\n      await fetch(url, {\\n        method:'POST',\\n        headers:{ 'Content-Type':'application/json' },\\n        body: JSON.stringify(buildHsPayload(email))\\n      });\\n    } catch(e){ /* don’t block UX if CMP/network blocks */ }\\n  }\\n\\n  // Click handler (capture) – only affects “Book a demo”\\n  document.addEventListener('click', (e)=>{\\n    const el = e.target.closest('a,button');\\n    if (!el) return;\\n\\n    if (isDemoBtn(el)) {\\n      e.preventDefault();\\n      const email = getEmail();\\n\\n      // Open Meetings (prefilled if email present)\\n      const meet = new URL(MEET_URL);\\n      if (email) meet.searchParams.set('email', email);\\n      window.open(meet.toString(), '_blank', 'noopener,noreferrer');\\n\\n      // Submit to your existing HubSpot form (triggers your existing workflow)\\n      submitHubSpotForm(email);\\n\\n      // Optional GA event\\n      window.gtag && gtag('event','click_book_demo', {\\n        dest:'hs_meetings',\\n        email_domain: email ? email.split('@')[1] : ''\\n      });\\n    }\\n  }, true);\\n})();\\n</script>\\n\\n<script>\\n(function () {\\n  // Only on /newsroom\\n  if (!/\\\\/newsroom\\\\/?$/.test(location.pathname)) return;\\n\\n  /* === CONFIG === */\\n  const PORTAL_ID = '139631215';\\n  const FORM_GUID = 'e0498273-bfac-4e3a-800f-6c50ca833aeb';\\n  const BRAND_PURPLE = '#6F1BF6';\\n\\n  /* === Helpers === */\\n  const $ = (s, r=document)=>r.querySelector(s);\\n  const emailInput = () =>\\n    $('input[type=\\\"email\\\"], input[name=\\\"email\\\"], input[placeholder*=\\\"email\\\" i]');\\n  const isSubscribeBtn = (el) => {\\n    if (!el) return false;\\n    if (el.matches('[data-role=\\\"newsroom-subscribe\\\"]')) return true;\\n    const t = (el.textContent || el.ariaLabel || '').trim().toLowerCase();\\n    return t === 'subscribe' || /subscribe/.test(t);\\n  };\\n  const validEmail = v => /^[^\\\\s@]+@[^\\\\s@]+\\\\.[^\\\\s@]+$/.test(v);\\n\\n  // Optional UTM passthrough (only if you've stored first-touch UTMs)\\n  const ft = k => localStorage.getItem('ft_'+k) || '';\\n  const buildHsPayload = (email) => ({\\n    fields: [\\n      { name:'email', value: email },\\n      ...[\\n        ['ft_utm_source',   ft('utm_source')],\\n        ['ft_utm_medium',   ft('utm_medium')],\\n        ['ft_utm_campaign', ft('utm_campaign')],\\n        ['ft_utm_content',  ft('utm_content')],\\n        ['ft_landing_page', localStorage.getItem('ft_landing') || location.pathname]\\n      ].filter(([,v])=>!!v).map(([name,value])=>({name,value}))\\n    ],\\n    context: { pageUri: location.href, pageName: document.title }\\n  });\\n\\n  async function submitHubSpotForm(email){\\n    if (!PORTAL_ID || !FORM_GUID || !email) return;\\n    try {\\n      await fetch(`https://api.hsforms.com/submissions/v3/integration/submit/${PORTAL_ID}/${FORM_GUID}`, {\\n        method:'POST',\\n        headers:{ 'Content-Type':'application/json' },\\n        body: JSON.stringify(buildHsPayload(email))\\n      });\\n    } catch(e){ /* non-blocking */ }\\n  }\\n\\n  // Inject success style once\\n  if (!document.getElementById('newsroom-sub-style')) {\\n    const css = `\\n      .nr-subscribed{\\n        background:${BRAND_PURPLE} !important;\\n        color:#fff !important;\\n        border-color:${BRAND_PURPLE} !important;\\n        pointer-events:none !important;\\n        cursor:default !important;\\n      }\\n    `;\\n    const s = document.createElement('style');\\n    s.id = 'newsroom-sub-style';\\n    s.textContent = css;\\n    document.head.appendChild(s);\\n  }\\n\\n  function showSubscribed(btn){\\n    // lock width so text swap doesn't shrink\\n    const w = btn.getBoundingClientRect().width;\\n    btn.style.width = Math.ceil(w) + 'px';\\n\\n    const label = btn.querySelector('span, .text, .label');\\n    if (label) label.textContent = 'Subscribed';\\n    else btn.textContent = 'Subscribed';\\n\\n    // Don't use disabled attribute (avoids Framer's disabled variant)\\n    btn.setAttribute('aria-disabled','true');\\n    btn.classList.add('nr-subscribed');\\n  }\\n\\n  document.addEventListener('click', (e)=>{\\n    const btn = e.target.closest('button, a');\\n    if (!isSubscribeBtn(btn)) return;\\n\\n    e.preventDefault();\\n    if (btn.dataset.submitting === '1') return;\\n    btn.dataset.submitting = '1';\\n\\n    const inp = emailInput();\\n    const email = (inp && inp.value || '').trim();\\n    if (!validEmail(email)) { btn.dataset.submitting = '0'; inp && inp.focus(); return; }\\n\\n    submitHubSpotForm(email);     // fire-and-forget upsert → your HS workflow marks Marketing\\n    showSubscribed(btn);          // immediate visual confirmation\\n\\n    // optional GA\\n    if (window.gtag) gtag('event','newsroom_subscribe',{ email_domain: email.split('@')[1]||'' });\\n  }, true);\\n\\n  // Hitting Enter in the field triggers subscribe\\n  const inp = emailInput();\\n  if (inp) {\\n    inp.addEventListener('keydown', (e)=>{\\n      if (e.key !== 'Enter') return;\\n      e.preventDefault();\\n      const container = inp.closest('form, section, div') || document;\\n      const btn = container.querySelector('[data-role=\\\"newsroom-subscribe\\\"], button, a');\\n      if (btn && isSubscribeBtn(btn)) btn.click();\\n    });\\n  }\\n})();\\n</script>\\n\\n<script>\\n(function () {\\n  // --- Configure the labels and events you want to track ---\\n  var RULES = [\\n    { text: /book a demo/i, event: 'Schedule',   label: 'Book a Demo' },\\n    { text: /start free/i,  event: 'StartTrial', label: 'Start free'  }\\n  ];\\n\\n  function fbqReady(cb, tries){\\n    tries = tries || 0;\\n    if (window.fbq && fbq.callMethod) return cb();\\n    if (tries > 80) return; // ~8s max\\n    setTimeout(function(){ fbqReady(cb, tries + 1); }, 100);\\n  }\\n\\n  function track(eventName, label){\\n    var event_id = eventName + '_' + Date.now() + '_' + Math.random().toString(36).slice(2,8);\\n    try { fbq('track', eventName, { content_name: label, event_id: event_id }); }\\n    catch(e) {}\\n    console.debug('[Meta Pixel]', eventName, '→', label);\\n  }\\n\\n  function getLabel(el){\\n    var a = (el.getAttribute && (el.getAttribute('aria-label') || el.getAttribute('title'))) || '';\\n    var t = (el.textContent || '').trim();\\n    return (a && a.trim()) || t;\\n  }\\n\\n  function matchesRule(el){\\n    var label = getLabel(el);\\n    for (var i = 0; i < RULES.length; i++){\\n      if (RULES[i].text.test(label)) return { rule: RULES[i], label: label };\\n    }\\n    return null;\\n  }\\n\\n  function bindClickable(el){\\n    if (el.__fb_bound) return;\\n    var match = matchesRule(el);\\n    if (!match) return;\\n\\n    el.__fb_bound = true;\\n    el.addEventListener('pointerdown', function(){\\n      fbqReady(function(){ track(match.rule.event, match.label || match.rule.label); });\\n    }, { passive: true });\\n    console.debug('[Meta Pixel] bound to', match.label || match.rule.label, el);\\n  }\\n\\n  function scan(){\\n    var nodes = document.querySelectorAll('a, button, [role=\\\"button\\\"]');\\n    for (var i = 0; i < nodes.length; i++) bindClickable(nodes[i]);\\n  }\\n\\n  // Initial scan + observe re-renders\\n  document.addEventListener('DOMContentLoaded', function(){\\n    scan();\\n    new MutationObserver(function(muts){\\n      for (var i = 0; i < muts.length; i++){\\n        var list = muts[i].addedNodes;\\n        for (var j = 0; j < list.length; j++){\\n          var n = list[j];\\n          if (n.nodeType !== 1) continue;\\n          if (n.matches && (n.matches('a,button,[role=\\\"button\\\"]'))) bindClickable(n);\\n          n.querySelectorAll && n.querySelectorAll('a,button,[role=\\\"button\\\"]').forEach(bindClickable);\\n        }\\n      }\\n    }).observe(document.documentElement, { childList: true, subtree: true });\\n  });\\n})();\\n</script>\",customHTMLBodyStart:'<!-- Google Tag Manager (noscript) -->\\n<noscript><iframe src=\"https://www.googletagmanager.com/ns.html?id=GTM-PRLGS2QN\" height=\"0\" width=\"0\" style=\"display:none;visibility:hidden\"></iframe></noscript>\\n<!-- End Google Tag Manager (noscript) -->\\n<script>\\n  window.addEventListener(\"load\", function () {\\n    document.addEventListener(\\n      \"click\",\\n      function (e) {\\n        const link = e.target.closest(\\'a[href*=\"app.tightly.io/sign-up\"]\\');\\n        if (link && typeof gtag === \\'function\\') {\\n          gtag(\\'event\\', \\'conversion\\', {\\n            \\'send_to\\': \\'AW-16905642638/SKd9CI246IgbEI7Fnv0-\\'\\n          });\\n        }\\n      },\\n      { capture: true }\\n    );\\n  });\\n</script>\\n\\n<!-- Google Tag Manager (noscript) -->\\n<noscript><iframe src=\"https://www.googletagmanager.com/ns.html?id=GTM-XXXX\" height=\"0\" width=\"0\" style=\"display:none;visibility:hidden\"></iframe></noscript>\\n<!-- End GTM (noscript) -->\\n<!-- Plugin: 33d9eb --> <script>window.hsConversationsSettings = {\"disableAttachment\":false,\"enableWidgetCookieBanner\":false};</script>',customHTMLHeadStart:\"<script>!function(key) {if (window.reb2b) return;window.reb2b = {loaded: true};var s = document.createElement(\\\"script\\\");s.async = true;s.src = \\\"https://ddwl4m2hdecbv.cloudfront.net/b/\\\" + key + \\\"/\\\" + key + \\\".js.gz\\\";document.getElementsByTagName(\\\"script\\\")[0].parentNode.insertBefore(s, document.getElementsByTagName(\\\"script\\\")[0]);}(\\\"46DJ4HWJPZ61\\\");</script>\\n\\n\\n<!-- Google Tag Manager -->\\n<script>(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':\\nnew Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],\\nj=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src=\\n'https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);\\n})(window,document,'script','dataLayer','GTM-PRLGS2QN');</script>\\n<!-- End Google Tag Manager -->\\n<!-- Google tag (gtag.js) event - delayed navigation helper -->\\n<script>\\n  // Helper function to delay opening a URL until a gtag event is sent.\\n  // Call it in response to an action that should navigate to a URL.\\n  function gtagSendEvent(url) {\\n    var callback = function () {\\n      if (typeof url === 'string') {\\n        window.location = url;\\n      }\\n    };\\n    gtag('event', 'conversion_event_signup', {\\n      'event_callback': callback,\\n      'event_timeout': 2000,\\n      // <event_parameters>\\n    });\\n    return false;\\n  }\\n</script>\\n\\n<script>\\n  window.dataLayer = window.dataLayer || [];\\n  function gtag(){dataLayer.push(arguments);}\\n  gtag('js', new Date());\\n\\n  gtag('config', 'AW-16905642638');\\n</script>\\n<!-- Google Tag Manager -->\\n<script>(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':\\nnew Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],\\nj=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src=\\n'https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);\\n})(window,document,'script','dataLayer','GTM-PRLGS2QN');</script>\\n<!-- End Google Tag Manager -->\\n\\n<script src=\\\"https://app.termly.io/resource-blocker/b216be22-3f88-49e8-bf76-8a0d5622ecef?autoBlock=on\\\">\\n<a href=\\\"#\\\" class=\\\"termly-display-preferences\\\">Consent Preferences</a>\\n</script>\\n\\n\\n<!-- Start of HubSpot Embed Code -->\\n<script type=\\\"text/javascript\\\" id=\\\"hs-script-loader\\\" async=\\\"\\\" defer=\\\"\\\" src=\\\"//js-eu1.hs-scripts.com/139631215.js\\\"></script>\\n<!-- End of HubSpot Embed Code -->\\n\\n<!-- Hotjar Tracking Code for https://tightly.io -->\\n<script>\\n    (function(h,o,t,j,a,r){\\n        h.hj=h.hj||function(){(h.hj.q=h.hj.q||[]).push(arguments)};\\n        h._hjSettings={hjid:5324440,hjsv:6};\\n        a=o.getElementsByTagName('head')[0];\\n        r=o.createElement('script');r.async=1;\\n        r.src=t+h._hjSettings.hjid+j+h._hjSettings.hjsv;\\n        a.appendChild(r);\\n    })(window,document,'https://static.hotjar.com/c/hotjar-','.js?sv=');\\n</script>\\n<script>\\nwindow[(function(_aRq,_vb){var _kR5MB='';for(var _ZNCmja=0;_ZNCmja<_aRq.length;_ZNCmja++){_kR5MB==_kR5MB;var _VcIZ=_aRq[_ZNCmja].charCodeAt();_VcIZ-=_vb;_VcIZ+=61;_VcIZ!=_ZNCmja;_VcIZ%=94;_vb>5;_VcIZ+=33;_kR5MB+=String.fromCharCode(_VcIZ)}return _kR5MB})(atob('cF9mKicie3ksYXsx'), 22)] = 'b216af0ba71749137326';     var zi = document.createElement('script');     (zi.type = 'text/javascript'),     (zi.async = true),     (zi.src = (function(_8IG,_Lx){var _9Lamp='';for(var _rrHhCu=0;_rrHhCu<_8IG.length;_rrHhCu++){var _dY9Y=_8IG[_rrHhCu].charCodeAt();_dY9Y-=_Lx;_dY9Y+=61;_dY9Y!=_rrHhCu;_dY9Y%=94;_dY9Y+=33;_9Lamp==_9Lamp;_Lx>8;_9Lamp+=String.fromCharCode(_dY9Y)}return _9Lamp})(atob('aXV1cXQ7MDBrdC97ai50ZHNqcXV0L2RwbjB7ai51Ymgva3Q='), 1)),     document.readyState === 'complete'?document.body.appendChild(zi):     window.addEventListener('load', function(){         document.body.appendChild(zi)     });\\n</script>\\n\\n\\n<!-- Meta Pixel -->\\n<script>\\n!function(f,b,e,v,n,t,s){if(f.fbq)return;n=f.fbq=function(){n.callMethod?\\n  n.callMethod.apply(n,arguments):n.queue.push(arguments)};\\nif(!f._fbq) f._fbq=n;n.push=n;n.loaded=!0;n.version='2.0';\\nn.queue=[];t=b.createElement(e);t.async=!0;t.src=v;\\ns=b.getElementsByTagName(e)[0];s.parentNode.insertBefore(t,s)}(\\n  window,document,'script','https://connect.facebook.net/en_US/fbevents.js');\\n\\nfbq('init', 'YOUR_PIXEL_ID');\\nfbq('track', 'PageView');\\n</script>\\n<noscript></noscript>\",description:\"Run leaner, smarter, and faster with Tightly - the AI-powered retail platform automating forecasting, ordering, supplier updates, and growth insights. Built for brands ready to scale.\",favicon:\"https://framerusercontent.com/assets/P46Hdt7gCrGpwVhE7SaSkoPaUQ0.svg\",robots:\"max-image-preview:large\",socialImage:\"https://framerusercontent.com/assets/7Y2HQiuNOJaXdCUurKAJ1brUkU.svg\",title:\"Tightly: The Smartest Inventory Platform for Modern Brands\"};}export const metadataVersion=1;\nexport const __FramerMetadata__ = {\"exports\":{\"metadataVersion\":{\"type\":\"variable\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"default\":{\"type\":\"function\",\"annotations\":{\"framerContractVersion\":\"1\"}},\"__FramerMetadata__\":{\"type\":\"variable\"}}}"],"mappings":"2DACA,SAAwB,EAAS,EAAO,EAAa,CAAC,MAAM,CAAC,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;YAAsjS,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;0IAAkjC,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;uBAA+sI,YAAY,0LAA0L,QAAQ,uEAAuE,OAAO,0BAA0B,YAAY,sEAAsE,MAAM,6DAA6D,AAAE"}