Hm, yes, it's easily overlooked – (by me perhaps).
My reference book gives the following:
3 basic conditionals
- if + present will + infinitive
- if + past would + infinitive
- if + past perfect would have + past participle
The latter one corresponding to your sentence.
Regards
Dok