To change the opacity of Gallery Background in Lightbox Mode, you can use this code to Custom CSS box.
div.gallery-lightbox-background {
opacity: 0.5 !important;
}
If you want to change gallery background lightbox color, you can use this CSS code
div.gallery-lightbox-background {
background-color: rgba(0,0,0,0.9) !important;
}
with 0.9 is opacity