First of all, it depends on how much work the customer has done in advance. Do they have a proper spec? Do they at least have a bunch of key requirements? Or is it just "out there" and you must drag the spec out of the customer through interrogation and mind reading?
If there isn't a proper spec, you should probably add a couple of weeks right there. You have to make the spec yourself, then ping pong that with the customer back and forth. Also, customers who don't quite know what they want tend to come up with requirements later, when you are already half-ways through the project. Each time that happens, it will delay the project and cause extra work.
Then you'll start to consider design and implementation time. Here you need experience from similar work but also from the market. To take the DC/DC scenario for example, it shouldn't be that much work unless there are specialized requirements. Find out the most exotic or tough requirement and base the time estimate on that one. High currents? Tough EMC requirements? Is some peculiar switch regulator topology needed? Or whatever you deem hardest to fulfil or most likely to cause hiccups. Check how much in the way of reference designs you can get from the silicon vendor and how much you think that design needs to be tweaked.
Then consider one of the biggest pitfalls: some unexpected technical problem might (will) appear at some point in the project. If (when) that happens, you don't want to end up clawing against an unresponsive or unwilling tech support wall. It might put the whole project to halt and delay it significantly.
The hardened, cynical project manager applies Murphy's Law and assumes that something like that will happen in this project as well and just toss in 2 or so weeks as "hassle margin". The larger the project, the more such time is needed.
But here, past experience market knowledge is valuable. Ok so there's a TI simple switcher that fulfils everything in the spec, it is cheap and there's a reference design. At a glance it seems like an obvious choice. But then you should recall "oh wait, my company isn't Microsoft-sized, so TI will give me the middle finger if I happen to need support". On the other hand you know that LT/Analog has excellent support, but more expensive parts. And suddenly you find yourself in a BOM cost vs time to market situation.
That's where you need to feel out/ask the EE who will do the design how confident they are in pulling off the project - how much switch regulator design have they done in the past? If it isn't a veteran designer, then they are more likely to need tech support. But if they are experienced, you might pick the company with cheap parts but non-existent support.
So lets assume you come up with something like 1 week spec/requirements gathering, 1 week design & component choices, 1 week PCB CAD, then prototype order, then 1 week test. The prototype order time is a black hole - how fast can you get PCBs, are you willing to pay extra for faster delivery, can you solder this yourself, if not - then how swift is your assembly contractor etc etc. Then once the prototype arrives, it almost never 100% correct. You'll find something that needs improving, there will most likely be at least one more board spin. Take this in account.
And then finally regulatory stuff and laws. Where in the world will it be sold? Does this need 3rd party EMC testing? EU regulations? FCC? UL? Local EMC requirements in South-East Asia? Do we need to spew RoHS paperwork all over the technical file? These can be major time and money sinks! So get them right from the start and make it clear with the customer who will pay for any testing. And involve a test house early on and book a time. Don't contact them at the point when the product is supposedly finished & working, they might have a full schedule and you might have to wait many weeks.