import { Routes, Route } from 'react-router-dom';
import LandingPage from './pages/LandingPage';
import DashboardLayout from './pages/Dashboard/DashboardLayout';
import Login from './pages/Login';
import Register from './pages/Register';
import { Toaster } from 'react-hot-toast';
import { NotificationsProvider } from './context/NotificationsContext';

const App = () => (
  <NotificationsProvider>
    <Toaster position="top-right" toastOptions={{
      style: { background: '#1a1a2e', color: '#fff', borderRadius: '12px', border: '1px solid rgba(255,255,255,0.1)', fontSize: '14px' },
      success: { iconTheme: { primary: '#00d4aa', secondary: '#fff' } },
      error:   { iconTheme: { primary: '#ff4d6d', secondary: '#fff' } },
    }} />
    <Routes>
      <Route path="/" element={<LandingPage />} />
      <Route path="/login" element={<Login />} />
      <Route path="/register" element={<Register />} />
      <Route path="/dashboard/*" element={<DashboardLayout />} />
    </Routes>
  </NotificationsProvider>
);

export default App;
