In case Emirates has an interline agreement with Copa you will not have any problems checking your baggage all the way to final destination, especially because it is all in one ticket. You have to check with Emirates.
In case you manage to check your baggage to final destination, you do not need to claim you luggage and therefore do not need to clear immigration. If you want to rest while you wait for your connection, I recommend FAST SLEEP which has showers, spa, and rooms you can rest. It is located in the tunel which links both GRU terminals near the business lounges of airlines.
On the other hand, why dont you apply for a Brazil VISA in Islamabad?
Enjoy your trip!
Rgs,