Core structuring tip: your under-the-hood code should import Foundation and not AppKit or UIKit. Even if you never plan to go cross-platform, this should be the rule, because any app benefits from this separation.

(There are exceptions: image-handling code, for one.)