Hi Evan.... you pose a good question and one that I guess many people struggle to understand within society in general.
Sex ... Is defined by our chromosomes (XY etc), but it is difficult to know what these are (without testing) so when we are born, we are categorized into one of two accepted sexes by our genitalia (Penis, vagina etc). Some people are born with ambiguous sex organs (or both) and hence may have to have their sex assigned to them at a later time or may be InterSexed (IS)
Gender.... is defined by our feelings, emotions and behavioural patterns, including how we think, interact and communicate. It is basically a function of the way our brains are wired, male and female brains are different and develop in the feotal stage being exposed to hormones in the womb (Estrogen or Testosterone etc), which govern which Sex a baby will develop as.
Gender Conditioning .... Is a function of our perceived birth sex, It's a boy!... automatically consigns us to a life of blue clothes, train sets, rough and tumble games and learning to be strong and independent. It's a girl!... automatically consigns us to a lifeof pink clothes, dolls, close friendships and cooperation in play and how to act and conform going into womanhood.
However.... During our development in the womb, things can happen outside of anyones control. Sometimes a basic male body can develop with a partly feminized brain (and vice versa) and this can lead to confusion and anguish throughout our early lives, especially as we develop and head into puberty. Our feelings, thoughts and emotions being at odds with our bodies and physical forms.
The term Gender Identity Disorder (or Dysphoria) are often used for such people, who feel anguish and confusion about having the "wrong body". I was one such person and from an early age always believed I was a girl and wanted to be such.
As we go through life, the feeling can come and go, to an extent be controlled or forgotten, pushed into dark recesses in our minds and many people go into academia, the armed forces etc to provide an environment with a focus away from gender issues.
Jealousy, hate, confusion, depression, disgust, anguish can be part of our lives constantly day and night and that is a terrible burden to bear.
So... Welcome to Susan's. There are many people here with a vast experience and at different stages of their gender discoveries.
I wish you luck in yours.
Buffy