Why is the p-value defined the way it is (as opposed to a more intuitive measure)? As I understand it the p-value for some hypothesis H and some test-statistic T is defined as the probability of observing a test-statistic T' which is at least as extreme as T, conditional on H being true.
First question: should "at least as extreme" always be interpreted as "the absolute value of T' is at least as large as T"? If not, when shouldn't it be interpreted that way?
Second question: What is the reasoning behind defining the p-value this way as opposed to just the likelihood of the data -- "probability of observing test-statistic T, or a value in the epsilon region around T, conditional on H being true "-- which seems more clearly related to the strength of evidence that T provides with respect to H than the p-value?


First question: should "at least as extreme" always be interpreted as
"the absolute value of T' is at least as large as T"? If not, when
shouldn't it be interpreted that way?

The definition of the $p$-value depends on the rejection region of the test statistic. Indeed, given a sample $X_1,\ldots,X_n$, a test statistic $T(X_1,\ldots,X_n)$ and $R_\alpha$, a rejection region of size $\alpha$, then
$$
p\text{-value} = \inf\{\alpha: T(X_1,\ldots,X_n)\in R_\alpha\}.
$$
Thus the $p$-value can be interpreted as the smallest size at which we can reject $H_0$. Thus the $p$-value tells us how surprising is the value of the statistic when $H_0$ is true, to be interpreted as:

the lower the $p$-value, the more surprising is observed such a value
under the model with $H_0$ being true.

Indeed, some authors refer to the $p$-value by the name observed significance level.
Now about the computation of the $p$-value, if $t_n$ is the observed test statistics then:

*

*if the rejection region is of the form $$\{X_1,\ldots,X_n: T(X_1,\ldots,X_n)\geq c\},$$ then the $p$-value is defined by
$$\sup_{\theta\in\Theta_0} P_\theta(T(X_1,\ldots,X_n)\geq t_n);$$


*if the rejection region is of the form $$\{X_1,\ldots,X_n: T(X_1,\ldots,X_n)\leq c\},$$ then the $p$-value is defined by
$$\sup_{\theta\in\Theta_0} P_\theta(T(X_1,\ldots,X_n)\leq t_n);$$


*if the rejection region is of the form $$\{X_1,\ldots,X_n: T(X_1,\ldots,X_n)\geq c_1\}\cup \{X_1,\ldots,X_n: T(X_1,\ldots,X_n)\geq c_2\},$$ then the $p$-value is defined by
$$2\min\left(\sup_{\theta\in\Theta_0} P_\theta(T(X_1,\ldots,X_n)\leq t_n,\sup_{\theta\in\Theta_0} P_\theta(T(X_1,\ldots,X_n)\geq t_n\right).$$
