"Jogging for three miles" is a gerund verbal phrase which functions as the subject of the sentence. This verbal phrase is formed by a verbal or a gerund that functions as a noun (NOT AS A VERB) and a participial phrase (for three miles) which functions as a complement. Besides, gerund phrases always present verbs ending in -ing plus any modifiers, objects or complements.