@sam105,
I am not a woman but I will agree that her behavior seems to suggest that she doesn't want you to see what she has been writing. However, that doesn't mean she is writing to a lover. She could be writing to a friend and telling her how miserable she is in her marriage. That's not much of a consolation, I know, but there could be something with that you can deal with and repair.
There could be a number of things she is communicating with someone about that do not involve her having sex with someone else, but she doesn't want you to see. Some which may surprise you. Some people just don't like to have anyone looking over their shoulder, or may exaggerate or elaborate in a story told which would prove embarrassing if a person who knew the story first hand read it. Or she could be conversing about a career change of which she thinks you would not approve. The point is there are other reasons than an affair.
The fact that she has been distant, and there is no romance or sex in your marriage should be the focus of your concern.
I suggest you ask her to talk to you about it (without getting defensive or fighting); just the two of you, or with a counselor (who can't come up with magic answers but can help keep the conversation calm and on track.)
Trying to violate her privacy by hacking her phone or I-pad is only going to be of any value if your worst fears are realized, (and the dubious nature of that value is obvious) but if she didn't lie and she finds out you've been spying, you could really put the final touch on a troubled relationship.