https://www.google.com/search?client=firefox-b-d&q=p1336Crankshaft position sensor?
The way these cars eat chains, and that Mazda keeps fitting the same part, may mean that the chain is where the problem emerges but the root is somewhere deeper.
If I remember well, there was somebody with two plus the original chain done within 50k or so.
When part exchange values and auction cars are around £500, it may be worthy keeping a collection and using them as parts cars.
Let's hope that you will not need another chain and it will be something simple.