<div class="bg">
.bg {
  width: 400px;
  height: 240px;
  margin: 30px auto;
  background: url(https://api.time.com/wp-content/uploads/2020/07/jeff-bezos.jpg?quality=85&w=1024&h=628&crop=1) no-repeat center center;
  transition: background-size 1s ease-in-out;
  position: relative;
  z-index: 1;

  background-size: 100%; /* work with the background-size */
.bg:hover {background-size: 120% /* work with the background-size */}

.bg::before {
  position: absolute;
  content: '';
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,.7);
  top: 0;
  left: 0;
  z-index: -1;

.bg h2 {
  text-align: center;
  font-size: 60px;
  line-height: 230px;
  font-family: sans-serif;
  color: #fff;

External CSS

This Pen doesn't use any external CSS resources.

External JavaScript

This Pen doesn't use any external JavaScript resources.