How long did the first phase of fighting last?