Added search functionality with pagination