'use client' import { ReactNode, useEffect } from 'react' interface ModalProps { open: boolean; onClose: () => void; title?: string; children: ReactNode; maxWidth?: string } export default function Modal({ open, onClose, title, children, maxWidth = 'max-w-lg' }: ModalProps) { useEffect(() => { if (open) document.body.style.overflow = 'hidden'; return () => { document.body.style.overflow = '' } }, [open]) if (!open) return null return (