/**
 * @fileoverview React component for main.jsx
 * 
 * @module main
 */

import React from "react";
import ReactDOM from "react-dom/client";
import "./blockly/blocklyConfig.js"; // Configuração global do Blockly (locale PT-BR)
import App from "./App.jsx";
import { initGoogleConsentMode } from "./services/analytics";

// Initialize Google Consent Mode before loading analytics
initGoogleConsentMode();

// Log de versão para rastreabilidade em produção
if (import.meta.env.PROD) {
  console.log(
    `%cDecoda v${import.meta.env.VITE_APP_VERSION} (${import.meta.env.VITE_GIT_HASH})`,
    "color: #2563eb; font-weight: bold; font-size: 12px;"
  );
}

ReactDOM.createRoot(document.getElementById("root")).render(<App />);
