Here are the relevant steps to play a spell. More details are found in 409 in you CompRules:
Announce you're playing the spell. Put it on the stack (409.1a).
Pay costs and choose modes. In this case, you're deciding to reveal an Elf card. (409.1b).
Determine the total cost. (409.1f).
409.1g If the total cost includes a mana payment, the player then has a chance to play mana abilities (see rule 411, “Playing Mana Abilities”). Mana abilities must be played before costs are paid.
409.1h The player pays the total cost in any order. Partial payments are not allowed. Unpayable costs can’t be paid.
The spell is now played. (409.1i).
So no, you have to play mana abilities before you pay the costs.