When you see docs figure out a case seemingly effortlessly, it's almost certainly because they've seen that pathology many times before. So much of clinical medicine is pattern recognition from previous cases. The seasoned attendings get to a point where most of their patients are essentially auto-piloted, and they only really need to turn their brain on for the rare cases.
Point is, you really can only get to that level from seeing a ton of patients. You shouldn't be down on yourself for not having the clinical skills of a resident, who probably has at least double your clinical experience. What you need to do as a student and as a resident is see as many patients as possible. Once you've seen a DVT for the 10th time, you'll have a sense of what a generic DVT patient looks like. Until you've mentally developed generic patient pictures for the essential pathologies you'll expect to see, you need to be more broad about your approach to undifferentiated patients. Let me give an example:
55 year old lady comes in with acute abdominal pain. History of diabetes, a fib, HTN, HLD. Pain is horrible 10/10. Belly exam is benign. A doc with decent clinical acumen will likely have mesenteric ischemia high on the differential without needing any more info, since he's seen that pathology 25 times before, and the patients were all diabetic and/or a fib and/or vasculopaths with benign abdominal exam despite 10/10 pain ("pain out of proportion to exam"). A medical student or less experienced physician will need to ask some more questions and consider a broader differential to catch that and not presume gastroenteritis, nephrolithiasis, etc.
So what should you do? When in doubt, I think the following approach is pretty reasonable:
1. Take a good history. Let the patient tell their story (within reason), then OLDCARTS the HPI. Do a systems-based ROS. Ask about systems one body "compartment" above and below the area (e.g. if they have abdominal pain, also consider ACS and lung pathology). Ask about past medical, surgical, social, and family history. Ask about meds and recent medication changes. If this seems really long, that's because it is. Your script for this will become shorter and shorter over time with experience. But a really good history will usually narrow down your differential to a handful of items, one of which is probably correct. So you gotta do this right.
2. Do a focused physical exam. Pay special attention to the area/system in question, but don't neglect the rest of the patient (e.g. listen carefully to the heart and lungs in that chronically deconditioned leg swelling patient, maybe they have some pulmonary edema pointing to a cardiac/pulm cause).
3. Formulate a differential and try to make it no more than 3 items long. Include the most likely diagnosis, the most dangerous diagnosis, and one possible zebra.
4. Tailor a plan to confirm one of those three as the diagnosis. If none were right, go back to step 3. If you can't think of any more differential items, talk to the patient again, re-examine them, and consider further diagnostics.
If you follow this basic approach, or something like this, and you see a ton of patients, you'll start to see the same pathology multiple times. You'll notice that patients with the same given diagnoses tend to look a certain way, have certain vital sign patterns, have certain unique historical patterns, have certain physical exam findings, etc. Seeing these same boxes get checked over and over again is how you develop gestalt. But you can only see those boxes get checked if you ask/look for them, and early on in your training you need to be thorough to make sure you do that. Also read. A lot. When you see new pathology on a real patient for the first time, read about it on UpToDate when you get home.
tl;dr -- Be thorough with H&P, see as many patients as possible, and read a lot. You'll get there eventually.