2.2. The tense in the conditional adverbial clause guided by if should be the simple present tense, indicating the meaning of the future.
3. The main clause is the past tense, and the clauses use the corresponding past tense. The dream they had lasted from a certain moment in the past until they were asked. The action of "dream" was always in progress, so the past perfect continuous tense was used.