This version calls a secure backend: /.netlify/functions/generate.
/.netlify/functions/generate
If you get an error, check Netlify → Functions logs.