Firmware is software that runs on Read-Only Memory (ROM) or something similar. Firmware is firmer than software because software can be changed somewhere along the chain from where it is stored in some Read-Write media and loaded into writable memory and executed from there.
Firmware cannot work as in-place self-modifying code. Software can run as in-place, self-modifying code.
If you can think of a ROM and as some form of programmable hardware, then "firmware" is a form of hardware. If you can think of an FPGA as some form of programmable hardware, then you can think of FPGA Verilog and the like as a form of "firmware".
As time marches on, the lines between software, firmware, hardware get blurred more and more.