﻿/* Базовые стили — по умолчанию на любых экранах */
#wrapper {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  background: #fff;
  
  box-sizing: border-box;
  font-family: Arial, sans-serif;
  color: #333;
}

/* Большие экраны (десктопы, ноутбуки) — от 1200px и выше */
@media (min-width: 1200px) {
  #wrapper {
    max-width: 1200px;
  
  }
}

/* Средние экраны (планшеты и маленькие ноутбуки) — от 992px до 1199px */
@media (min-width: 992px) and (max-width: 1199px) {
  #wrapper {
    max-width: 960px;
  
  }
}

/* Маленькие экраны (горизонтальные телефоны, небольшие планшеты) — от 768px до 991px */
@media (min-width: 768px) and (max-width: 991px) {
  #wrapper {
    max-width: 720px;
  
  }
}

/* Очень маленькие экраны (телефоны в портретной ориентации) — до 767px */
@media (max-width: 767px) {
  #wrapper {
    max-width: 100%;
  
  }
}

/* Ультра широкие экраны (например, 1440px+, 4K-мониторы) */
@media (min-width: 1440px) {
  #wrapper {
    max-width: 1400px;
  }
}












/* Сброс и базовая настройка */
html, body {
  margin: 0;
  padding: 0;
  background: #f1f1f1;
  font-family: Arial, sans-serif;
  color: #333;
  font-size: 14px;
  line-height: 1.6;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Общий контейнер для контента */
#content {
  padding: 10px;
  box-sizing: border-box;
}

/* hfeed — микроформат: оставим базовый стиль на случай использования */
.hfeed {
  display: block;
  overflow: hidden;
}

/* Заголовки */
h1, h2, h3, h4, h5, h6 {
  font-weight: 600;
  margin: 1.5em 0 0.5em 0;
  color: #222;
  line-height: 1.3;
}

/* Параграфы */
p {
  margin: 0 0 1em 0;
  line-height: 1.6;
  word-break: break-word;
}

/* Ссылки */
a {
  color: #0066cc;
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover,
a:focus {
  text-decoration: underline;
  color: #004999;
}






/* Обёртка меню */
#cssmenu {
  margin: 0;
  padding: 0;
  list-style: none;
  background-color: #333;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  border-bottom: 2px solid #222;
}

/* Элементы меню */
#cssmenu li {
  display: flex;
}

/* Ссылки меню */
#cssmenu li a {
  display: block;
  padding: 12px 18px;
  color: #FFA200;
  text-decoration: none;
  font-weight: bold;
  font-size: 15px;
  border-right: 1px solid #444;
  transition: background-color 0.3s ease, color 0.3s ease;
}

/* Наведение */
#cssmenu li a:hover,
#cssmenu li a:focus {
  background-color: #555;
  color: #fff;
}

/* Убираем последний бордер */
#cssmenu li:last-child a {
  border-right: none;
}

/* 🔄 Адаптивность */
@media (max-width: 768px) {
  #cssmenu {
    flex-direction: column;
    align-items: stretch;
  }

  #cssmenu li a {
    text-align: center;
    border-right: none;
    border-bottom: 1px solid #444;
  }

  #cssmenu li:last-child a {
    border-bottom: none;
  }
}








/* Обёртка подменю */
.subnav {
  background-image: url('/pics/background-repeat.png');
  background-repeat: repeat-x;
  background-position: left top;
  padding: 10px 0;
  font-family: Arial, sans-serif;
  font-size: 14px;
  color: #444;
}

/* Внутренний контейнер */
.subnav-inner {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
  line-height: 1.6;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

/* Ссылки подменю */
.subnav a {
  color: #111;
  text-decoration: none;
  font-weight: bold;
  transition: color 0.3s ease, text-decoration 0.3s ease;
}

.subnav a:hover,
.subnav a:focus {
  text-decoration: underline;
  color: #0066cc;
}

/* Заголовок подменю */
.subnav-title a {
  color: gray;
  margin-right: 10px;
  font-weight: normal;
}

/* 🔄 Адаптивность */
@media (max-width: 768px) {
  .subnav-inner {
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
  }

  .subnav-title a {
    margin-bottom: 5px;
  }
}






#footer {
  background-color: #003366;
  color: grey;
  padding: 40px 0;
  font-family: Arial, sans-serif;
  font-size: 14px;
}

#footer a {
  color: grey;
  text-decoration: none;
  display: block;
  margin-bottom: 5px;
}

#footer a:hover {
  text-decoration: underline;
}

#footer h4 {
  color: white;
  margin-bottom: 10px;
  font-size: 16px;
}

.footer-grid {
  display: flex;
  flex-wrap: wrap;
  max-width: 1200px;
  margin: 0 auto;
  gap: 20px;
}

.footer-col {
  flex: 1 1 160px;
  min-width: 150px;
}

.footer-col-wide {
  flex: 2 1 350px;
}

.footer-social .social-block {
  display: flex;
  align-items: flex-start;
  margin-bottom: 10px;
}

.footer-social img {
  width: 32px;
  height: 32px;
  margin-right: 10px;
}

.footer-bottom {
  border-top: 1px solid #555;
  margin-top: 30px;
  padding-top: 20px;
  font-size: 13px;
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
}

.footer-bottom a {
  display: inline-block;
  margin-right: 15px;
  color: grey;
}

.footer-bottom p {
  margin: 5px 0;
  color: grey;
}

/* Responsive */
@media (max-width: 768px) {
  .footer-grid {
    flex-direction: column;
    padding: 0 15px;
  }

  .footer-col,
  .footer-col-wide,
  .footer-social {
    flex: 1 1 100%;
  }

  .footer-bottom {
    padding: 20px 15px;
  }
}





.mainpage_ver2_block {
  margin: 30px 10px;
  border-left: 1px solid #ccc;
  padding-left: 15px;
}




/* Блок Смотрите также под статьями */
.ver2_block_2 {
  margin: 30px 10px;
}

.ver2_block_3 {
  margin: 30px 10px;
  border-top: 1px solid #ccc;
  padding-top: 15px;
}
