/* ============================================================
   БАЗА (old.css) — действует всегда, пока не переопределено
   ============================================================ */

.col_set7 {
  display: inline-block;
  vertical-align: top;
  width: 29%;
  margin-right: 3%;
  margin-bottom: 40px;
}

.inline-blocks .col_set7 {
  max-width: 351px;
}

.block_style2 {
  position: relative;
  line-height: 0;
  max-height: 243px;
  overflow: hidden;
}

.overlay-block {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  transition: .3s;
  color: #fff;
  text-align: center;
  font-size: 26px;
  line-height: 26px;
  padding-top: 100px;
  box-sizing: border-box;
}

.block_style2:hover .overlay-block {
  background: transparent;
}

.image-popup {
  display: inline-block;
  line-height: 0;
}

/* ВАЖНО: в old.css здесь max-content, без aspect-ratio/object-fit */
a.image-popup img {
  width: 25vw;
  max-width: max-content;
}

/* ---------- Адаптив из old.css ---------- */

@media (max-width: 1559px) {
  .col_set7 { margin-bottom: 25px; }
  .news-items .col_set7,
  .gallery-items .col_set7 {
    width: 31%;
    margin-right: 1%;
    background: #c38d56;
    min-height: 15.7vw;
  }
}

@media (max-width: 992px) {
  .col_set7 { width: 46%; margin-right: 3%; }
  .col_set9 .col_set7 { margin-right: 2%; }
}

@media (max-width: 680px) {
  .col_set7 { width: 100%; margin-right: 0; }
  .gallery-items .col_set7,
  .news-items .col_set7 {
    width: 100%;
    margin-right: 0;
    max-width: 100%;
  }
  .news-items .col_set7 {
    width: 100%;
    margin-right: 0;
    margin-bottom: 30px;
  }
}

/* ============================================================
   ПЕРЕОПРЕДЕЛЕНИЕ (old_pc.css) — только ≥767px
   ============================================================ */

@media (min-width: 767px) {
  .col_set7 {
    display: inline-block;
    vertical-align: top;
    width: 29%;
    margin-right: 3%;
    margin-bottom: 2.77778vw;   /* переопределяет 40px */
  }

  .inline-blocks .col_set7 {
    max-width: 24.375vw;        /* переопределяет 351px */
  }

  .block_style2 {
    position: relative;
    line-height: 0;
    max-height: 16.875vw;       /* переопределяет 243px */
    overflow: hidden;
  }

  .overlay-block {
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    transition: 0.3s;
    color: #fff;
    text-align: center;
    font-size: 1.80556vw;       /* переопределяет 26px */
    line-height: 1.80556vw;     /* переопределяет 26px */
    padding-top: 6.94444vw;     /* переопределяет 100px */
    box-sizing: border-box;
  }

  .block_style2:hover .overlay-block {
    background: transparent;
  }

  .image-popup {
    display: inline-block;
    line-height: 0;
  }

  /* Здесь old_pc.css даёт ДРУГОЕ правило */
  a.image-popup img {
    width: 25vw;
    max-width: 100%;            /* переопределяет max-content */
    aspect-ratio: 3/2;          /* НОВОЕ — только на десктопе */
    object-fit: cover;          /* НОВОЕ — только на десктопе */
  }

  /* Вложенный адаптив внутри min-width:767px (из old_pc.css) */

  @media (max-width: 1559px) {
    .col_set7 { margin-bottom: 25px; }
    .news-items .col_set7,
    .gallery-items .col_set7 {
      width: 31%;
      margin-right: 1%;
      background: #c38d56;
      min-height: 15.7vw;
    }
  }

  @media (max-width: 680px) {
    /* этот блок внутри min-width:767px НЕ сработает — 
       он противоречит внешнему условию. Фактически мёртвый код. */
  }
}