Leeds fielded a patched-up side, including17-year-old debutants Max Simpson and Jack Sinfield, but hit back from 8-0 down to go into the final quarter all square.
The sin-binning of Leeds second-rower James Bentley proved costly, but they were in the contest until the final seconds.
A major concern for Rhinos was a head injury suffered by stand-off Blake Austin, which leaves them without any experienced half-backs for Friday's crucial visit of Toulouse Olympique.
Here's how the Rhinos players rated, plus marks for the Castleford side and referee.
1. Liam Sutcliffe (squad number 4)
Liam Watts got past him for the crucial try, but he had a solid game out of position at full-back 7. Photo: Tony Johnson
2. Tom Briscoe (No 20)
Switched back to the wing, where he's probably most at home, but had no running chances 5. Photo: Steve Riding
3. Max Simpson (No 28)
The 17-year-old debutant didn't see much ball, but ran strongly when he got it and didn't looked fazed 7. Photo: Allan McKenzie/SWpix.com
4. Alex Mellor (No 15)
Filling in out of position at centre, couldn't make a big impression on the game 5. Photo: Allan McKenzie/SWpix.com
5. Ash Handley (No 5)
One brilliant try-saving tackle, ran hard and looked capable of making things happen 8 Photo: Allan McKenzie/SWpix.com
6. Blake Austin (No 6)
On the field less than 10 minutes before failing a head injury assessment 5. Photo: Allan McKenzie/SWpix.com