The correct option is B It is wonderful to go to the hills in summer.
The basic order of words in a sentence is: subject + verb + object.
A sentence may not contain an object, depending on the verb. Transitive verbs like 'appear', 'die', etc do not require objects.
To this basic structure, different elements can be added. For example, noun phrases, adjective phrases, subject complements, types of clauses and so on.
Option B: The structure in this sentence complies with the basic structure:
subject (It) + verb (is) + subject complement (wonderful) + infinitive phrase (to go to the hills) + adverb phrase (in summer).
Hence B is correct.
Option A: An infinitive phrase does not precede the subject, unless the phrase itself is the subject. Hence A is incorrect.
Option C: Similarly, the adverbial phrase and infinitive phrase do not precede the subject. Hence C is incorrect.
Option D: The phrase "in the summer" indicates time. Adverbs of time usually go at the end of the sentence. Hence it should follow the infinitive phrase here. So, D is incorrect.