Hello there
Present problem first : be assured that you had a period & the pregnancy, even if was, is no more. Worry no more.
The thing you talked about may be just a clot or membrane. You didn't mention about your date of last menses & the date that you got this time. Accordingly I can tell whether it was pregnancy or not
Anyways, nothing to worry for now.
Next Steps
But, as a Doctor, I advise you to be more careful in the future.
The pill or some other method is NOT fool-proof.
Think of your future, as you are still very young & have a long life forward