Here's an ad hoc solution that doesn't generalize well to higher numbers of balls.
I'll treat balls of the same colour as distinguishable throughout and divide through by the number $4!3!2!2!$ of permutations of indistinguishable balls in the end.
Since it's the $4$ green balls that make inclusion-exclusion most cumbersome to apply, let's regard these as walls and distribute the remaining balls among them. If we have $k$ non-green objects, we can select one for each green ball in $\frac{k!}{(k-4)!}$ ways, glue the green balls to their right, and then permute the resulting $k$ objects in $k!$ ways. This doesn't allow a green ball to be on the very left, so we have to add a contribution where we select one of the $4$ green balls to be on the very left, select one object for each of the remaining $3$ green balls in $\frac{k!}{(k-3)!}$ ways and permute the resulting $k$ objects in $k!$ ways. Let's denote the total for $k$ objects by $g_k$:
$$
g_k=k!^2\left(\frac1{(k-4)!}+\frac4{(k-3)!}\right)\;,
$$
where terms with negative factorials should be omitted.
Now we have $2$ red, $2$ yellow and $3$ blue balls to distribute. That yields $\binom22+\binom22+\binom32=5$ adjacency conditions to satisfy. Let's first ignore the complications from the interactions of the blue pairs and just perform inclusion-exclusion for these five conditions. This yields
$$
\sum_{k=0}^5(-1)^k\binom5ka_k\;,
$$
where $a_k=2^kg_{7-k}$ is the number of arrangements that result when we glue $k$ pairs of the $7$ non-green balls together and the factor $2^k$ arises because each pair can be glued together in two different orders.
Now we have to account for the interactions of the blue pairs. First consider the cases including two blue adjacency conditions. These are in fact satisfiable, but we overcounted them, since there are only $2$ orders in which the blue balls can be glued together to satisfy two adjacency conditions, whereas we counted $4$, so we have to substract half of that contribution:
$$
\frac12\binom32\sum_{k=0}^2(-1)^{k+2}\binom2ka_{k+2}\;,
$$
where $k$ now counts the non-blue adjacency conditions fulfilled.
That leaves the cases with all three blue pairs. These shouldn't have been counted at all, since it's impossible to have all three pairs of blue balls adjacent, so we need another subtraction of
$$
\sum_{k=0}^2(-1)^{k+3}\binom2ka_{k+3}\;.
$$
Adding it all up yields
\begin{align}
&a_0-5a_1+10a_2-10a_3+5a_4-a_5-\frac32\left(a_2-2a_3+a_4\right)+(a_3-2a_4+a_5)\\
={}&a_0-5a_1+\frac{17}2a_2-6a_3+\frac32a_4\\
={}&8467200-5\cdot1209600+\frac{17}2\cdot172800-6\cdot23040+\frac32\cdot2304\\
={}&3753216\;,
\end{align}
and dividing by $4!3!2!2!=576$ yields $6516$ admissible arrangements, in agreement with the calculation on the site you linked to.
You made your mistake in counting the number of cases that violate the restriction that the lower four drawers can contain at most three balls.
Let $x_i$ be the number of balls placed in drawer $i$, where we count from the top drawer down. Since eight balls are placed in the five drawers,
$$x_1 + x_2 + x_3 + x_4 + x_5 = 8 \tag{1}$$
is an equation in the nonnegative integers. The restriction that at most four balls may be placed in the top drawer means $x_1 \leq 4$. The restriction that at most three balls may be placed in every other drawer means $x_2, x_3, x_4, x_5 \leq 3$.
A particular solution of equation 1 corresponds to the placement of $5 - 1 = 4$ addition signs in a row of eight ones. For instance,
$$1 1 + 1 + 1 1 1 + + 1 1$$
corresponds to the solution $x_1 = 2$, $x_2 = 1$, $x_3 = 3$, $x_4 = 0$, $x_5 = 2$. The number of such solutions is the number of ways we can place four addition signs in a row of eight ones which is
$$\binom{8 + 5 - 1}{5 - 1} = \binom{12}{4}$$
since we must choose which four of the twelve positions required for eight ones and four addition signs will be filled with addition signs.
From these, we must count those cases that violate one or more of the restrictions. Let $A_i$ be the set of solutions in which the $i$th drawer has more than the permitted number of balls.
$|A_1|$: The top drawer is allowed to have at most four balls, so we must subtract those cases in which $x_1 \geq 5$. Suppose $x_1 \geq 5$. Then $x_1' = x_1 - 5$ is a nonnegative integer. Substituting $x_1' + 5$ for $x_1$ in equation 1 yields
\begin{align*}
x_1' + 5 + x_2 + x_3 + x_4 + x_5 & = 8\\
x_1' + x_2 + x_3 + x_4 + x_5 & = 3 \tag{2}
\end{align*}
Equation 2 is an equation in the nonnegative integers with
$$\binom{3 + 5 - 1}{5 - 1} = \binom{7}{4}$$
solutions.
$|A_2|$: The second drawer is allowed to have at most three balls, so we must subtract those cases in which $x_2 \geq 4$. then $x_2' = x_2 - 4$ is a nonnegative integer. Substituting $x_2' + 4$ for $x_2$ in equation 1 yields
\begin{align*}
x_1 + x_2' + 4 + x_3 + x_4 + x_5 & = 8\\
x_1 + x_2' + x_3 + x_4 + x_5 & = 4 \tag{3}
\end{align*}
Equation 3 is an equation in the nonnegative integers with
$$\binom{4 + 5 - 1}{5 - 1} = \binom{8}{4}$$
solutions.
By symmetry,
$$|A_2| = |A_3| = |A_4| = |A_5| = \binom{8}{4}$$
$|A_1 \cap A_2|$: It is not possible for both the restrictions $x_1 \leq 4$ and $x_2 \leq 3$ to be violated since we would require at least $5 + 4 = 9 > 8$ balls to be placed in the drawers.
By symmetry,
$$|A_1 \cap A_2| = |A_1 \cap A_3| = |A_1 \cap A_4| = |A_1 \cap A_5| = 0$$
$|A_2 \cap A_3|$: The only way to violate both the restrictions $x_2 \leq 3$ and $x_3 \leq 3$ is to place four balls in each drawer, which can be done in one way.
By symmetry,
$$|A_2 \cap A_3| = |A_2 \cap A_4| = |A_2 \cap A_5| = |A_3 \cap A_4| = |A_3 \cap A_5| = |A_4 \cap A_5| = 1$$
It is not possible to violate three or more restrictions at once since we only have eight balls and $3 \cdot 4 = 12 > 8$.
Hence, by the Inclusion-Exclusion Principle, the number of admissible ways to distribute the balls is
$$\binom{12}{4} - \binom{7}{4} - \binom{4}{1}\binom{8}{4} + \binom{6}{1}\binom{4}{4} = 495 - 35 - 4 \cdot 70 + 6 \cdot 1 = 495 - 35 - 280 + 6 = 186$$
Best Answer
For (a), there are $\binom{19+4-1}{4-1}$ ways to choose without restrictions. If one of the $\binom41$ restrictions is violated, that leaves $\binom{19+4-1-8}{4-1}$ possibilities (since $8$ balls of the colour for which the restriction is violated are fixed), and if one of the $\binom42$ pairs of restrictions are violated, that leaves $\binom{19+4-1-8-8}{4-1}$ possibilities. Three or four restrictions can't be violated simultaneously. Thus inclusion-exclusion yields
$$ \binom{22}3-\binom41\binom{14}3+\binom42\binom63=204\;. $$
For a general treatment, see Balls In Bins [here: Colours] With Limited Capacity.
For (b), your approach is right. There are $n^9$ arrangements using at most $n$ digits, so inclusion-exclusion using the sets you defined yields
$$ 4^9-\binom41\cdot3^9+\binom42\cdot2^9-\binom43\cdot1^9=186480\;. $$