import React, { StrictMode } from 'react'
import { createRoot } from 'react-dom/client'
import { BrowserRouter } from 'react-router-dom'
import App from './App.jsx'
import { initClarity } from './lib/clarity.js'

// Ensure React is available globally
if (typeof window !== 'undefined') {
  window.React = React;
}

// Initialize Microsoft Clarity if configured
initClarity()

createRoot(document.getElementById('root')).render(
  <StrictMode>
    <BrowserRouter>
      <App />
    </BrowserRouter>
  </StrictMode>,
)
