*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  background-color: #151f28;
}

.container {
  width: 70%;
  max-width: 800px;
  height: 400px;
  display: flex;
  justify-content: center;
  align-items: stretch;
  gap: 1.25rem;
  transition: all 400ms;
}

.card {
  flex: 1;
  height: 100%;
  transition: all 400ms;
  cursor: pointer;
}
.card > img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.card {
  flex: 1;
  height: 100%;
  transition: all 400ms;
  cursor: pointer;
}
.card:nth-child(odd) {
  translate: 0 -20px;
}
.card:nth-child(even) {
  translate: 0 20px;
}
.container:hover .card:not(:hover) {
  filter: grayscale(100%);
}
.card:hover {
  flex: 3;
}
