Thanks for query.
Your mid cycle pain is due to ovulation.
your before period pain
is due to collection of blood in pockets of endometrium causes tense uterus
cause you pain.
Once you get good flow it will go.
Some times due to hymen
the flow does not get passage & you get pain.This should be controlled after your marriage.