/*
 * The overlay is applied to images only. The pseudo-element is not reliable
 * for replaced elements such as <img>, so the script toggles visibility.
 */
html.wpisg-images-covered img,
html.wpisg-images-covered picture,
html.wpisg-images-covered video,
html.wpisg-images-covered svg image,
html.wpisg-images-covered .wp-block-image,
html.wpisg-images-covered figure img {
    visibility: hidden !important;
}

/* White placeholders remain visible while the original image is hidden. */
html.wpisg-images-covered img,
html.wpisg-images-covered picture,
html.wpisg-images-covered video,
html.wpisg-images-covered .wp-block-image,
html.wpisg-images-covered figure img {
    background: #fff !important;
}

/* Keep layout dimensions to reduce page jumping. */
html.wpisg-images-covered img {
    opacity: 0 !important;
}
