Cabrera's 4 hits help Giants beat Marlins 3-2