About the AI, could it be an idea to assign AI's to different regions, like a france AI, Italy AI, Iberian AI, British AI, Scandinavian AI, German AI, etc. In the real world, nations in the same regions often share the same targets, which is basicly control in that region.
In Iberia, the AI would focus on gaining control in Iberia and establishing coloninies, since this was both portugal and spain aims
Scandinavian countries would focus on contolling Iberia and expanding eastwards into Finland, Karlern and Baltic states, which would be reasonable for Sweden, Norway and Denmark.
Scotland, England and Ireland would try to gain power on the british islands and colonice North-America.
Italian states would go for Italy and gain economic supremacy in the mediterian sea.
What I am really thinking on is that you could make arrays to check what would be the best AI for that nation, to avoid the problems you worried about when it came to Denmark suddenly developing an interest in Spain.
If the arrays should consist of the tags for nations in a region, or the arrrays should contain the provinces so that one could check against where the capital, is something that I'm not sure of. Both would have it's pros and cons.