Things are much more complicated than when I was a kid in the 1970s. I inherited some of my Dad's 1950s HO train parts and built around that.
I had a transformer that supplied power for lighting (tiny scale brass streetlights) and lights inside the buildings. Very simple, much like a battery. One side was 12V+ and one side was 12V-. Attach the wires and switch it on. As I recall it also supplied power to track switches. Track switches, plus momentary buttons from Radio Shack, and power from the transformer allowed me to direct the trains onto one of two alternative loops. My layout had the main loop, an outer loop with elevation (hills), and another loop through a styrofoam tunnel that cost about $3 back then.
For train control I had a second transformer with a lever and a switch. Lever controlled the locomotive speed, the switch controlled the direction. It was up to the operator to be as realistic (or not) as they wanted to be. Start slow or not. Transformers like those and the one for lighting got warm from use so they had to be unplugged when the train was not used.
As impressive as the new digital controls can be - it
might be pretty intimidating for a beginner. Maybe not.
Benefits of starting this hobby in 2024 is all the used trains probably available as people age out of the hobby. The internet is still an amazing resource for hobby information. YouTube videos can either be a source of ideas or wear off the newness of the hobby i.e. satiate the fascination and bring a person's interest to a halt.
As a kid I had a ton of fun assembling buildings and laying out the track and town. I used all sorts of mismatched toys at first. Legos, Lincoln Logs, Matchbox cars, and Erector Set projects. Then I caught a bug that drove me to seek realism and I started studying historical picture books to see what things really looked like. My budget was thin and we lived far from the places where I could source crafting supplies so I used cereal boxes turned inside out, ink markers and later model car paints.
Now you can have fun with LEDs which are much safer than miniature incandescent bulbs of the past. Less chance of a fire anyhow. Power supplies are likely loads better as 2sk22 described. I wouldn't be afraid to use an old school transformer speed control as long as it was unplugged (power strip) when not in use.
Budget 3D printers, hobby grade lasercutters and websites like Thingiverse, GrabCAD and a dozen others can supply free models to print. Open-source software like Linux, Inkscape, FreeCAD-3D, and TrackCAD mean the sky is the limit as your child grows up. The hobby can be as intricate as they want it to be.
https://xtrkcad-fork.sourceforge.net/Wikka/HomePage https://inkscape.orghttps://www.freecad.orghttps://kubuntu.orgMakes me want to return to the hobby but I have far too many fascinations already. ;) Have fun!!!