I have got somewhere, thanks to this post discussing a similar-ish challenge.
In essence, the problem seems to lie in the fact that the filename in the URL is the filename I am loading, e.g. /files/example.pdf to retrieve example.pdf
If I remove the file extension from the URL, I am then able to return the pdf file correctly. I am not sure what configuration is going on with my server that is causing this discrepancy (I assume it's something to do with the server configuration, because I did not hit this problem in my local docker dev environment)
Anyway, I thought I should post an update for anyone who does stumble across this in the future. And of course if anyone has any ideas as to what to do resolve this, I'd appreciate any guidance available!