Identifying prior signals of bipolar disorder using primary care electronic health records: a nested case-control study