No heating elements work on cooktop or in ovens everything else is still working

Sounds like a power problem.
The light, control board etc. all run off of half the line 120 volts.
But all the elements require the full 240 volts.

The 240 is controlled for the oven by the control board and the stove top elements by the individual infinite switches so it is near impossible for all the control devices to go bad at the same time.

Try flipping the breaker off/on slowly a couple times. Sometimes you can loose half the line without actually tripping the breaker.
Check the voltage at the plug
L1 to L2 should be 240 volts
L1 to Neutral and L2 to Neutral, both should be 120 volts.
If OK
Unplug the unit and check the wires at the terminal strip in the machine to make sure none are loose or burned out
If OK
Check the power at the terminal strip.
Do this with the heater off and on.
[COLOR=“Red”]Be careful as 240 volts is lethal !!![/COLOR]