/* ================================================
   reading.css — overrides для страниц /reading/
   Загружается ПОСЛЕ style.css
   ================================================ */

/* ----- Три колонки вместо двух -----
   .read в style.css убирает правый отступ.
   Возвращаем его — правая колонка (соцсети) нужна. */
.read {
  margin: 0 250px 0 370px !important;
  width: auto !important;
  min-height: auto !important;
}

/* ----- Правая колонка: соцсети ----- */
.right_column .share-block {
  margin-top: 15px;
}
.right_column .share-block p {
  font-size: 14px;
  margin-bottom: 10px;
  color: #666;
}

/* Кнопки Яндекс.Поделиться — во всю ширину колонки */
.ya-share2__item * {
  width: 208px !important;
}

/* VK-виджет на всю ширину колонки */
#vk_groups {
  width: 100% !important;
}

/* ----- Гамбургер: скрыт на десктопе ----- */
.burger {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 30px;
  height: 22px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  position: absolute;
  top: 20px;
  left: 15px;
  z-index: 1001;
}
.burger span {
  display: block;
  height: 3px;
  width: 100%;
  background: #fff;
  border-radius: 2px;
  transition: transform 0.25s, opacity 0.25s;
}

/* Затемнение под выезжающим меню */
.burger-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.4);
  z-index: 999;
}
.burger-overlay.show {
  display: block;
}

/* ================================================
   ПЛАНШЕТ (<= 1160px)
   Правая колонка прячется (уже в style.css),
   контент занимает её место
   ================================================ */
@media screen and (max-width: 1160px) {
  .read {
    margin: 0 25px 0 370px !important;
  }
  /* .right_column { display: none; } — уже в style.css */
}

/* ================================================
   МОБИЛЬНЫЙ (<= 970px)
   Левая колонка > выезжающая панель под гамбургер
   Правая колонка скрыта
   ================================================ */
@media screen and (max-width: 970px) {

  /* Гамбургер появляется */
  .burger {
    display: flex;
  }

  /* Лого сдвигаем вправо, чтобы не перекрывалось гамбургером */
  .logo {
    margin-left: 50px !important;
  }

  /* Левая колонка — выезжающая панель */
  .left_column {
    display: block !important;
    position: fixed !important;
    top: 0;
    left: 0;
    width: 280px;
    max-width: 80vw;
    height: 100vh !important;
    overflow-y: auto;
    z-index: 1000;
    transform: translateX(-100%);
    transition: transform 0.3s ease;
    margin: 0 !important;
    border-radius: 0 !important;
    padding: 20px 15px !important;
    box-shadow: 2px 0 12px rgba(0,0,0,0.2);
    background: #fff;
  }
  .left_column.burger-open {
    transform: translateX(0);
  }

  /* Контент — на всю ширину */
  .read {
    margin: 0 15px !important;
    min-width: 0 !important;
  }

  /* Поиск — подстраиваем под узкий экран */
  .top .search {
    margin: 10px 15px 15px 50px !important;
    padding: 10px 15px !important;
  }
  .top .search input[name=search] {
    width: calc(100% - 140px) !important;
  }
  .top .search noindex {
    margin-left: 0 !important;
  }

  /* Верхнее меню — не уезжает за край */
  .top_menu {
    margin-left: 50px !important;
    width: calc(100% - 60px) !important;
  }
}

/* ================================================
   МАЛЕНЬКИЙ ЭКРАН (<= 600px)
   Карточки статей — в одну колонку
   ================================================ */
@media screen and (max-width: 600px) {
  .one_new {
    width: 100% !important;
    margin: 0 0 15px 0 !important;
  }

  .top .search input[name=search] {
    width: calc(100% - 100px) !important;
  }

  .top .search b {
    display: block;
    margin-bottom: 5px;
    font-size: 18px;
  }

  .top_menu {
    margin-left: 50px !important;
    width: calc(100% - 60px) !important;
    margin-top: -10px !important;
  }
  .top_menu a {
    font-size: 14px !important;
    padding-right: 10px !important;
  }

  .logo a {
    font-size: 28px !important;
  }

  .pages a, .pages span {
    padding: 4px 8px;
    font-size: 13px;
  }
}
