Viñales snatches pole from Dovizioso at Misano