"The Hidden Heart" (裏の心, Ura no Kokoro) is episode 392 of the Naruto: Shippūden anime.
As the tailed beasts go into battle against Madara, Gaara and Shukaku lead the way using a cooperation ninjutsu on the Uchiha, which momentarily manages to immobilise him. The other tailed beasts follow suit with fiercetechniques. Using its body as a medium, Shukaku seals Madara away, but before it could finish, the latter breaks free via Susanoo before being intercepted by Naruto and jointly tail-whipped by the tailed beasts. A White Zetsu Army clone emerges from the ground, giving Madara his original right eye. Now with his Rinnegan restored, Madara brings forth the Demonic Statue of the Outer Path as it emerges from Obito's body. Kakashiattempts to stop the statue but only manages to amputate one of its arms. Standing atop the statue, Madara executes a technique which repels the tailed beasts all at once. He then has the statue unleash its chains to restrain them, and plans to extract the Eight and Nine-Tails. As the targeted jinchūriki continue to battle against their restraints, Naruto attempts to exit Tailed Beast Mode, but finds that he is unable to suppress Kurama's chakra. Deeming Naruto's efforts futile, Madara redirects his attention to Shukaku. Gaara forms two enormous sand hands to stop the chain from dragging the One-Tail. The tanuki, shocked that its former host would defend it, recalls its time with the young Kazekage. Shukaku also remembers its conversation with its previous jinchūriki Bunpuku, and finally realises that Gaara is the one whom the priest had foretold. Activating his Susanoo, Madara launches a sword at Gaara, but Shukaku deflects it in time, declaring that it prided itself on its absolute defence after all.