Thanks, I took a lot of flak from my colleagues and it was always treated like this wart on the outskirts of our COE. The only other options required discarding two month's work and refunding the client, or investing another few weeks building a bespoke PDF generator for this one use-case. I never really saw it as a heroic exercise, just had to think of a way to save everyone's time, money, and reputation in the fastest, safest, most reliable way possible.
I never got a compliment for the solution (just a "okay if you think we can make it work go ahead", and afterwards a "nice work, let's hope it doesn't break") so this is a first. Thanks again.