Highly stable and spectrum-selective ultraviolet photodetectors based on lead-free copper-based perovskites