Margaret M. Heckler, a moderate Republican who championed women’s rights in Congress before being appointed — and then forced out — as secretary of health and human services in the Reagan administration, died on Monday at a hospital in Virginia. She was 87 and lived in Arlington, Va.