J.S.
Wow... I don't know if I missed an earlier post, you might have talked about this before and I just don't know it.
Have you talked to your doctor about this? 3L of water is a LOT of water every day. 1 cup of coffee shouldn't be a problem.
Please, my suggestion is to call your doctor and let him know what's going on. There may be a different issue completely unrelated to hydration.
Wishing the best for you...