Moved passphrase modal functions to helpers