A blistering 94 not out from Chris Cooke helped Glamorgan beat Kent in the Royal London One-Day Cup in Cardiff.