[Moto G4 Plus Questions & Answers] echo92:
1) TWRP flashes of a build generally only update your system, not the firmware underneath. So though you flashed the NPJ25.93-14-5 build via TWRP, your system is at the June 2017 level but your bootloader is still likely at the March 2017 level. I don't think you have fully updated your device to the June patch. Only stock firmware flashed via fastboot or official OTA updates can update the underlying firmware, and you mentioned the OTA failing to patch your device previously.

2) you can check the bootloader version by powering down your device, then hold down the power and volume down keys to get to the bootloader screen. There, one of the top lines on display should say what version you have (e.g B1.05 for March 2017). I don't know of a way to check bootloader status in TWRP.

3)I recall your initial boot issues, which likely meant the OTA did not install anyway. It's still odd how the TWRP backup you applied did not include the stock boot image though and only gave you ElementalX. Did you opt to restore boot (kernel) as well as system when you used the TWRP backup and where did you get the stock boot image btw? Was it included in the TWRP backup? Hopefully the stock boot image was from the TWRP backup and not from a previous March 2017 backup, I'm not sure if using boot kernels from different builds works...

4) given the current state of your device, I'd honestly suggest flashing the March 2017 retail firmware onto your device, make a clean start. Yes, it'll be painful and will mean having to back up your device. However, from what you've mentioned, your device appears to have boot failure due to rooting of the stock Motorola kernel, which would trip the anti rooting protections built into the stock kernel when magisk was flashed. To the best of my knowledge, once they're tripped, you'll have to reflash the stock ROM.

You may be able to save your data and internal storage by using the following fastboot commands to flash the stock ROM, they will wipe TWRP and root, but should get your device operational and be ready for the OTA. Back up and be prepared to factory reset your device if it proves unstable.

fastboot flash logo logo.bin
fastboot flash boot boot.img
fastboot flash recovery recovery.img
fastboot flash dsp adspso.bin
fastboot flash oem oem.img
fastboot flash system system.img_sparsechunk.0
fastboot flash system system.img_sparsechunk.1
fastboot flash system system.img_sparsechunk.2
fastboot flash system system.img_sparsechunk.3
fastboot flash system system.img_sparsechunk.4
fastboot flash system system.img_sparsechunk.5
fastboot flash system system.img_sparsechunk.6
fastboot flash system system.img_sparsechunk.7
fastboot flash modem NON-HLOS.bin
fastboot erase modemst1
fastboot erase modemst2
fastboot flash fsg fsg.mbn
fastboot erase cache
fastboot reboot

If used with the March 2017 retail firmware, should bring your device back to its original firmware, still unlocked and a stock kernel, stock recovery and unmodified system, ready for accepting OTA updates. As it's all from the March 2017 update, the file signatures should match what the update is expecting and should flash, bringing you formally to the June 2017 update. Of course, this should also update your bootloader and other underlying firmware, so downgrading once you've installed the OTA in stock recovery (not TWRP, OTA updates are not accepted in TWRP) is not advisable.