Basically, flash carts all rely on a profile exploit that was in system firmwares 4.1 through 4.5 This exploit allows the launching of code that is not Nintendo's. This exploit is the very foundation of 3DS flash carts. It was patched in firmwares past 4.5, meaning if your system's firmware were to go past 4.5, it would be impossible to access the flash cart at all. Therefore, you would not be able to access the eshop or anything that required a firmware greater than 4.5 because it would lose Gateway access.
Since you have to have 4.1 to 4.5 for Gateway in order to use it (with no exceptions), but would ALSO need a greater firmware in order to play newer games as well as access online features such as eShop, EmuNAND was created. EmuNAND is literally a copy of your system's firmware that runs from your SD card instead of your actual system's internal storage. The console can't tell any different, but it is actually from a different source entirely, and operates independently. If you download a game on your emuNAND, it is saved to the SD card copy and will not show up on your regular internal NAND copy of the 3DS. It is the same case with your internal firmware. If you downloaded or installed something on your regular internal NAND, it will not show up on emuNAND.
The emuNAND can only be accessed after having running unsigned code, so the emuNAND itself does not need to actually have the profile exploit anymore. Therefore, you can update this emuNAND to newer firmwares like 6.X and 7.X and take advantage of being on the newer firmware. The system's internal firmware just remains on 4.X in order to be a "gateway" (via the profile exploit) to launch a modified, newer, emuNAND where you will do all your future operations from.