Stylised water intersection foam bugging

I have been messing around with shader graph, and found some really weird graphical bugs when trying to add intersection foam to my water shader. here is the tutorial I used for this effect: https://www.youtube.com/watch?v=NHy3rSKtRmc. but as you can see it isnt really working.

Here is the video of the issues: wacky.mp4 - Google Drive

My GPU is a radeon 6500 xt, if that helps.

edit: I have updated all my drivers and restarted my computer, no luck.