Text this: Design and optimization of photonic crystal based all-optical logic gate with enhanced contrast ratio.