Using IF() to calculate overtime

I’m using Calc to find overtime in hours and minutes.
D6 is the calculated HH:MM (C6-B6, end time - start time) during the day and I’d like to find how many hours+minutes (if any) there are over 12. Actual result of D6 is 12:28. Therefore the result of D7
=IF(D6>12;D6-12;0) should be 00:28.
The results I’m getting is 00:00 whether D6 is more or less than 12.
Using text to search for errors:
=IF(D6>12;“right”;“wrong”) gives me “wrong” no matter if D6 is larger or smaller than 12 so it does not Test correctly.
If I use simply =D6-12 it gives me the result of D6 (12:28) instead of giving me 00:28
Is it a format error or something else?

Thank you.

Version: 7.2.5.2 / LibreOffice Community
Build ID: 499f9727c189e6ef3471021d6132d4c694f357e5
CPU threads: 16; OS: Mac OS X 12.3.1; UI render: default; VCL: osx
Locale: is-IS (en_US.UTF-8); UI: en-US
Calc: threaded

Time values are fractions of days, your 12 is 12 days == 288 hours. You want to compare against 0.5 instead.

And you are the Genius of the day Mr. [erAck].
Thank you. This solved it. Wonderful.