Customizing menubar popup


I need to create a custom menubar where the popup menu after the first click has a border / background which can encompass both the second and third level elements.
The attached image shows an example of what I am trying to accomplish.
I have been struggling trying to find a way to acheive this and have not found any solution, any help would be greatly appreciated!


Here is the sampleā€¦