There could be several possible reasons why your Honda XR250R is turning off when the engine is warm:
Fuel Delivery Issues: Despite cleaning the carburetor and hoses, there may still be some residual clogs or blockages affecting fuel flow. Ensure that all fuel passages are thoroughly cleaned and that the fuel tank and lines are free from debris or restrictions. Additionally, check the fuel filter for any signs of clogging.
Carburetor Adjustment: The carburetor settings may need to be adjusted to ensure the correct fuel-air mixture. Proper synchronization of the carburetor components, such as the idle mixture screw, float level, and jetting, can help resolve fuel-related issues.
Ignition System Problems: The intermittent issue with the high beam of the headlight and the engine stalling could indicate an electrical problem. Check the wiring connections, switches, and ignition components, such as the spark plug, ignition coil, and CDI unit, for any loose connections or faulty parts.
Overheating Issues: Monitor the engine temperature and make sure the cooling system is functioning properly. Overheating can cause engine stalling. Ensure that the cooling system is clean, the coolant levels are correct, and the radiator and fan are working as they should.
Vacuum Leaks: Inspect all intake and vacuum lines for leaks or cracks. Any vacuum leak can disrupt the fuel-air mixture and cause engine stalling.
Other Potential Causes: Other potential causes could include a faulty fuel pump (if equipped), a malfunctioning petcock, or a problem with the electrical system, such as a faulty regulator/rectifier or charging system.
It's recommended to systematically troubleshoot and address each potential issue. If you are unsure or unable to diagnose and fix the problem, it's advisable to consult a qualified mechanic or Honda dealership who can provide expert assistance and diagnose the specific issue with your Honda XR250R.