Touring bike could be the answer – it’ll more than likely have a triple chainset and a wide spread of gears, and it’ll have bosses for (or maybe even come with)mudguards and panniers.
If my memory serves Caerphilly to Cardiff is 8-10miles dependant on route.A tourer lets you carry your clobber on the bike as opposed to your back and it will also be (provided you fit the right tyres) quite happy with a bit of off – road.
I use mine on an almost daily basis for a similar distance, and ok its not the fastest bike out there (engines not what it used to be either) but its very, very nice to ride and with the panniers and racks it doesn’t matter what I need to take to and from work its more than capable of carrying the load.
Whatever you decide full mudguards are (IMO) a must – they’llkeep you drier and the bike cleaner.