I only know the basics, and I am not as deep as our veterans here.
So I will just use that.
A hardware wallet is downloadable or you could just save a clear copy if you want to. The .exe file or whatever it is that had not been used yet.
That means, you could use it offline if it is saved in a flash drive.
Create your address, save your private keys and seeds without the need of the internet.
It's better if your seeds are written in a piece of paper.
Now, your computer is compromised.
You just use the flash drive to open the hardware wallet again. Note: You haven't input your seeds yet. It is still in that piece of paper.
Enter that while offline then Voila! you can access your account again.
You don't really need the hardware for the whole run.
You just need it in the starting line and finish line.
You got it entirely wrong as far as I am concerned. Hardware wallets are not downloadable. They're literally pieces of hardware.
If you're referring to apps such as Ledger Live, these are just wallets to check balances and initiate transactions
with the HW. You could use a lot of other apps and sites, including Waves DEX, Binance, Electrum, Magnum Wallet etc. There is no need to save anything anywhere besides the seed your Ledger shows during the first-time setup. You just write that seed down and store it somewhere safe.
Private keys are usually not scrapped from the Ledger for security reasons. As long as you have the seed, it's enough to recover all your balances.
Even with a compromised computer, the HW is known to be safe - while the PC's screen might fool you, the hardware wallet's won't. If the PC is infected so that the transactions only
show to be correct while in reality the destination wallet is a thief's, your hardware wallet will always show the real destination one and requires your physical input to confirm or decline the transaction.
But besides checking wallet balances, you basically need the wallet the entire time. You have to confirm addresses, transactions etc using it.
And what bad do encrypted text files have? Like txts in rars. In a PC that no one ever touched you download Winrar and add to archive the csv file of the private keys. You put a very strong password that can remember. And you save it to different places with a name that isn't suspicious.
Disk failure. I always fear that scenario. Another concern I personally have is that a vulnerability might be found someday for encrypted archives and my money would just suddenly be transferred into another wallet just because I held my seed/wallet.dat in an archive and someone got in touch with it. I don't trust digitally stored personal stuff.
And why would you like to import your seed to electrum since you have the strong hardware?
That is in case you lose your hardware wallet like you said and cannot purchase another one for replacement. You can simply recover everything using your seed, or just buy another wallet. Ledger has 3 PIN tries before it automatically resets, so in case you lose it you'd need someone who knows what a Ledger is who also knows an unknown physical vulnerability in order to have it compromised. Otherwise, you could lose 10 HWs with the same seed on them all and you'd still be perfectly fine.