  The halo concentration-mass relation has ubiquitous use in modeling the
matter field for cosmological and astrophysical analyses, and including the
imprints from galaxy formation physics is tantamount to its robust usage. Many
analyses, however, probe the matter around halos selected by a given
halo/galaxy property -- rather than by halo mass -- and the imprints under each
selection choice can be different. We employ the CAMELS simulation suite to
quantify the astrophysics and cosmology dependence of the concentration-mass
relation, $c_{\rm vir}-M_{\rm vir}$, when selected on five properties: (i)
velocity dispersion, (ii) formation time, (iii) halo spin, (iv) stellar mass,
and (v) gas mass. We construct simulation-informed nonlinear models for all
properties as a function of halo mass, redshift, and six
cosmological/astrophysical parameters, with a mass range $M_{\rm vir} \in
[10^{11}, 10^{14.5}] M_\odot/h$. There are many mass-dependent imprints in all
halo properties, with clear connections across different properties and
non-linear couplings between the parameters. Finally, we extract the $c_{\rm
vir}-M_{\rm vir}$ relation for subsamples of halos that have scattered
above/below the mean property-$M_{\rm vir}$ relation for a chosen property.
Selections on gas mass or stellar mass have a significant impact on the
astrophysics/cosmology dependence of $c_{\rm vir}$, while those on any of the
other three properties have a significant (mild) impact on the cosmology
(astrophysics) dependence. We show that ignoring such selection effects can
lead to errors of $\approx 25\%$ in baryon imprint modelling of $c_{\rm vir}$.
Our nonlinear model for all properties is made publicly available.
