In in-universe time, how long did the "first" part of the movie last?
It's never stated. However, judging by the amount of different coloured diary logs in Taki's phone, it's likely to be that they switched for at least 2 months. The section where Zen Zen Zense plays can't be used as reference as it is unlcear as to when each event happened.

In terms, I'd say that they took a week of switches to realise the changes, and took another month getting completely used to it. Add a month after that, and that should fufill the timeline.