The front gear rings are
chainrings. The cogs are the gears in back.
Your description sounds like the drive-side crank arm is loose and wobbling on the bottom bracket spindle. The aluminium crank interface will quickly wear out of square against the harder steel spindle. Once worn enough, the crank arm won't fit securely again, and replacement will be necessary. If yours moves enough to cause the chain to derail, I suspect it's beyond hope.