The gold foil image is used as the Mix Shader’s factor input, with its interpolation set to “Non-Color.”
That’s not a Black&White Image and doesn’t work as a Mask. A Math Node to the rescue:

Non-Color just means that no Color Transform is being applied to the Image, not that it’s being turned into a B&W Image or so.