.customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row {
  height: calc(1200px / 4);
}
@media (max-width: 1200px) {
  .customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row {
    height: calc(100vw / 4);
  }
}
.customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row.masonry-rows-2 {
  height: calc(1200px / 2);
}
@media (max-width: 1200px) {
  .customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row.masonry-rows-2 {
    height: calc(100vw / 2);
  }
}
.acf-fc-row.acf-fc-row-full-width .customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row {
  height: calc(1920px / 4);
}
@media (max-width: 1920px) {
  .acf-fc-row.acf-fc-row-full-width .customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row {
    height: calc(100vw / 4);
  }
}
.acf-fc-row.acf-fc-row-full-width .customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row.masonry-rows-2 {
  height: calc(1920px / 2);
}
@media (max-width: 1920px) {
  .acf-fc-row.acf-fc-row-full-width .customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row.masonry-rows-2 {
    height: calc(100vw / 2);
  }
}
.acf-fc-row.acf-fc-row-narrow-width .customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row:not(.masonry-cols-1),
.acf-fc-row.acf-fc-row-full-width-columns-narrow .customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row:not(.masonry-cols-1) {
  height: calc(900px / 4);
}
@media (max-width: 900px) {
  .acf-fc-row.acf-fc-row-narrow-width .customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row:not(.masonry-cols-1),
  .acf-fc-row.acf-fc-row-full-width-columns-narrow .customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row:not(.masonry-cols-1) {
    height: calc(100vw / 4);
  }
}
.acf-fc-row.acf-fc-row-narrow-width .customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row:not(.masonry-cols-1).masonry-rows-2,
.acf-fc-row.acf-fc-row-full-width-columns-narrow .customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row:not(.masonry-cols-1).masonry-rows-2 {
  height: calc(900px / 2);
}
@media (max-width: 900px) {
  .acf-fc-row.acf-fc-row-narrow-width .customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row:not(.masonry-cols-1).masonry-rows-2,
  .acf-fc-row.acf-fc-row-full-width-columns-narrow .customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row:not(.masonry-cols-1).masonry-rows-2 {
    height: calc(100vw / 2);
  }
}
.acf-fc-row.acf-fc-row-extra-narrow-width .customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row:not(.masonry-cols-1),
.acf-fc-row.acf-fc-row-full-width-columns-extra-narrow .customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row:not(.masonry-cols-1) {
  height: calc(700px / 4);
}
@media (max-width: 700px) {
  .acf-fc-row.acf-fc-row-extra-narrow-width .customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row:not(.masonry-cols-1),
  .acf-fc-row.acf-fc-row-full-width-columns-extra-narrow .customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row:not(.masonry-cols-1) {
    height: calc(100vw / 4);
  }
}
.acf-fc-row.acf-fc-row-extra-narrow-width .customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row:not(.masonry-cols-1).masonry-rows-2,
.acf-fc-row.acf-fc-row-full-width-columns-extra-narrow .customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row:not(.masonry-cols-1).masonry-rows-2 {
  height: calc(700px / 2);
}
@media (max-width: 700px) {
  .acf-fc-row.acf-fc-row-extra-narrow-width .customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row:not(.masonry-cols-1).masonry-rows-2,
  .acf-fc-row.acf-fc-row-full-width-columns-extra-narrow .customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row:not(.masonry-cols-1).masonry-rows-2 {
    height: calc(100vw / 2);
  }
}
.customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  grid-template-rows: 1fr;
  grid-gap: 5px;
  margin-bottom: 5px;
  grid-auto-flow: dense;
}
.customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row:last-child {
  margin-bottom: 0;
}
.customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row.masonry-cols-1 {
  grid-template-columns: 1fr;
}
.customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row.masonry-cols-2 {
  grid-template-columns: 1fr 1fr;
}
.customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row.masonry-rows-2 {
  grid-template-rows: 1fr 1fr;
}
.customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row a.item:hover .img-container img {
  transform: scale(1.05);
  transition: all 0.3s ease;
}
.customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row .item {
  display: block;
  position: relative;
  overflow: hidden;
  line-height: 0;
  background: none;
}
.customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row .item.image-size-tall {
  grid-row: span 2;
}
.customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row .item.image-size-wide {
  grid-column: span 2;
}
.customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row .item.image-size-big {
  grid-column: span 2;
  grid-row: span 2;
}
.customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row .item .img-container {
  width: 100%;
  height: 100%;
}
.customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row .item .img-container img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transition: all 0.6s ease;
}
.customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row.masonry-template-full {
  display: block;
  height: unset;
}
.customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row.masonry-template-full .item .img-container img {
  height: auto;
}
.customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row.masonry-template-tall-wide,
.customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row.masonry-template-wide-tall {
  grid-template-columns: 1fr 1fr 1fr 1fr 1fr;
}
.customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row.masonry-template-tall-wide .item.image-size-wide,
.customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row.masonry-template-wide-tall .item.image-size-wide {
  grid-column: span 4;
}
.customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row.masonry-template-tall-wide .item.image-size-tall,
.customtheme-gallery-container.customtheme-gallery-type-rectangular .customtheme-gallery-masonry-row.masonry-template-wide-tall .item.image-size-tall {
  grid-row: span 1;
}
