'use client';

import dynamic from 'next/dynamic';

// Code-split the support widget out of the initial page bundle — it pulls in
// socket.io-client and opens a live WebSocket connection on mount (see
// useSupportSocket), which otherwise happens on every single page load before
// the user ever opens the chat. next/dynamic + ssr:false must be called from a
// Client Component (disallowed directly in a Server Component like layout.tsx),
// hence this thin wrapper.
const SupportWidget = dynamic(() => import('./SupportWidget'), { ssr: false });

export default SupportWidget;
