.wml-ec-wrapper {
  position: relative;
  height: var(--wml-ec-height, 300px);
  width: var(--wml-ec-width, 600px);
  margin: 50px 0;

  display: flex;
  flex-direction: row;

  transition: all var(--wml-ec-transition, 0.6s) ease-in-out;
}

.wml-ec-image-wrapper {
  height: 100%;
  width: var(--wml-ec-img-width, 450px);
  overflow: hidden;
  border-radius: 5px;
  cursor: pointer;

  transition: all var(--wml-ec-transition, 0.6s) ease-in-out;
}

.wml-ec-image {
  display: block;
  height: 100%;
  width: var(--wml-ec-img-width, 450px);
  object-fit: cover;
  object-position: top;
  will-change: transform;
  backface-visibility: hidden;

  transition: all var(--wml-ec-transition, 0.6s) ease-in-out;
}

.wml-ec-header-wrapper {
  display: flex;
  flex-direction: column;
  position: absolute;
  height: 100%;
  width: 400px;
  /* Default width for header area */
  left: var(--wml-ec-text-left, 380px);
  transition: all var(--wml-ec-transition, 0.6s) ease-in-out;
  overflow: hidden;
  pointer-events: none;
}

.wml-ec-title {
  position: relative;
  bottom: 0;
  height: var(--wml-ec-height, 300px);
  /* color, family, size handled by Bricks typography control */
  text-transform: uppercase;
  margin: 0;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  /* Better vertical alignment */

  transition: all var(--wml-ec-transition, 0.6s) ease-in-out;
}

.wml-ec-wrapper:hover .wml-ec-image {
  transform: scale(2);
}

.wml-ec-wrapper:hover .wml-ec-title {
  bottom: var(--wml-ec-height, 300px);
  transform: scale(.4);
}

.wml-ec-wrapper:hover .wml-ec-image-wrapper {
  width: var(--wml-ec-img-expanded-width, 800px);
}