Fluids in narrow pores: Adsorption, capillary condensation, and critical points