I've had problems with this since I bought a desktop with Vista installed 4 years ago (Gateway refused to install XP). I found this Microsoft register change that cleared the problem for me, so I thought I'd pass it on.

Wireless keyboard and mouse become unresponsive

If your wireless keyboard and mouse remain unresponsive for a long while after you resume from sleep or hibernation on a Vista SP2 or Windows 7 computer, it is likely because the USB host controllers are not being correctly handed off to the operating system. You can fix the problem with a registry edit, as described in KB article 969711.