Nowhere does that even suggest that Mexicans have to return to Mexico within 24 hours if they drive here from Mexico. That’s just not a law. I have no idea why you think Mexicans can’t legally drive from Tijuana to New York City, but they can, despite that taking over 40 hours.
They can even drive to Toronto. That would take even longer. And then they can go back through Canada and through the U.S. and back to Mexico and they can stay in the U.S. as long as their travel visa allows.
I have no idea why you think they can only get 12 hours from Mexico by car before they have to turn back.