What is the appropriate formula?

I would like cell D4 to turn green if:
C4=F1

I would like cell D4 to turn red if:
M4>7

I would like cell D4 to stay empty (or white) if:
M4<7 or if C4 is empty