Hi and welcome to the forum
for "normal" time, try this...
=IF(AND(OR(B3<7/24,B3>19/24),OR(B3>19/24,C3>19/24)),0,IF(B3<=7/24,IF(C3>19/24,19/24,C3)-7/24,IF(C3>19/24,19/24,C3)-B3))
For OT, try this...
=IF(B3<7/24,B3,0)+IF(C3>19/24,C3-19/24,0)
Test with a range of times and let me know how you make out?
Bookmarks