.text-gallerey {
  font-size: 14px;
  font-family: "Manrope";
  font-weight: 500;
}

.text-gallerey a {
  color: #ffffff !important;
  text-decoration: none !important;
}

.gallerey__container {
  max-width: 97% !important;
}

.gallerey__container #custom-button {
  text-transform: uppercase;
  font-family: "Manrope";
  font-size: 14px;
  margin-top: 40px;
  width: 223px;
}

.gallerey__container #custom-button .pink-text {
  font-family: "Manrope";
  font-weight: 600;
}

.region-gallerey {
  background-image: url("/sites/all/themes/vesta_theme/image/gallerey.png");
  border-radius: 40px;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  margin-top: 90px;
}

.gallerey__title {
  font-size: 36px;
  font-family: "Stroke(RUS BY LYAJKA)";
  font-weight: 500;
  color: #ffffff;
  padding-top: 90px;
  padding-bottom: 40px;
}

.view-galereya-predstavlenie .view-content {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px;
}

.view-galereya-predstavlenie .view-content .views-row {
  width: 23%;
  position: relative;
  overflow: hidden;
  border-radius: 20px;
}

.view-galereya-predstavlenie .view-content .views-row img {
  width: 100%;
  height: auto;
  transition: transform 0.5s;
}

.view-galereya-predstavlenie .view-content .views-row img:hover {
  transform: scale(1.2);
}

.view-galereya-predstavlenie .view-content .views-row a {
  opacity: 1;
  
}

.view-galereya-predstavlenie .view-content .views-row:first-child a::before {
  content: "";
  background-image: url("/sites/all/themes/vesta_theme/image/borderForGallerey1.png");
  background-repeat: no-repeat;
  background-position: center;
  width: 90%;
  height: 90%;
  position: absolute;
  top: 10px;
  left: 13px;
  background-size: contain;
}

.view-galereya-predstavlenie .view-content .views-row:last-child a::before {
  content: "";
  background-image: url("/sites/all/themes/vesta_theme/image/borderForGallerey1.png");
  background-repeat: no-repeat;
  background-position: center;
  width: 90%;
  height: 90%;
  position: absolute;
  top: 10px;
  left: 13px;
  background-size: contain;
}



.gallerey_for_page {
  background-image: url("/sites/all/themes/vesta_theme/image/gallerey.png");
  border-radius: 40px;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  max-height: 780px;
  max-width: 95% !important;
  margin-bottom: 40px;
}

.gallerey_for_page #custom-button {
  margin-top: 40px;
  margin-bottom: 90px;
}

.region-gallerey-page-view .view-content {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 90px;
  margin-bottom: 40px;
}

.region-gallerey-page-view .view-content .views-row {
  width: 23%;
}

.region-gallerey-page-view .view-content .views-row .views-field-field-foto-galerei {
  overflow: hidden;
  border-radius: 20px;
}

.region-gallerey-page-view .view-content .views-row img {
  width: 100%;
  height: auto;
  transition: transform 0.5s;
}

.region-gallerey-page-view .view-content .views-row img:hover {
  transform: scale(1.2);
}


.region-gallerey-page-view .view-content .views-row a:hover {
  opacity: 1 !important;
}



/* фотки в альбомах */

.field--name-field-foto-galerei .field__items {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 40px;
  margin-bottom: 40px;
}

.field--name-field-foto-galerei .field__items .field__item {
  width: 23%;
  overflow: hidden;
  border-radius: 20px;
}

.field--name-field-foto-galerei .field__items .field__item a:hover {
  opacity: 1 !important;
}

.field--name-field-foto-galerei .field__items .field__item img {
    width: 100%;
    height: auto;
    transition: transform 0.5s;
}

.field--name-field-foto-galerei .field__items .field__item img:hover {
    transform: scale(1.2);
}

.region-gallerey {
  padding-bottom: 90px;
}

@media (max-width: 1920px) {

  

}

@media (max-width: 1200px) {
}

@media (max-width: 996px) {
  .view-galereya-predstavlenie .view-content .views-row {
    width: 32%;
  }

  .region-gallerey-page-view .view-content .views-row {
    width: 32%;
  }

  .field--name-field-foto-galerei .field__items .field__item {
    width: 32%;
  }

  .field--name-field-foto-galerei .field__items {
    justify-content: flex-start;
  }

  .region-gallerey {
    max-height: 100%;
  }

  .gallerey_for_page {
    max-height: 100%;
  }
}

@media (max-width: 768px) {
  .view-galereya-predstavlenie .view-content .views-row {
    width: 47%;
  }

  .region-gallerey-page-view .view-content .views-row {
    width: 47%;
  }

  .field--name-field-foto-galerei .field__items .field__item {
    width: 47%;
  }

  .region-gallerey-page-view .view-content {
    margin-top: 60px;
  }

  .region-gallerey {
    margin-top: 60px;
  }

}
@media (max-width: 576px) {
  .gallerey__container #custom-button .pink-text {
    font-size: 12px;
  }

  .field--name-field-foto-galerei .field__items {
    margin-top: 20px;
    margin-bottom: 20px;
  }

  .containerx2__gallerey {
    padding: 0px !important;
    margin: 0px !important;
    width: 100% !important;
  }



  .region-gallerey {
    margin-top: 40px;
    padding-bottom: 40px;
  }

  .gallerey__title {
    padding-top: 10px;
  };

  .gallerey__container #custom-button {
    margin-bottom: 40px;
  }

}

@media(max-width: 500px) {
  .view-galereya-predstavlenie .view-content .views-row:first-child a::before {
    display: none;
  }
  
  .view-galereya-predstavlenie .view-content .views-row:last-child a::before {
    display: none;
  }

}
