Superconductor strip in a closed magnetic environment: Exact analytic representation of the critical state