If I’m coming out of the U.S. and into Canada, do I follow Canadian laws or U.S. laws when I get here? May I drive 13 hours or do I shutdown after 10?
You operate according to the laws of which ever country you happen to be in. When in the US, it’s the American rules. In Canada, you follow the Canadian rules.
Lets say you're on a trip north from Kansas City to Toronto. You've got 9.75 hours driving when you get to the border. As soon as you cross the border, you've got another 3.25 hours left to drive.
Now reverse the situation. Say you're driving from Montreal to Chicago. It takes you 9 hours to get from Montreal to Detroit. As soon as you cross the border, you'll have 1 hour left to drive.