The answer, as best I can discern it from my training & my own experience, is "You can't!" -- every instructor I've flown with has said that cloud clearances are the most inadvertently-busted regulation, even when pilots are doing their best to obey the requirements.
Our eyes and brain are really good at judging distance relative to landmarks and objects of known size (that's how we can tell we're on a "3 mile final" or "8 miles out"), but without known references our ability to estimate distance quickly falls apart, and there simply aren't that many useful landmarks in the sky.
Judging lateral distance to clouds is, at least in my experience, generally easier than vertical distance - as long as you're a fair distance away from the cloud anyway.
You can roughly estimate the ground position of a cloud pretty easily (and if you can't you can always use its shadow and be pretty close). You can also usually find features on the ground of known size (runways, for example: You can get the length of the longest runway at a field from your handy VFR sectional), and figure out how many of those are between you and the cloud's ground position.
Also if you're doing this whole pilotage-and-navigation thing right you know where you are on the chart, and you can visually estimate the ground position of a cloud pretty easily (again if all else fails use its shadow and you'll be close). Break out your plotter and you can figure out how many miles away you are from the cloud (but inside about 3 miles this is going to get pretty difficult, and with your head in the cockpit mucking about with the chart and plotter you may wind up inside the cloud by the time you're done working up your estimate!).
A final close-in technique for clouds at your altitude is to use your wing. You know your aircraft's wingspan, and you can also say that roughly half that value is the length of one wing. Figure out how many "wings away" the cloud is, and do the math -- of course if you're at a distance where you can do that kind of visual estimation you're likely to be close to the cloud clearance limits.
Judging vertical distance is harder. The usual advice if you're below the clouds is to get the cloud heights from a local airports ATIS or AWOS and use that as a guide. If you're above the clouds PIREPs for cloud tops serve the same purpose.
Visually if you're above the cloud the same skills you use to judge your height above a runway will work. The catch is those skills really only work when you're within about 1000 to 2000 feet (i.e. "By the time you can really judge the distance you may already be too close!").
Coming up from below a cloud you're basically relying on judging your closing speed to an object of unknown / nebulous size: As you approach the cloud it's going to get bigger, but you don't really know how big it's going to get before you wind up inside it.
As a final visual cue in any direction, remember that clouds aren't clearly-defined boundaries - Often you'll see little wispy streaks of cloud around you as you're getting closer to the cloud you're trying to avoid (particularly when approaching from below). This is a pretty definitive indication that you're probably closer to the cloud than you should be, and you should start heading away from the cloud before you wind up inside it.
I think the best bottom-line practical advice I've ever gotten on cloud clearances, loosely paraphrased from a couple of the local CFIs: "Just stay way the heck away from clouds until you're instrument rated and on an IFR flight plan." and "If you think you might be too close to a cloud, get further away!" -- the latter probably being what the FAA is getting at with their statutory distance requirements.