Here is a nice rainbow animation as a shadow for a div content. When you hover over it the div pulls in all the shadow elements to form a single card. By Sarah Fossheim.
If you are having trouble with the pen, try the archived copy on GitHub
Shadow Grid Snippet
See the Pen Rainbow stacked accordion animation by Sarah Fossheim (@fossheim) on CodePen.dark