Question about continuous joint pdf of two random variables $\text{X and Y are a pair of jointly continuous random variables:}$

$f_{X,Y}(x, y) = \begin{cases}
       \text{c,} &\text{the shaded region}\\
       \text{0,} &\text{elsewhere}\\
     \end{cases}$
$\text{a- find the value of c.}$
$\text{b- find the marginal pdf of X and Y.}$
$\text{c- find E[X|Y=1/4] and Var[X|Y=1/4]}.$
$\text{d- find the conditional PDF of X knowing that Y=3/4.}$
$\text{what I did:}$
for the first question, we know that the function is constant thus we can simply multiply the shaded surface and c and this value will equal 1.
$$c\times S = \frac{c}{2} = 1$$
$$c = 2$$
for the marginal pdf of each variable:
the definition domain is:
$$\Delta(x,y)=\text{{0⩽x⩽1 and 0⩽y⩽1, and [0.5-x⩽y⩽1-x, or 3/2-x⩽y]}}$$
$$f_X(x) = \int^{1/2-x}_{1-x}cdy + \int^{3/2-x}_{1}cdy$$
$$f_X(x) = 2x$$
$$f_Y(y) = \int^{1-y}_{1/2-y}cdx + \int^{1}_{3/2-y}cdx$$
$$f_Y(y) = 2y$$
however when I tried to compute the expectation I got a negative value:
$$E[X|Y] = \int^{1-y}_{1/2-y}x \times \frac{f(x,y)}{f(y)}dx + \int^{1}_{3/2-y}x \times \frac{f(x,y)}{f(y)}dx$$
$$E[X|Y] = \int^{1-y}_{1/2-y}\frac{x}{y}dx + \int^{1}_{3/2-y}\frac{x}{y}dx$$
$$E[X|Y] = \frac{8y - 2 - 4y}{8y}$$
$$E[X|Y=1/4] = -0.5$$
I also computed in the same way the variance and found that it was negative [obviously wrong], thus I would be sincerely grateful to know where I made my mistake.

These questions can all be answered just by looking at the picture.
The only numerical result you need to know is that the variance of a Uniform distribution of length $1/2$ is $1/48.$  This can be computed by noting the variance does not depend on the location of the distribution and therefore is the variance of a Uniform distribution on the zero-centered interval $[-1/4,1/4],$ where it equals
$$\int_{-1/4}^{1/4}x^2\,\mathrm dx = \frac{x^3}{3}\bigg|_{-1/4}^{1/4} = \frac{1}{48}.$$
Computation isn't really needed: if you have committed to memory the variance of a unit Uniform distribution, which is $1/12,$ simply observe this distribution has been scaled by a factor of $1/2,$ whence its variance is $(1/2)^2$ = one-quarter of $1/12.$
a. The shaded region along with its rotation by 180 degrees (shown in orange) partition the unit square, showing the original area is half the area of the square, or $1/2.$ Therefore $c = 1/(1/2) = 2$ to make the total probability equal to $1.$

("Partition" isn't quite correct, because there may be some overlap along the boundaries of the two pieces: but because the boundaries have no area, they have no probability and this overlap doesn't matter.)
b. Consider the marginal of $y.$  This is the total probability of $x$ for each $y$ (within an infinitesimal neighborhood of $y$: this form of reasoning is explained more generally in my post at https://stats.stackexchange.com/a/584907/919).  We may shift some of the probability horizontally without changing either $y$ or the total probability conditional on $y.$  The result upon shifting two triangular pieces, as shown, is a rectangle.  Its horizontal cross-sections are all the same length, showing the total probability does not change with $y.$  Therefore the marginal is uniform.  The marginal of $x$ must be uniform, too, because the original picture with $x$ and $y$ interchanged is the same.

c. The conditional expectation is the average position of $x$ for any given $y.$  For $y=1/4,$ $x$ is uniformly distributed between $1/4$ and $3/4,$ as shown in the yellow region.  Therefore its average position is $1/2$ and its variance is that of that uniform distribution, equal to $1/48.$

d. Finally, the conditional distribution of $x$ when $y=3/4$ is found in the same way as in (c).  The picture clearly shows it is uniform on the union of the intervals $[0,1/4]\cup[3/4,1].$

