Importing with parameters, or switchable templates

Thank you! This way of doing this is very new to me so I appreciate the help very much.

This seems very close to doing what I want, and the problem isn’t with this at all; it’s a knock-on effect.

I have another bit of code which places logos next to certain bits of text. I’d finally got that apparently working. However, moving the logo size definitions into the template function means that no longer works as it can’t access the sizes.

I’ve tried moving the logo-placing function inside the template so it can access the logowidth etc., but then it’s no longer visible to the function calls in the main document. Feels like a bit of a catch-22. Do you have any suggestions?

If absolutely necessary I can hardcode the logo width to a single size and just deal with it, so it’s not a disaster if we don’t have a solution.