Riding in Dunf is thin on the ground in my opinion, but…
Blairadam. 5 minutes by car. Mix of fire roads, paths and some trails if you know where to find them (go off teh paths into the trees).
Lochore Meadows country park has some new trails. 15 minutes by car. Perfectly flat and quite tame I think. All man made.
Dean Plantation. Small forest West of Dunfermline (Gowkhall), some natural trails gently undulating and can be reached by cycling 5-10mins along the West Fife Cycle path from the town centre.
Braefoot Bay. 10mins by car (Dalgety Bay/Aberdour). DH trails and jumps but nothing particularly steep although some big tricks and jumps if you fancy trying them.
Pitmedden Forest. North Fife, 30mins by car. Awesome natural trail network but you’d really need shown around, its a huge area.
Falkland DH Trails. North/Central Fife. Crazy-ass DH and big hucks and jumps. Not for the first timers or feint hearted and not in the wet either.
Other than that further afield to Pentlands, Carron Valley or the Borders.