@skyblond There was a similar problem with AMS and some other package I had to use. I believe they both go in the beginning of the tex and \beginpackage should work. If it doesn't it might need to be nested or the \endotherpackage needs to precede it.
@skyblond I'd recommend a custom template or browsing templates used by different Universities and researchers. I remember having to make a Mitre Attack graphic with Tex.
The templates aren't too difficult to make but it is likely that many people have encountered the same problem. There's likely a template from a University that fixes it.