  We derive a general effective action for quark matter at nonzero temperature
and/or nonzero density. For this purpose, we distinguish irrelevant from
relevant quark modes, as well as hard from soft gluon modes by introducing two
separate cut-offs in momentum space, one for quarks, $\Lambda_q$, and one for
gluons, $\Lambda_g$. We exactly integrate out irrelevant quark modes and hard
gluon modes in the functional integral representation of the QCD partition
function. Depending on the specific choice for $\Lambda_q$ and $\Lambda_g$, the
resulting effective action contains well-known effective actions for hot and/or
dense quark matter, for instance the ``Hard Thermal Loop'' or the ``Hard Dense
Loop'' action, as well as the high-density effective theory proposed by Hong
and others. We then apply our effective action to review the calculation of the
color-superconducting gap parameter to subleading order in weak coupling, where
the strong coupling constant $g \ll 1$. In this situation, relevant quark modes
are those within a layer of thickness $2 \Lambda_q$ around the Fermi surface.
The non-perturbative nature of the gap equation invalidates naive attempts to
estimate the importance of the various contributions via power counting on the
level of the effective action. Nevertheless, once the gap equation has been
derived within a particular many-body approximation scheme, the cut-offs
$\Lambda_q, \Lambda_g$ provide the means to rigorously power count different
contributions to the gap equation. We recover the previous result for the QCD
gap parameter for the choice $\Lambda_q \alt g \mu \ll \Lambda_g \alt \mu$,
where $\mu$ is the quark chemical potential. We also point out how to improve
this result beyond subleading order in weak coupling.
