Caffeine can make people jittery and cause fast and sometimes anbormal heart rhythms. It sounds like you should stay away from caffeine. Reasons to seek a doctor would be if you are having passing out or near passing out episodes, palpitations, or if there's a history of young people dying suddenly in your family.
The total duration of treatment depends on the complexity of the treatment and is generally comparable to that of traditional braces. Typically treatment can last between 9 and 18 months. During your consultation, your Invisalign Provider can provide you with more detailed information.
If your dentist is recommending three weeks of Invisalign wear per tray he could be using another product other than Invisalign. There are other clear aligners on the market and at least one of them recommends three weeks of aligner wear instead of the traditional two weeks recommended by Invisalign.