Install New Lyric T5 on second AC, first one went great, this ones confusing, help!
Rc and Rh – split connections for 24vac if the system has separate cooling and heating control transformers, respectively.  Most systems have a single control transformer on the heating side only and in that case Rc and Rh usually are shunted together at the thermostat as shown.

Elec/Gas – this is a label for the switch below the labeling, not the wire terminals above.  If you do not have a gas furnace, this switch should be set to “elec” as shown.

Blu + Ylw wires – these look like they are connected to the thermostat terminal marked “Y”.  Look above the lower set of terminals under the wires.  “Y” energizes the compressor for cooling mode.  “W” normally energizes the furnace, but since you have a heat pump these wires are shunted together (compressor needs to be on in either cooling or heating mode).

Wht + Grn wires – one of these probably runs to the “O” terminal and the other runs to the “G” terminal.  I cannot tell which is which from the thermostat photo.   Based on the other photos, green connects to “G,” which controls the indoor blower and is typical wiring.  “O” controls the reversing valve.  When “O” is energized, the outdoor unit is in cooling mode.  When “O” is not energized, the unit is in heating mode.  In rare cases the terminal is marked "B" instead of "O," which has complimentary functionality relative to "O."

C wire – Based on the above photos, the black wire is in the bundle of thermostat wires somewhere, probably hidden behind the thermostat as you suggest.