If you’re worried about any part of the car overheating specially transmission and engine then you’ve got the wrong vehicle and there are major design flaws in it.
You can run today’s vehicles practically endlessly as long as you keep refueling your tank when it gets empty. Just keep coolant at the right level.
Drive for not only 5 but 10 hours and it doesn’t matter.
Just your own physical health and sleep matters. Your body and legs need some stretching after say 3-4 hours of driving so take stops to drink refreshments or bathroom breaks.
Drive 12 hours in a day then stay somewhere to sleep OR
change drivers and continue driving the same car it doesn’t matter it will not overheat or affect anything.