If I understand your question correctly, then it's a matter of joining the code from two answers from the following Questions of this Stack:
This is the result, top-level categories are converted to radio buttons, so only one can be selected.
The caveat is that sub-categories from other top-level categories can be selected as well.
As I mention in my answer to the second Question, Scribu's plugin, Category Checklist Tree, is almost a necessity for this scenario.
I'll not repost the full code, it's just a matter of replacing this lines:
For this ones:
this.type = 'radio';
Attention to the ID of the
For knowing which category is the "main category", from all selected parents or children, I can only think of a Custom Field to hold this information.
This could be solved programmatically, creating a new Meta Box, displaying a dropdown list with all categories, and saving this as post meta (
And with a plugin, this can be done with Advanced Custom Fields and the Taxonomy Field add-on. Which results in: