Here's my take on this. The question doesn't seem completely well-posed, so I'll try to fill in some gaps. Let \(\displaystyle F = 0.52\) (or whatever) be the proportion of the entire population that is female. You have a random variable \(\displaystyle f\), which is the proportion of a particular 100-person sample of people that is female. What is the distribution of \(\displaystyle f\)? If you're doing a chi-squared test, you're implicitly assuming that \(\displaystyle f\) is a Gaussian (or "Normal") random variable. We'll say that the mean (or expected value) of this random variable converges to \(\displaystyle \bar{f} = F\), where \(\displaystyle \bar{f}\) is the mean over a sufficiently-large set of random 100-person samples. The other thing you need to know is what is the variance of random variable \(\displaystyle f\), i.e. what is \(\displaystyle \sigma_f^2\)? Once again, in theory, you can estimate this by computing the standard deviation of the measured \(\displaystyle f\) values you get over a sufficiently-large set of random 100-person samples. But in your particular problem, you don't have this information, and you cannot solve this problem without knowing (or assuming) the variance. Is the female fraction \(\displaystyle 0.52 \pm 0.01 \) or \(\displaystyle 0.52 \pm 0.1 \)? Obviously it's going to make a huge difference to how likely or unlikely your result of 0.77 was.
If you knew the variance, you wouldn't even need to really do a chi-squared test. What you have is a particular 100-person sample of the population associated with event A that yield a proportion of females \(\displaystyle f_A = 0.77\). The question you are trying to answer is, is this 100-person sample consistent with being a random sample of the population? (I.e. event A kills randomly, which is the null hypothesis.) Or is it biased sample?
If you knew the standard deviation, you could ask yourself the question, how many standard deviations is 0.77 away from the mean? And what is the probability of getting a value this far away (or farther) from the mean? In other words, you could compute the p-value by directly integrating over the Gaussian (Normal) distribution:
\(\displaystyle \displaystyle p = \frac{1}{\sigma_f\sqrt{2\pi}}\int_{0.77}^\infty e^{-(f-F)^2/2\sigma_f^2}\,df\)
If you wanted to, you could instead compute a chi-squared statistic given by
\(\displaystyle \displaystyle \chi^2 = \frac{(f - F)^2}{\sigma_f^2}\)
and substitute in \(\displaystyle f = f_A = 0.77\). Since (under the null hypothesis) this is a sum of the squares of \(\displaystyle N\) standard Normal random variables (where \(\displaystyle N=1\) here), the distribution of this test statistic should be given by a chi-squared probability distribution with \(\displaystyle N=1\) degree of freedom. You would then compute your p-value by integrating over the chi-squared distribution from the value of your test statistic out to infinity. Hopefully you'd get the same answer, because a result of 77%-percent female should equally probable (or improbable) no matter how you choose to measure its probability. In this case, because there is only one Gaussian distribution involved (rather than the sum of many), constructing the chi-squared statistic and hence converting \(\displaystyle f\) from a Gaussian random variable into a chi-squared one, and then integrating over that, seems like pointless extra math.
Bottom line: you cannot solve this problem without knowing (or assuming) a \(\displaystyle \sigma_f\), therefore I do not understand how you got a chi-squared value and associated p-value.