@import url('https://fonts.googleapis.com/css?family=Montserrat:400,500,600');
@import url('https://fonts.googleapis.com/css?family=Open+Sans:400,600,700');
@import url('/templates/awaid/fonts/font-awesome.css?v=1788354674');
@import url('/templates/awaid/fonts/stylesheet.css?v=1788354674');
@import url('bootstrap.css?v=1788354674');
@import url('style_1.css?v=1788354674');
@import url('style_2.css?v=1788354674');
@import url('style_3.css?v=1788354674');
@import url('style_sdg.css?v=1788354674');
@import url('boxicons.min.css?v=1788354674');
.with_code table tr td {
    word-break: normal;
}

.cnopka {
    display: flex;
    align-items: center;
    border-radius: 50px;
    padding: 8px 5px;
    background: #223054;
    place-content: center;
}

.cnopka:hover {
    background: #27375f;
    color: #fff;
}

/* ===== Карточка новости — исправление ===== */

.news_block {
    display: flex !important;
    align-items: stretch !important;
    gap: 18px !important;
    padding: 16px !important;
    border-radius: 18px !important;
    overflow: hidden !important;
}

.news-block-img {
    width: 42% !important;
    min-width: 180px !important;
    height: 260px !important;
    border-radius: 14px !important;
    background-size: cover !important;
    background-position: center !important;
    flex-shrink: 0 !important;
}

.flex_info_new {
    display: flex !important;
    flex-direction: column !important;
    justify-content: space-between !important;
    width: 58% !important;
    min-width: 0 !important;
    height: auto !important;
    padding: 4px 4px 4px 0 !important;
}

.flex_up_new {
    display: flex !important;
    flex-direction: column !important;
    gap: 8px !important;
}

.name_news {
    font-size: 17px !important;
    font-weight: 600 !important;
    color: #fff !important;
    width: 100% !important;
    max-width: 100% !important;
    overflow: hidden !important;
    white-space: normal !important;
    text-overflow: unset !important;
    display: -webkit-box !important;
    -webkit-line-clamp: 2 !important;
    -webkit-box-orient: vertical !important;
    line-height: 1.35 !important;
}

.short_news {
    color: #7a89b0 !important;
    font-size: 12px !important;
    line-height: 1.45 !important;
    font-weight: 500 !important;
    margin: 0 !important;
    max-height: 70px !important;
    overflow: hidden !important;
    display: -webkit-box !important;
    -webkit-line-clamp: 3 !important;
    -webkit-box-orient: vertical !important;
}

.flex_down_new {
    display: flex !important;
    flex-direction: column !important;
    gap: 10px !important;
    margin-top: 12px !important;
}

.first_text_news {
    color: #6b7a9e !important;
    font-size: 11px !important;
    font-weight: 600 !important;
    display: flex !important;
    flex-direction: column-reverse !important;
}

.second_text_news {
    color: #fff !important;
    font-size: 12px !important;
    font-weight: 600 !important;
    margin-top: 0 !important;
}

.news-button-bottom {
    width: 100% !important;
    max-width: 220px !important;
    margin-top: 8px !important;
    padding: 12px 0 !important;
    font-size: 11px !important;
    letter-spacing: 0.5px !important;
    border-radius: 10px !important;
}

/* ===== Страница новости (открытая) ===== */

.news_flex {
    display: flex !important;
    flex-direction: row !important;   /* картинка слева, текст справа */
    gap: 24px !important;
    align-items: flex-start !important;
    margin-bottom: 30px !important;
}

.block_content_new {
    display: flex !important;
    flex-direction: column !important;
    gap: 16px !important;
    flex: 1 !important;
    min-width: 0 !important;
}

.news-block-imgg {
    width: 320px !important;
    min-width: 300px !important;
    height: 240px !important;
    border-radius: 16px !important;
    background-size: cover !important;
    background-position: center center !important;
    background-repeat: no-repeat !important;
    flex-shrink: 0 !important;
    overflow: hidden !important;
    position: relative !important;
}

.news-block-imgg span {
    position: absolute !important;
    left: 12px !important;
    top: 12px !important;
    background: rgba(15, 22, 38, 0.85) !important;
    padding: 6px 12px !important;
    border-radius: 20px !important;
    font-size: 12px !important;
    color: #fff !important;
    display: flex !important;
    align-items: center !important;
    gap: 6px !important;
}

.flex_news_index {
    width: 100% !important;
}

.with_code {
    text-align: left !important;
    color: #c5d0eb !important;
    line-height: 1.65 !important;
    font-size: 14px !important;
}

.with_code p,
.with_code div {
    text-align: left !important;
    margin-bottom: 12px !important;
}

.head_news {
    margin-bottom: 12px !important;
}

/* На мобильных — колонка */
@media (max-width: 991px) {
    .news_flex {
        flex-direction: column !important;
    }
    .news-block-imgg {
        width: 100% !important;
        min-width: 100% !important;
        height: 280px !important;
    }
}

/* ===== Открытая новость — картинка меньше ===== */

.block_content_new .news-block-imgg {
    width: 100% !important;
    max-width: 300px !important;
    height: 240px !important;
    min-width: 0 !important;
    margin: 0 auto 16px auto !important;
    border-radius: 16px !important;
    background-size: cover !important;
    background-position: center center !important;
    background-repeat: no-repeat !important;
}

.block_content_new {
    max-width: 100% !important;
}

.flex_news_index {
    width: 100% !important;
}

.with_code {
    text-align: left !important;
    line-height: 1.65 !important;
    font-size: 14px !important;
}

/* ===== Карточка новости — картинка как на странице новости ===== */

.news_block {
    display: flex !important;
    align-items: stretch !important;
    gap: 18px !important;
    padding: 14px !important;
}

.news_block .news-block-img {
    width: 220px !important;
    min-width: 220px !important;
    max-width: 220px !important;
    height: 220px !important;
    border-radius: 14px !important;
    background-size: cover !important;
    background-position: center center !important;
    background-repeat: no-repeat !important;
    flex-shrink: 0 !important;
    overflow: hidden !important;
}

.news_block .flex_info_new {
    flex: 1 !important;
    width: auto !important;
    min-width: 0 !important;
    height: auto !important;
    justify-content: space-between !important;
}

@media (max-width: 767px) {
    .news_block {
        flex-direction: column !important;
    }
    .news_block .news-block-img {
        width: 100% !important;
        min-width: 100% !important;
        max-width: 100% !important;
        height: 200px !important;
    }
}

/* =====================================================
   Порядок сообщений: ваше / старое сверху, новые ниже
   В конец templates/awaid/css/main.css
   ===================================================== */

/* Форум — стартовое сообщение темы всегда первое */
.topic-answers {
  display: flex !important;
  flex-direction: column !important;
}
.topic-answers > #answer_0 {
  order: -999 !important;
  margin-bottom: 16px !important;
}

/* Тикеты: текст виден + прокрутка
   В КОНЕЦ templates/awaid/css/main.css */

#answers {
  display: block !important;
  max-height: 450px !important;
  overflow-y: auto !important;
  overflow-x: hidden !important;
  padding: 4px 6px 8px 0 !important;
}

#answers > div {
  height: auto !important;
  min-height: auto !important;
  overflow: visible !important;
  margin-bottom: 12px !important;
}

.ban-modal-footer {
  display: flex;
  justify-content: flex-end;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid #243456;
  clear: both;
}

.ban-unban-btn {
  display: inline-flex !important;
  align-items: center !important;
  gap: 8px !important;
  padding: 10px 20px !important;
  border: none !important;
  border-radius: 12px !important;
  background: linear-gradient(135deg, #2ecc71, #27ae60) !important;
  color: #fff !important;
  font-weight: 600 !important;
  font-size: 13px !important;
  box-shadow: 0 4px 16px rgba(46, 204, 113, 0.3) !important;
  cursor: pointer !important;
  transition: 0.2s !important;
}

.ban-unban-btn:hover {
  opacity: 0.92 !important;
  transform: translateY(-1px) !important;
}

.ban-admin-nick {
  display: flex !important;
  align-items: center !important;
  gap: 8px !important;
}

.ban-admin-nick img {
  width: 28px !important;
  height: 28px !important;
  border-radius: 50% !important;
  object-fit: cover !important;
}

.ban-admin-nick a {
  color: #7ec8ff !important;
  font-weight: 600 !important;
  text-decoration: none !important;
}

/* Аккуратный бейдж NEW на карточке новости */
.news-block-img {
  position: relative !important;
  overflow: hidden !important;
}

.news-block-img .new_news,
span.new_news {
  position: absolute !important;
  top: 10px !important;
  left: 10px !important;
  margin: 0 !important;
  z-index: 5 !important;

  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;

  height: 22px !important;
  padding: 0 10px !important;

  border-radius: 999px !important;
  background: linear-gradient(135deg, #2ecc71, #27ae60) !important;
  box-shadow: 0 4px 12px rgba(39, 174, 96, 0.35) !important;

  color: #fff !important;
  font-size: 10px !important;
  font-weight: 700 !important;
  letter-spacing: 0.6px !important;
  line-height: 1 !important;
  text-shadow: none !important;
}