/* Собрано из шаблонов — tools/extract_template_styles.php */


/* --- template/header.php --- */
body {
  margin: 0;
  font-family: "Inter", "Segoe UI", Roboto, sans-serif;
  background: #fafafa;
  color: #222;
}

.site-header {
  background: #fff;
  border-bottom: 1px solid #e0e0e0;
  position: sticky;
  top: 0;
  z-index: 100;
  transition: box-shadow 0.3s ease;
}

.site-header.scrolled {
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.header-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 12px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo a {
  font-size: 1.5em;
  font-weight: 700;
  text-decoration: none;
  color: #111;
}

.main-menu {
  list-style: none;
  display: flex;
  gap: 24px;
  margin: 0;
  padding: 0;
}

.main-menu li a {
  text-decoration: none;
  color: #333;
  font-weight: 500;
  border-bottom: 2px solid transparent;
  transition: color 0.2s ease, border-color 0.2s ease;
}

.main-menu li a:hover {
  color: #d33;
  border-color: #d33;
}

.menu-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 1.6em;
  color: #333;
  cursor: pointer;
}

@media (max-width: 820px) {
  .menu-toggle {
    display: block;
    z-index: 200;
  }

  .main-menu {
    display: none;
    position: absolute;
    top: 60px;
    left: 0;
    width: 100%;
    background: #fff;
    flex-direction: column;
    align-items: center;
    border-top: 1px solid #e0e0e0;
    z-index: 150;
  }

  .main-menu.active {
    display: flex;
    animation: fadeIn 0.25s ease-in;
  }

  .main-menu li {
    padding: 10px 0;
    width: 100%;
    text-align: center;
  }
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-5px); }
  to { opacity: 1; transform: translateY(0); }
}

/* --- template/footer.php --- */
.site-footer--main {
  margin-top: 72px;
  font-family: "Inter", "Segoe UI", Roboto, system-ui, sans-serif;
  background: linear-gradient(165deg, #0f172a 0%, #1e293b 48%, #0f172a 100%);
  color: rgba(248, 250, 252, 0.88);
  border-top: 4px solid #38bdf8;
  box-shadow: 0 -12px 40px rgba(15, 23, 42, 0.35);
}
.site-footer__inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 40px 22px 36px;
}
.site-footer__top {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 28px 40px;
  padding-bottom: 28px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.25);
}
.site-footer__brand {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 180px;
}
.site-footer__mark {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: linear-gradient(135deg, #38bdf8, #818cf8);
  box-shadow: 0 4px 18px rgba(56, 189, 248, 0.35);
  flex-shrink: 0;
}
.site-footer__name {
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: #f8fafc;
}
.site-footer__nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 10px 22px;
  justify-content: flex-end;
}
.site-footer__nav a {
  color: rgba(226, 232, 240, 0.92);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.92em;
  padding: 4px 0;
  border-bottom: 2px solid transparent;
  transition: color 0.2s, border-color 0.2s;
}
.site-footer__nav a:hover {
  color: #7dd3fc;
  border-bottom-color: #38bdf8;
}
.site-footer__contacts-band {
  margin-top: 8px;
  padding: 22px 20px;
  background: rgba(15, 23, 42, 0.55);
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 14px;
}
.site-footer__contacts {
  margin: 0;
}
.site-footer__contacts .cms-foot-contact__strip {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 14px;
}
.site-footer__contacts .cms-foot-contact__item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 16px;
  background: rgba(30, 41, 59, 0.85);
  border-radius: 10px;
  border: 1px solid rgba(56, 189, 248, 0.2);
  transition: border-color 0.2s, box-shadow 0.2s;
}
.site-footer__contacts .cms-foot-contact__item:hover {
  border-color: rgba(56, 189, 248, 0.45);
  box-shadow: 0 4px 20px rgba(56, 189, 248, 0.12);
}
.site-footer__contacts .cms-foot-contact__glyph {
  flex-shrink: 0;
  font-size: 1.1rem;
  opacity: 0.92;
  line-height: 1.4;
}
.site-footer__contacts .cms-foot-contact__link {
  color: #f1f5f9;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.9rem;
  line-height: 1.45;
  word-break: break-word;
}
.site-footer__contacts .cms-foot-contact__link:hover {
  color: #7dd3fc;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.site-footer__text {
  padding-top: 24px;
  font-size: 0.9em;
  line-height: 1.65;
  color: rgba(203, 213, 225, 0.92);
  max-width: 820px;
}
@media (max-width: 700px) {
  .site-footer__top {
    flex-direction: column;
  }
  .site-footer__nav ul {
    justify-content: flex-start;
  }
}

/* --- template/home.php --- */
.home-container {
  max-width: 1200px;
  margin: 40px auto;
  padding: 0 20px;
  display: flex;
  flex-direction: column;
  gap: 60px;
}

.main-menu:not(.main-menu--lite) {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
  justify-content: center;
  background: #f5f5f5;
  padding: 10px 20px;
  border-radius: 50px;
}
.menu-link {
  text-decoration: none;
  color: #333;
  font-weight: 600;
  transition: all 0.2s ease;
}
.menu-link:hover {
  color: #0077cc;
}

.main-news {
  position: relative;
  overflow: hidden;
  border-radius: 20px;
}
.main-news-card {
  display: block;
  position: relative;
  color: white;
}
.main-news-card img {
  width: 100%;
  height: 450px;
  object-fit: cover;
  border-radius: 20px;
}
.main-news-card .overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 40px;
  background: linear-gradient(transparent, rgba(0,0,0,0.8));
}
.main-news-card h1 {
  font-size: 2em;
  margin-bottom: 10px;
}
.main-news-card p {
  font-size: 1em;
  opacity: 0.9;
}
.tag {
  background: #0077cc;
  padding: 5px 10px;
  border-radius: 8px;
  font-size: 0.9em;
  margin-bottom: 10px;
  display: inline-block;
}

.cms-home-top-stories {
  width: 100%;
}
.cms-home-top-stories__inner {
  padding: 14px 16px 16px;
  background: #f0f4f8;
  border-radius: 14px;
  border: 1px solid rgba(0, 119, 204, 0.15);
}
.cms-home-top-stories__label {
  margin: 0 0 12px;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #0073e6;
}
.cms-home-top-stories__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 10px 12px;
  align-items: stretch;
}
.cms-home-top-stories__item {
  flex: 1 1 160px;
  min-width: 0;
  max-width: 100%;
}
.cms-home-top-stories__link {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 12px;
  min-height: 64px;
  padding: 8px 12px;
  text-decoration: none;
  color: #0f172a;
  background: #fff;
  border-radius: 10px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.06);
  transition: border-color 0.18s ease, box-shadow 0.18s ease, color 0.18s ease;
}
.cms-home-top-stories__link:hover {
  border-color: rgba(0, 115, 230, 0.35);
  box-shadow: 0 4px 14px rgba(0, 115, 230, 0.12);
  color: #0073e6;
}
.cms-home-top-stories__thumb {
  flex-shrink: 0;
  width: 56px;
  height: 56px;
  border-radius: 8px;
  overflow: hidden;
  background: #e2e8f0;
}
.cms-home-top-stories__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.cms-home-top-stories__title {
  font-size: 0.88rem;
  font-weight: 600;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
@media (max-width: 768px) {
  .cms-home-top-stories__inner {
    padding: 10px 10px 12px;
    border-radius: 12px;
  }
  .cms-home-top-stories__label {
    margin: 0 0 8px;
    font-size: 0.65rem;
    letter-spacing: 0.08em;
  }
  .cms-home-top-stories__list {
    display: flex;
    flex-direction: column;
    flex-wrap: nowrap;
    gap: 10px;
    overflow: visible;
    padding: 0;
    margin: 0;
    scroll-snap-type: none;
  }
  .cms-home-top-stories__item {
    flex: none;
    width: 100%;
    max-width: none;
    min-width: 0;
    scroll-snap-align: none;
  }
  .cms-home-top-stories__link {
    min-height: 54px;
    padding: 8px 10px;
    gap: 10px;
  }
  .cms-home-top-stories__thumb {
    width: 48px;
    height: 48px;
  }
  .cms-home-top-stories__title {
    font-size: 0.82rem;
    -webkit-line-clamp: 2;
    line-clamp: 2;
  }
}

.latest-news h2,
.category-news h2 {
  margin-bottom: 20px;
  font-size: 1.5em;
  text-align: center;
}
.news-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 25px;
}
.news-card {
  background: white;
  border-radius: 15px;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.news-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}
.news-card img {
  width: 100%;
  height: 180px;
  object-fit: cover;
}
.news-info {
  padding: 15px;
}
.news-info h3 {
  margin: 0 0 10px;
  font-size: 1.1em;
}
.news-info p {
  font-size: 0.95em;
  color: #555;
}

.categories {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 25px;
}
.category-card {
  position: relative;
  display: block;
  overflow: hidden;
  border-radius: 15px;
}
.category-card img {
  width: 100%;
  height: 250px;
  object-fit: cover;
  transition: transform 0.4s ease;
}
.category-card:hover img {
  transform: scale(1.05);
}
.cat-overlay {
  position: absolute;
  bottom: 0;
  padding: 20px;
  background: linear-gradient(transparent, rgba(0,0,0,0.7));
  color: #fff;
}
.cat-name {
  background: #0077cc;
  padding: 4px 10px;
  border-radius: 8px;
  font-size: 0.85em;
}
.cat-overlay h3 {
  margin-top: 8px;
  font-size: 1.1em;
}

/* --- template/article.php --- */
/* ====== Base ====== */
body {
  font-family: "Inter", "Segoe UI", system-ui, sans-serif;
  background: #f5f7fa;
  color: #222;
  margin: 0;
  padding: 0;
  line-height: 1.7;
}

/* ====== Article ====== */
main {
  max-width: 860px;
  margin: 70px auto;
  background: #fff;
  padding: 55px;
  border-radius: 20px;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.08);
}

.post h1 {
  font-size: 2.5rem;
  line-height: 1.3;
  color: #111;
  margin-bottom: 20px;
  font-weight: 700;
  text-align: left;
}

.meta {
  font-size: 0.95rem;
  color: #666;
  margin-bottom: 35px;
}

.meta a {
  color: #0073e6;
  text-decoration: none;
  font-weight: 500;
  transition: color 0.2s ease;
}
.meta a:hover { color: #005bb5; }

/* ====== Content ====== */
.content {
  font-size: 1.06rem;
  color: #222;
  text-align: left;
}
/* Quill часто сохраняет центрирование — на статье оставляем ровный левый край */
.post .content .ql-align-center {
  text-align: left !important;
}
.post .content p[style*="text-align: center"],
.post .content p[style*="text-align:center"] {
  text-align: left !important;
}
.content p { margin-bottom: 1.6em; }
.content img {
  display: block;
  max-width: 100%;
  border-radius: 12px;
  margin: 25px auto;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
}
.content h2, .content h3 {
  margin-top: 1.8em;
  color: #111;
  line-height: 1.4;
}
.content blockquote {
  border-left: 4px solid #0073e6;
  padding-left: 15px;
  font-style: italic;
  color: #555;
  margin: 1.5em 0;
}
.content a {
  color: #0073e6;
  text-decoration: underline;
  transition: all 0.2s ease;
}
.content a:hover { color: #005bb5; }

/* ====== Main Image ====== */
.post-image {
  margin: 35px 0;
  text-align: center;
}
.post-image img {
  max-width: 100%;
  border-radius: 16px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.08);
}

/* ====== Related ====== */
.related-articles {
  max-width: 1100px;
  margin: 90px auto;
  padding: 20px;
}
.related-articles h2 {
  font-size: 1.9rem;
  color: #111;
  margin-bottom: 35px;
  text-align: center;
  position: relative;
}
.related-articles h2::after {
  content: "";
  display: block;
  width: 80px;
  height: 3px;
  background: #0073e6;
  margin: 12px auto 0;
  border-radius: 3px;
}
.related-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 32px;
}
.related-list article {
  background: #fff;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.06);
  transition: all 0.25s ease;
}
.related-list article:hover {
  transform: translateY(-6px);
  box-shadow: 0 10px 26px rgba(0, 0, 0, 0.1);
}
.related-list img {
  width: 100%;
  height: 190px;
  object-fit: cover;
}
.related-list h3 {
  font-size: 1.1rem;
  padding: 15px 20px 25px;
  line-height: 1.4;
}
.related-list a {
  color: #111;
  text-decoration: none;
  transition: color 0.2s ease;
}
.related-list a:hover { color: #0073e6; }

/* ====== Mobile ====== */
@media (max-width: 768px) {
  main {
    padding: 30px 20px;
    margin: 40px 15px;
  }
  .post h1 { font-size: 2rem; }
  .related-list { grid-template-columns: 1fr; }
}

/* --- template/category.php --- */
body {
    font-family: "Inter", system-ui, sans-serif;
    background: #f8fafc;
    margin: 0;
    padding: 0;
    color: #222;
}

h1 {
    text-align: center;
    font-size: 2.2rem;
    margin: 30px 0 40px;
    color: #111;
}

/* --- Контент страницы --- */
/* --- Контент страницы (из таблицы pages.content) --- */
.page-content {
    max-width: 900px;
    margin: 0 auto 50px;
    padding: 25px 30px;
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.06);
    line-height: 1.7;
    color: #222;
    font-size: 1.05rem;
    word-wrap: break-word;
}

/* Текстовые элементы */
.page-content p {
    margin: 0 0 1.1em;
}

.page-content h2,
.page-content h3,
.page-content h4 {
    margin-top: 1.5em;
    margin-bottom: 0.7em;
    color: #111;
    font-weight: 600;
    line-height: 1.3;
}

.page-content h2 {
    font-size: 1.6rem;
    border-left: 4px solid #007bff;
    padding-left: 10px;
}

.page-content h3 {
    font-size: 1.3rem;
}

/* Списки */
.page-content ul,
.page-content ol {
    margin: 1em 0 1em 1.5em;
    padding: 0;
}
.page-content li {
    margin-bottom: 0.5em;
}

/* Ссылки */
.page-content a {
    color: #007bff;
    text-decoration: none;
}
.page-content a:hover {
    text-decoration: underline;
}

/* Картинки */
.page-content img {
    display: block;
    max-width: 100%;
    height: auto;
    margin: 20px auto;
    border-radius: 8px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.08);
}

/* Цитаты */
.page-content blockquote {
    margin: 1.2em 0;
    padding: 1em 1.2em;
    border-left: 4px solid #007bff;
    background: #f7faff;
    color: #333;
    border-radius: 6px;
    font-style: italic;
}

/* Таблицы */
.page-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.5em 0;
}
.page-content th,
.page-content td {
    border: 1px solid #ddd;
    padding: 10px;
    text-align: left;
}
.page-content th {
    background: #f1f5ff;
    font-weight: 600;
}

/* Видео, iframe */
.page-content iframe {
    max-width: 100%;
    display: block;
    margin: 20px auto;
    border: none;
}

/* Адаптивность */
@media (max-width: 768px) {
    .page-content {
        padding: 20px;
        font-size: 1rem;
    }
    .page-content h2 { font-size: 1.4rem; }
    .page-content h3 { font-size: 1.2rem; }
}

ul.category-articles {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 25px;
    padding: 0 20px;
    list-style: none;
    margin: 0 auto 40px;
    max-width: 1200px;
}

ul.category-articles > li {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.06);
    overflow: hidden;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
}

ul.category-articles > li:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0,0,0,0.1);
}

ul.category-articles li img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-bottom: 1px solid #eee;
}

ul.category-articles li a {
    text-decoration: none;
    color: inherit;
}

ul.category-articles li strong {
    font-size: 1.1rem;
    color: #0a0a0a;
    display: block;
    margin-bottom: 8px;
}

ul.category-articles li small {
    color: #666;
    font-size: 0.85rem;
}

ul.category-articles .post-content {
    padding: 15px 18px 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

/* --- Pagination --- */
.pagination {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px;
    padding: 20px 0 40px;
}

.pagination a {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 8px 14px;
    color: #333;
    text-decoration: none;
    transition: all 0.2s ease;
}

.pagination a:hover {
    background: #007bff;
    color: #fff;
    border-color: #007bff;
}

.pagination a[style*="font-weight:bold"] {
    background: #007bff;
    color: #fff;
    font-weight: normal !important;
}

/* --- Responsive tweaks --- */
@media (max-width: 768px) {
    h1 { font-size: 1.8rem; }
    ul.category-articles li img { height: 160px; }
}

@media (max-width: 480px) {
    ul.category-articles { gap: 18px; }
    ul.category-articles li img { height: 140px; }
}

/* --- template/page.php --- */
/* Базовые настройки */
  body {
    font-family: "Inter", "Segoe UI", Roboto, Arial, sans-serif;
    margin: 0;
    padding: 0;
    background: #f8f9fb;
    color: #222;
    line-height: 1.6;
  }

  h1 {
    text-align: center;
    font-size: 2.4rem;
    margin: 40px 20px 20px;
    color: #111;
  }

  main {
    max-width: 900px;
    margin: 0 auto 60px;
    background: #fff;
    padding: 40px 50px;
    border-radius: 18px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.08);
    transition: box-shadow 0.3s ease, transform 0.2s ease;
  }

  main:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
  }

  main p {
    margin: 1.2em 0;
    font-size: 1.05rem;
  }

  main img {
    display: block;
    max-width: 100%;
    margin: 25px auto;
    border-radius: 12px;
  }

  main a {
    color: #0078f2;
    text-decoration: none;
    border-bottom: 1px solid rgba(0,120,242,0.3);
    transition: color 0.2s, border-color 0.2s;
  }

  main a:hover {
    color: #0059b3;
    border-color: rgba(0,120,242,0.5);
  }

  blockquote {
    margin: 30px 0;
    padding: 20px 30px;
    background: #f0f5ff;
    border-left: 4px solid #0078f2;
    font-style: italic;
    color: #333;
  }

  code, pre {
    font-family: "Fira Code", monospace;
    background: #f4f4f4;
    border-radius: 8px;
  }

  pre {
    padding: 15px;
    overflow-x: auto;
  }

  @media (max-width: 700px) {
    main {
      padding: 25px;
    }

    h1 {
      font-size: 1.8rem;
    }
  }

/* --- template/author.php --- */
body {
      font-family: 'Inter', 'Segoe UI', Roboto, sans-serif;
      background-color: #f5f6f8;
      color: #222;
      margin: 0;
      padding: 0;
      line-height: 1.6;
    }

    h1 {
      text-align: center;
      margin-top: 50px;
      font-size: 2.4rem;
      color: #111;
    }

    .author-desc {
      max-width: 700px;
      margin: 10px auto 50px;
      text-align: center;
      font-size: 1.05rem;
      color: #555;
    }

    main {
      max-width: 1200px;
      margin: 0 auto;
      padding: 0 20px 60px;
    }

    .articles {
      list-style: none;
      display: grid;
      grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
      gap: 30px;
      padding: 0;
      margin: 0;
    }

    .article-card {
      background: #fff;
      border-radius: 18px;
      overflow: hidden;
      box-shadow: 0 4px 15px rgba(0,0,0,0.06);
      transition: transform 0.25s ease, box-shadow 0.25s ease;
      display: flex;
      flex-direction: column;
    }

    .article-card:hover {
      transform: translateY(-5px);
      box-shadow: 0 10px 25px rgba(0,0,0,0.12);
    }

    .preview {
      width: 100%;
      aspect-ratio: 16 / 9;
      overflow: hidden;
      background: #eee;
    }

    .preview img {
      width: 100%;
      height: 100%;
      object-fit: cover;
      transition: transform 0.4s ease;
    }

    .article-card:hover .preview img {
      transform: scale(1.07);
    }

    .card-body {
      padding: 20px 22px 25px;
      display: flex;
      flex-direction: column;
      flex-grow: 1;
    }

    .card-body h3 {
      margin: 0 0 10px;
      font-size: 1.3rem;
    }

    .card-body h3 a {
      text-decoration: none;
      color: #111;
      transition: color 0.2s ease;
    }

    .card-body h3 a:hover {
      color: #0066ff;
    }

    .excerpt {
      font-size: 0.95rem;
      color: #555;
      flex-grow: 1;
      margin-bottom: 20px;
    }

    .read-more {
      align-self: flex-start;
      text-decoration: none;
      color: #0066ff;
      font-weight: 500;
      transition: all 0.2s ease;
    }

    .read-more:hover {
      color: #0044bb;
      transform: translateX(3px);
    }

    /* Глобальный p { text-align:center } ломал абзацы статей и страниц в этой же теме */
    main > p.author-empty-note {
      text-align: center;
      font-size: 1.1rem;
      color: #777;
    }

    @media (max-width: 600px) {
      h1 {
        font-size: 1.8rem;
      }
      .author-desc {
        font-size: 0.95rem;
      }
      .card-body h3 {
        font-size: 1.1rem;
      }
    }


/* === Стандартная тема: лёгкая главная === */
:root {
  --nb-navy: #0a1628;
  --nb-navy-mid: #0d2138;
  --nb-blue: #0066cc;
  --nb-blue-bright: #2d9bff;
  --nb-bg: #ffffff;
  --nb-bg-soft: #f1f5f9;
  --nb-text: #1a1a1a;
  --nb-muted: #5c5c5c;
  --nb-line: #e2e8f0;
  --nb-hero-overlay: linear-gradient(
    180deg,
    rgba(10, 22, 40, 0.04) 0%,
    rgba(10, 22, 40, 0.5) 42%,
    rgba(10, 22, 40, 0.92) 100%
  );
}

body {
  background: var(--nb-bg);
  color: var(--nb-text);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

.site-header.site-header--lite {
  background: var(--nb-bg);
  border-bottom: 1px solid var(--nb-line);
  box-shadow: none;
}

.site-header.site-header--lite.scrolled {
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.06);
}

.header-inner--lite {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 16px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 16px;
  min-height: 54px;
}

a.logo.logo--lite {
  color: var(--nb-text);
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: -0.02em;
  text-decoration: none;
  padding: 6px 0;
  min-width: 0;
  margin-right: auto;
}

a.logo.logo--lite:hover {
  color: var(--nb-blue);
}

.menu-toggle--lite {
  width: 44px;
  height: 44px;
  margin: 0;
  padding: 0;
  border: none;
  background: transparent;
  cursor: pointer;
  border-radius: 6px;
  flex-shrink: 0;
}

.menu-toggle--lite:hover {
  background: rgba(15, 23, 42, 0.06);
}

.site-header--lite .menu-toggle__lines {
  display: block;
  width: 18px;
  height: 2px;
  margin: 0 auto;
  background: #1e293b;
  border-radius: 1px;
  position: relative;
}

.site-header--lite .menu-toggle__lines::before,
.site-header--lite .menu-toggle__lines::after {
  content: "";
  position: absolute;
  left: 0;
  width: 18px;
  height: 2px;
  background: #1e293b;
  border-radius: 1px;
}

.site-header--lite .menu-toggle__lines::before {
  top: -6px;
}

.site-header--lite .menu-toggle__lines::after {
  top: 6px;
}

.nav-menu--lite {
  flex: 1 1 auto;
  min-width: 0;
}

.main-menu--lite {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 2px 4px;
}

.main-menu--lite li {
  padding: 0;
}

.main-menu--lite li a {
  display: block;
  padding: 6px 10px;
  color: #334155;
  font-size: 0.875rem;
  font-weight: 500;
  text-decoration: none;
}

.main-menu--lite li a:hover {
  color: var(--nb-blue);
  text-decoration: underline;
  text-underline-offset: 3px;
}

@media (min-width: 821px) {
  .main-menu--lite > li.menu-item-has-children {
    position: relative;
  }

  .main-menu--lite .sub-menu {
    display: none;
    position: absolute;
    left: 0;
    top: 100%;
    min-width: 200px;
    margin: 0;
    padding: 4px 0;
    list-style: none;
    background: #fff;
    border: 1px solid var(--nb-line);
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.12);
    z-index: 200;
  }

  .main-menu--lite .sub-menu .sub-menu {
    left: 100%;
    top: 0;
    margin-left: 2px;
  }

  .main-menu--lite li.menu-item-has-children:hover > .sub-menu,
  .main-menu--lite li.menu-item-has-children:focus-within > .sub-menu {
    display: block;
  }

  .main-menu--lite .sub-menu li a {
    padding: 8px 14px;
    white-space: nowrap;
    text-decoration: none;
  }

  .main-menu--lite .sub-menu li a:hover {
    background: var(--nb-bg-soft);
    text-decoration: none;
  }
}

.main-menu__empty {
  color: #94a3b8;
  padding: 6px 10px;
  font-size: 0.875rem;
}

@media (min-width: 821px) {
  .menu-toggle--lite {
    display: none;
  }

  .nav-menu--lite {
    display: block !important;
  }

  .main-menu--lite {
    display: flex !important;
  }
}

@media (max-width: 820px) {
  .nav-menu--lite {
    flex: 1 1 100%;
    order: 3;
    display: none;
    width: calc(100% + 32px);
    border-top: 1px solid var(--nb-line);
    margin: 0 -16px;
    padding: 0 16px 8px;
    background: var(--nb-bg);
  }

  .main-menu--lite {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 8px 0 4px;
  }

  .main-menu--lite li a {
    border-bottom: 1px solid var(--nb-line);
    padding: 12px 4px;
  }

  .main-menu--lite li a:hover {
    background: var(--nb-bg-soft);
  }

  .main-menu--lite .sub-menu {
    display: block;
    position: static;
    margin: 0;
    padding: 0 0 0 12px;
    list-style: none;
    border: none;
    box-shadow: none;
    background: transparent;
  }

  .main-menu--lite .sub-menu li a {
    padding: 10px 4px 10px 8px;
    font-size: 0.8125rem;
    border-bottom: 1px solid var(--nb-line);
  }

  .main-menu--lite.active,
  .main-menu--lite {
    display: flex;
  }
}

.home-container--nb {
  max-width: 100%;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0;
  background: var(--nb-bg);
}

.nb-pinned-top-bar {
  width: 100%;
  background: var(--nb-bg-soft);
  border-bottom: 1px solid var(--nb-line);
}

.nb-pinned-top-bar__inner {
  max-width: 1240px;
  margin: 0 auto;
  padding: 18px 20px 16px;
}

.nb-pinned-top-bar__label {
  margin: 0 0 12px;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--nb-blue);
}

.nb-pinned-top-bar__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 10px 12px;
  align-items: stretch;
}

.nb-pinned-top-bar__item {
  flex: 1 1 200px;
  min-width: 0;
  max-width: 100%;
}

.nb-pinned-top-bar__link {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 12px;
  min-height: 72px;
  padding: 10px 14px;
  text-decoration: none;
  color: var(--nb-text);
  background: var(--nb-bg);
  border: 1px solid var(--nb-line);
  border-radius: 0;
  box-shadow: 0 2px 12px rgba(15, 23, 42, 0.06);
  transition: border-color 0.18s ease, box-shadow 0.18s ease, color 0.18s ease;
}

.nb-pinned-top-bar__link:hover {
  border-color: rgba(0, 115, 230, 0.35);
  box-shadow: 0 4px 18px rgba(0, 115, 230, 0.12);
  color: var(--nb-blue);
}

.nb-pinned-top-bar__thumb {
  flex-shrink: 0;
  width: 56px;
  height: 56px;
  border-radius: 0;
  overflow: hidden;
  background: #e2e8f0;
}

.nb-pinned-top-bar__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.nb-pinned-top-bar__meta {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

.nb-pinned-top-bar__cat {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--nb-blue-bright, var(--nb-blue));
}

.nb-pinned-top-bar__title {
  font-size: 0.92rem;
  font-weight: 700;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.nb-pinned-top-bar + .nb-hero-wrap {
  padding-top: 16px;
}

@media (max-width: 960px) {
  .nb-pinned-top-bar__inner {
    padding: 14px 16px 14px;
  }

  .nb-pinned-top-bar__list {
    flex-wrap: wrap;
    gap: 8px;
  }

  .nb-pinned-top-bar__item {
    flex: 1 1 100%;
    max-width: 100%;
  }

  .nb-pinned-top-bar__link {
    min-height: 64px;
    padding: 8px 12px;
  }

  .nb-pinned-top-bar__thumb {
    width: 48px;
    height: 48px;
  }

  .nb-pinned-top-bar__title {
    font-size: 0.88rem;
  }
}

.nb-hero-wrap {
  background: var(--nb-bg);
  padding: 24px 0 8px;
}

.nb-hero {
  max-width: 1240px;
  margin: 0 auto;
  padding: 20px 20px 0;
  display: grid;
  grid-template-columns: minmax(0, 1.65fr) minmax(260px, 1fr);
  gap: 20px;
  align-items: stretch;
}

@media (max-width: 960px) {
  .nb-hero {
    grid-template-columns: 1fr;
    padding: 16px 16px 0;
  }
}

.nb-hero-card {
  display: block;
  position: relative;
  text-decoration: none;
  color: #fff;
  border-radius: 0;
  overflow: hidden;
  box-shadow: 0 4px 28px rgba(0, 0, 0, 0.14);
  min-height: 320px;
}

@media (min-width: 961px) {
  .nb-hero-card {
    min-height: 380px;
  }
}

.nb-hero-media {
  position: absolute;
  inset: 0;
  background: #152536;
}

.nb-hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

@media (prefers-reduced-motion: no-preference) {
  .nb-hero-media img {
    transition: transform 0.25s ease;
  }

  .nb-hero-card:hover .nb-hero-media img {
    transform: scale(1.02);
  }
}

.nb-hero-cap {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 24px 22px 22px;
  background: var(--nb-hero-overlay);
}

.nb-hero-meta {
  margin: 0 0 10px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 14px;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.nb-hero-cat {
  color: var(--nb-blue-bright);
}

.nb-hero-time {
  color: rgba(255, 255, 255, 0.82);
}

.nb-hero-cap h1 {
  margin: 0;
  font-size: clamp(1.45rem, 3.6vw, 2.35rem);
  font-weight: 800;
  line-height: 1.14;
  letter-spacing: -0.02em;
  color: #fff;
  text-shadow: 0 2px 14px rgba(0, 0, 0, 0.45);
}

.nb-hero-rail {
  display: flex;
  flex-direction: column;
  background: var(--nb-bg);
  border: 1px solid var(--nb-line);
  border-radius: 0;
  overflow: hidden;
  box-shadow: none;
}

.nb-rail-card {
  padding: 14px 16px;
  text-decoration: none;
  color: var(--nb-text);
  border-bottom: 1px solid var(--nb-line);
}

.nb-rail-card:last-child {
  border-bottom: none;
}

.nb-rail-card:hover {
  background: var(--nb-bg-soft);
}

.nb-rail-meta {
  margin: 0 0 6px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 10px;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.nb-rail-cat {
  color: var(--nb-blue);
}

.nb-rail-time {
  color: var(--nb-muted);
}

.nb-rail-title {
  margin: 0;
  font-size: 0.98rem;
  font-weight: 700;
  line-height: 1.32;
  color: #000;
}

.nb-section {
  max-width: 1240px;
  margin: 0 auto;
  padding: 36px 20px 40px;
}

.nb-section--local {
  background: var(--nb-bg-soft);
  border-top: 1px solid var(--nb-line);
  max-width: none;
  width: 100%;
}

.nb-section--local .nb-section-head,
.nb-section--local .nb-grid--3 {
  max-width: 1240px;
  margin-left: auto;
  margin-right: auto;
}

.nb-section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
  padding-bottom: 10px;
  border-bottom: 3px solid #000;
}

.nb-section-head h2 {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #000;
}

.nb-section-head--plain {
  justify-content: flex-start;
}

.nb-grid--3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

@media (max-width: 900px) {
  .nb-grid--3 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 560px) {
  .nb-grid--3 {
    grid-template-columns: 1fr;
  }
}

.nb-tile {
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: inherit;
  background: var(--nb-bg);
  border: 1px solid var(--nb-line);
  border-radius: 0;
  overflow: hidden;
  transition: box-shadow 0.2s, border-color 0.2s;
}

.nb-section--local .nb-tile {
  background: #fff;
}

.nb-tile:hover {
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.08);
  border-color: #c9cdd4;
}

.nb-tile-media {
  aspect-ratio: 16 / 10;
  background: #dde1e6;
  overflow: hidden;
}

.nb-tile-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

@media (prefers-reduced-motion: no-preference) {
  .nb-tile-media img {
    transition: transform 0.2s ease;
  }

  .nb-tile:hover .nb-tile-media img {
    transform: scale(1.02);
  }
}

.nb-tile-body {
  padding: 14px 16px 16px;
}

.nb-tile-meta {
  margin: 0 0 8px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 10px;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.nb-tile-cat {
  color: var(--nb-blue);
}

.nb-tile-time {
  color: var(--nb-muted);
  font-weight: 600;
}

.nb-tile-title {
  margin: 0;
  font-size: 1.02rem;
  font-weight: 800;
  line-height: 1.28;
  color: #000;
  letter-spacing: -0.015em;
}

.nb-tile:hover .nb-tile-title {
  color: var(--nb-blue);
}

.site-footer--main {
  margin-top: 0;
  background: #2b3036;
  color: rgba(255, 255, 255, 0.82);
  border-top: 4px solid var(--nb-blue);
  box-shadow: none;
}

.site-footer__mark {
  border-radius: 4px;
  background: var(--nb-blue);
  box-shadow: none;
}

.site-footer__name {
  color: #fff !important;
}

.site-footer__nav a {
  color: rgba(255, 255, 255, 0.88);
}

.site-footer__nav a:hover {
  color: var(--nb-blue-bright);
  border-bottom-color: var(--nb-blue-bright);
}

.site-footer__contacts-band {
  background: rgba(0, 0, 0, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.site-footer__contacts .cms-foot-contact__item {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(0, 102, 204, 0.35);
}

.site-footer__contacts .cms-foot-contact__item:hover {
  border-color: var(--nb-blue-bright);
}

.site-footer__text {
  color: rgba(255, 255, 255, 0.55);
}

main:not(.home-container--nb) {
  background: var(--nb-bg);
  border: 1px solid var(--nb-line);
  border-radius: 4px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
}

.post h1 {
  color: var(--nb-text);
  letter-spacing: -0.025em;
  text-align: left;
}

main:not(.home-container--nb) .post .content {
  text-align: left;
}
main:not(.home-container--nb) .post .content .ql-align-center {
  text-align: left !important;
}
main:not(.home-container--nb) .post .content p[style*="text-align: center"],
main:not(.home-container--nb) .post .content p[style*="text-align:center"] {
  text-align: left !important;
}

.meta a {
  color: var(--nb-blue);
}

.meta a:hover {
  color: var(--nb-navy-mid);
}


/* --- 404 --- */
/* Страница 404 */
.page-404 {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 24px 16px;
  font-family: "Source Sans 3", "Inter", system-ui, sans-serif;
  text-align: center;
  background: var(--nb-bg-soft);
  color: var(--nb-text);
  margin: 0;
}
.page-404__hero {
  position: relative;
  width: 100%;
  max-width: 560px;
  height: 280px;
  background: #e5e7eb center/contain no-repeat;
  margin-bottom: 20px;
  border-radius: 12px;
}
.page-404__hero h1 {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  font-size: clamp(4rem, 14vw, 7rem);
  font-weight: 800;
  letter-spacing: -0.04em;
}
.page-404__lead {
  margin: 0 0 16px;
  max-width: 420px;
  line-height: 1.5;
}
.page-404__btn {
  display: inline-block;
  padding: 12px 28px;
  background: var(--nb-blue);
  color: #fff;
  text-decoration: none;
  font-weight: 600;
  border-radius: 10px;
  box-shadow: 0 4px 18px rgba(0, 102, 204, 0.35);
}
.page-404__btn:hover {
  background: #0052a3;
}
