:root {
    --ink: #17384c;
    --ink-soft: #365565;
    --paper: #fffdf8;
    --paper-soft: #f4f0e7;
    --accent: #d86c4b;
    --accent-dark: #ad4f35;
    --gold: #d6ad62;
    --line: rgba(23, 56, 76, .14);
    --shadow: 0 18px 50px rgba(23, 56, 76, .10);
    --radius: 22px;
    --content: 1180px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    margin: 0;
    color: var(--ink);
    background: var(--paper);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    font-size: 17px;
    line-height: 1.72;
    text-rendering: optimizeLegibility;
}
img { max-width: 100%; height: auto; border-radius: 14px; }
a { color: var(--accent-dark); text-decoration-thickness: .08em; text-underline-offset: .18em; }
a:hover { color: var(--accent); }
h1, h2, h3, h4 { color: var(--ink); line-height: 1.14; letter-spacing: -.025em; }
h1 { font-size: clamp(2.45rem, 6vw, 5.8rem); }
h2 { font-size: clamp(1.8rem, 3.4vw, 3rem); }
p { margin-block: 0 1.2em; }

.visually-hidden {
    position: absolute !important;
    width: 1px; height: 1px;
    padding: 0; margin: -1px;
    overflow: hidden; clip: rect(0, 0, 0, 0);
    white-space: nowrap; border: 0;
}
.skip-link { position: fixed; left: 1rem; top: -5rem; z-index: 9999; padding: .7rem 1rem; background: #fff; }
.skip-link:focus { top: 1rem; }

.site-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: rgba(255, 253, 248, .92);
    border-bottom: 1px solid var(--line);
    backdrop-filter: blur(16px);
}
.header-inner {
    width: min(calc(100% - 40px), var(--content));
    min-height: 82px;
    margin-inline: auto;
    display: flex;
    align-items: center;
    gap: 28px;
}
.brand { display: inline-flex; align-items: center; gap: 12px; color: var(--ink); text-decoration: none; font-weight: 800; }
.brand-mark {
    display: grid;
    place-items: center;
    width: 42px; height: 42px;
    border-radius: 50% 50% 46% 54%;
    color: #fff;
    background: var(--accent);
    font-family: Georgia, serif;
    font-size: 1.25rem;
    box-shadow: 5px 5px 0 var(--gold);
}
.brand-text { font-size: 1.15rem; letter-spacing: -.02em; }
.site-navigation { margin-left: auto; }
.site-navigation ul { display: flex; align-items: center; gap: 24px; margin: 0; padding: 0; list-style: none; }
.site-navigation a { color: var(--ink); font-size: .92rem; font-weight: 700; text-decoration: none; }
.site-navigation a:hover, .site-navigation .current > a, .site-navigation .active > a { color: var(--accent); }
.header-search { max-width: 220px; }
.menu-toggle { display: none; margin-left: auto; padding: 8px; border: 0; background: transparent; }
.menu-toggle > span:not(.visually-hidden) { display: block; width: 26px; height: 2px; margin: 5px; background: var(--ink); }

.hero {
    position: relative;
    isolation: isolate;
    min-height: min(720px, 78vh);
    display: grid;
    align-items: center;
    overflow: hidden;
    background:
        linear-gradient(125deg, rgba(23, 56, 76, .97), rgba(23, 56, 76, .82)),
        radial-gradient(circle at 70% 20%, #d6ad62, transparent 45%);
}
.hero::after {
    content: "";
    position: absolute;
    z-index: -1;
    inset: auto -8vw -25vw auto;
    width: min(760px, 64vw);
    aspect-ratio: 1;
    border: 1px solid rgba(255,255,255,.2);
    border-radius: 50%;
    box-shadow: 0 0 0 8vw rgba(255,255,255,.035), 0 0 0 16vw rgba(255,255,255,.025);
}
.hero-glow { position: absolute; z-index: -1; border-radius: 50%; filter: blur(2px); opacity: .8; }
.hero-glow-one { width: 240px; height: 240px; right: 10%; top: 13%; background: rgba(216,108,75,.34); }
.hero-glow-two { width: 130px; height: 130px; right: 27%; bottom: 15%; background: rgba(214,173,98,.28); }
.hero-inner { width: min(calc(100% - 40px), var(--content)); margin-inline: auto; padding-block: 100px; }
.eyebrow { color: var(--accent); font-size: .78rem; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; }
.hero .eyebrow { color: #f5c997; }
.hero h1 { max-width: 900px; margin: .15em 0 .28em; color: #fff; font-family: Georgia, "Times New Roman", serif; font-weight: 500; }
.hero-lead { max-width: 660px; color: rgba(255,255,255,.78); font-size: clamp(1.05rem, 2vw, 1.35rem); }
.hero-link { display: inline-flex; gap: 12px; margin-top: 20px; color: #fff; font-weight: 750; text-decoration: none; }
.hero-link:hover { color: #f5c997; }

.content-shell {
    width: min(calc(100% - 40px), var(--content));
    margin: 0 auto;
    padding: clamp(58px, 8vw, 112px) 0;
    display: grid;
    align-items: start;
    gap: 42px;
}
.layout-one { grid-template-columns: minmax(0, 1fr); }
.layout-two { grid-template-columns: minmax(210px, 280px) minmax(0, 1fr); }
.layout-two .site-main:first-child { grid-column: 1; }
.layout-two .site-main + .sidebar-right { grid-column: 2; }
.layout-three { grid-template-columns: minmax(190px, 240px) minmax(0, 1fr) minmax(190px, 240px); }
.site-main { min-width: 0; }
.site-main > *:first-child { margin-top: 0; }
.site-main article { margin-bottom: 64px; }
.site-main .page-header h1, .site-main .page-header h2 { font-family: Georgia, "Times New Roman", serif; }
.sidebar { position: sticky; top: 110px; }

.card, .sidebar .moduletable, .module-grid .moduletable {
    margin-bottom: 24px;
    padding: 26px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #fff;
    box-shadow: var(--shadow);
}
.module-band, .module-grid { width: min(calc(100% - 40px), var(--content)); margin-inline: auto; }
.banner-band { padding-top: 44px; }
.module-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 26px; }
.module-grid-top { padding-top: 58px; }
.module-grid-bottom { grid-template-columns: repeat(3, minmax(0,1fr)); }
.bottom-area { padding: 74px 0; background: var(--paper-soft); }

input, select, textarea, button { font: inherit; }
input:not([type="checkbox"]):not([type="radio"]), select, textarea {
    max-width: 100%;
    padding: .72rem .9rem;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #fff;
    color: var(--ink);
}
.button, button, input[type="submit"] {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    padding: .76rem 1.15rem;
    border: 0;
    border-radius: 999px;
    background: var(--accent);
    color: #fff;
    font-weight: 750;
    text-decoration: none;
    cursor: pointer;
}
.button:hover, button:hover, input[type="submit"]:hover { background: var(--accent-dark); color: #fff; }
table { width: 100%; border-collapse: collapse; }
th, td { padding: .75rem; border-bottom: 1px solid var(--line); text-align: left; }

.pagination ul { display: flex; flex-wrap: wrap; gap: 8px; padding: 0; list-style: none; }
.pagination a, .pagination span { display: grid; place-items: center; min-width: 40px; min-height: 40px; border: 1px solid var(--line); border-radius: 50%; text-decoration: none; }
.breadcrumb { display: flex; flex-wrap: wrap; gap: 8px; padding: 0; list-style: none; font-size: .86rem; }

.site-footer { padding: 64px 0; background: var(--ink); color: rgba(255,255,255,.72); }
.footer-inner { width: min(calc(100% - 40px), var(--content)); margin-inline: auto; display: grid; grid-template-columns: 1fr auto; gap: 34px; align-items: end; }
.site-footer strong { color: #fff; font-size: 1.4rem; }
.site-footer p { margin: 6px 0 0; }
.site-footer a { color: #f5c997; }
.site-footer small { grid-column: 1 / -1; padding-top: 24px; border-top: 1px solid rgba(255,255,255,.13); }

.content-only .site-main { width: min(calc(100% - 40px), 980px); margin: 40px auto; }
.error-page { min-height: 100vh; display: grid; place-items: center; padding: 24px; background: var(--paper-soft); }
.error-card { width: min(100%, 680px); padding: clamp(34px, 6vw, 70px); border-radius: 28px; background: #fff; box-shadow: var(--shadow); text-align: center; }
.error-brand { justify-content: center; }
.error-code { margin: 28px 0 0; color: var(--accent); font-size: clamp(4rem, 14vw, 8rem); font-weight: 900; line-height: 1; }
.error-card h1 { margin: .25em 0; }

@media (max-width: 900px) {
    body { font-size: 16px; }
    .header-inner { min-height: 70px; }
    .menu-toggle { display: block; }
    .site-navigation { display: none; position: absolute; inset: 70px 0 auto; padding: 22px; background: var(--paper); border-bottom: 1px solid var(--line); box-shadow: var(--shadow); }
    .site-navigation.is-open { display: block; }
    .site-navigation ul { align-items: stretch; flex-direction: column; gap: 0; }
    .site-navigation li { border-bottom: 1px solid var(--line); }
    .site-navigation a { display: block; padding: 12px 4px; }
    .header-search { display: none; }
    .layout-two, .layout-three { grid-template-columns: minmax(0, 1fr); }
    .sidebar { position: static; }
    .sidebar-left { order: 2; }
    .site-main { order: 1; }
    .sidebar-right { order: 3; }
    .module-grid, .module-grid-bottom { grid-template-columns: 1fr; }
    .footer-inner { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
    .header-inner, .hero-inner, .content-shell, .module-band, .module-grid, .footer-inner { width: min(calc(100% - 28px), var(--content)); }
    .brand-text { font-size: 1rem; }
    .hero { min-height: 600px; }
    .hero-inner { padding-block: 74px; }
    .content-shell { padding-block: 52px; }
    .card, .sidebar .moduletable, .module-grid .moduletable { padding: 20px; border-radius: 16px; }
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
/* Аккуратные заголовки на странице контактов */
.com-contact h1,
.com-contact .contact-name {
  font-size: clamp(2rem, 4vw, 3.25rem);
  line-height: 1.1;
}

.com-contact h2,
.com-contact h3,
.com-contact legend {
  font-size: clamp(1.4rem, 2.5vw, 2rem);
  line-height: 1.2;
}
@media (min-width: 901px) {
  .layout-two:has(.sidebar-right) {
    grid-template-columns: minmax(0, 1fr) 320px !important;
    gap: 42px;
  }

  .layout-two .site-main,
  .layout-two .sidebar-right {
    min-width: 0;
  }
}
/* Блок «Новое на сайте» */
.latest-home {
  margin-top: 42px;
}

.latest-home ul {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.latest-home li {
  margin: 0;
  padding: 22px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 18px;
  box-shadow: 0 10px 30px rgba(23, 56, 76, 0.07);
}

.latest-home li > a {
  display: inline-block;
  color: var(--ink);
  font-size: 1.05rem;
  font-weight: 700;
  line-height: 1.35;
}

.latest-home li > a:hover {
  color: var(--accent);
}

.latest-home .mod-articles-category-date {
  display: block;
  margin-bottom: 8px;
  color: #6b7c86;
  font-size: 0.82rem;
}

.latest-home .mod-articles-category-introtext {
  margin: 12px 0;
  line-height: 1.65;
}

.latest-home .mod-articles-category-readmore {
  display: inline-block;
  margin-top: 8px;
  font-weight: 700;
}

@media (max-width: 760px) {
  .latest-home ul {
    grid-template-columns: 1fr;
  }

  .latest-home li {
    padding: 18px;
  }
}
/* Пиктограммы в карточках «Новое на сайте» */
.latest-home li {
  position: relative;
  padding-top: 88px;
  overflow: hidden;
}

.latest-home li::before {
  content: "🇸🇪";
  position: absolute;
  top: 22px;
  left: 22px;
  display: flex;
  width: 48px;
  height: 48px;
  align-items: center;
  justify-content: center;
  border-radius: 15px;
  background: #f8e5d8;
  font-size: 25px;
  line-height: 1;
  box-shadow: 0 7px 18px rgba(23, 56, 76, 0.10);
}

.latest-home li:nth-child(2)::before {
  content: "🗣️";
  background: #e1edf0;
}

.latest-home li:nth-child(3)::before {
  content: "🕒";
  background: #f3ead4;
}

.latest-home li:nth-child(4)::before {
  content: "📘";
  background: #e5e8f3;
}

.latest-home li:nth-child(5)::before {
  content: "✍️";
  background: #e7efe3;
}

.latest-home li:nth-child(6)::before {
  content: "💬";
  background: #f3e1e5;
}

@media (max-width: 760px) {
  .latest-home li {
    padding-top: 82px;
  }

  .latest-home li::before {
    top: 18px;
    left: 18px;
  }
}
/* Выравнивание карточек «Новое на сайте» */
.latest-home li {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  min-height: 360px;
  padding: 82px 24px 24px;
  text-align: left;
}

/* Заголовок карточки */
.latest-home li > a:first-of-type {
  display: block;
  min-height: 2.8em;
  margin-bottom: 16px;
  font-size: 1.03rem;
  line-height: 1.35;
  text-align: left;
}

/* Вводный текст */
.latest-home .mod-articles-category-introtext {
  width: 100%;
  margin: 0 0 18px;
  color: var(--ink);
  font-size: 0.96rem;
  line-height: 1.65;
  text-align: left;
}

/* Абзацы внутри вводного текста */
.latest-home .mod-articles-category-introtext p {
  margin: 0 0 12px;
  text-align: left;
}

/* Ссылка «Подробнее» всегда внизу карточки */
.latest-home .mod-articles-category-readmore {
  margin-top: auto;
  padding-top: 16px;
  text-align: left;
}

/* Немного аккуратнее оформляем ссылку */
.latest-home .mod-articles-category-readmore a {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-weight: 700;
  text-decoration: none;
}

.latest-home .mod-articles-category-readmore a::after {
  content: "→";
  transition: transform 0.2s ease;
}

.latest-home .mod-articles-category-readmore a:hover::after {
  transform: translateX(4px);
}

/* Телефон */
@media (max-width: 760px) {
  .latest-home li {
    min-height: auto;
    padding: 78px 20px 22px;
  }

  .latest-home li > a:first-of-type {
    min-height: auto;
  }
}
/* Принудительно выравниваем содержимое карточек влево */
.latest-home li,
.latest-home li > *,
.latest-home .mod-articles-category-introtext,
.latest-home .mod-articles-category-introtext *,
.latest-home li p,
.latest-home li div {
  text-align: left !important;
}

/* Текст занимает всю ширину карточки */
.latest-home .mod-articles-category-introtext {
  width: 100%;
}

/* Нормальные интервалы между абзацами */
.latest-home .mod-articles-category-introtext p {
  margin: 0 0 12px;
  line-height: 1.65;
}

/* «Подробнее» остаётся у левого края и внизу */
.latest-home .mod-articles-category-readmore {
  width: 100%;
  margin-top: auto !important;
  text-align: left !important;
}
/* Более компактные карточки */
.latest-home li {
  min-height: 310px;
  padding: 78px 20px 20px;
}

.latest-home li > a:first-of-type {
  min-height: auto;
  margin-bottom: 14px;
}

.latest-home .mod-articles-category-introtext {
  margin-bottom: 14px;
}

.latest-home .mod-articles-category-readmore {
  padding-top: 10px;
}
/* Популярные разделы на главной */
.home-sections {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin: 24px 0 44px;
}

.home-section-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
  min-height: 190px;
  padding: 24px;
  color: var(--ink);
  text-align: left;
  text-decoration: none;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 18px;
  box-shadow: 0 10px 30px rgba(23, 56, 76, 0.07);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.home-section-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 36px rgba(23, 56, 76, 0.12);
}

.home-section-icon {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: var(--paper-soft);
  font-size: 1.35rem;
}

.home-section-card strong {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.25rem;
  line-height: 1.25;
}

.home-section-card span:last-child {
  color: #365565;
  line-height: 1.6;
}

@media (max-width: 760px) {
  .home-sections {
    grid-template-columns: 1fr;
  }

  .home-section-card {
    min-height: auto;
  }
}
/* Исправление мобильной версии */
@media (max-width: 820px) {

  html,
  body {
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
  }

  /* Основной текст и боковое меню размещаем друг под другом */
  .content-shell,
  .content-shell.layout-two,
  .content-shell.layout-three,
  .layout-two,
  .layout-three {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    width: min(calc(100% - 28px), var(--content)) !important;
    max-width: 100% !important;
    gap: 28px !important;
  }

  .site-main,
  .sidebar,
  .sidebar-left,
  .sidebar-right {
    grid-column: 1 / -1 !important;
    width: 100% !important;
    min-width: 0 !important;
    max-width: none !important;
    position: static !important;
  }

  .site-main {
    order: 1;
  }

  .sidebar-left,
  .sidebar-right {
    order: 2;
  }

  /* Карточки материалов — по одной в строке */
  .module-grid,
  .module-grid-bottom,
  .blog-items,
  .mod-articlesnews-horizontal,
  .mod-articles-category-group {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    gap: 18px !important;
  }

  .module-grid > *,
  .module-grid-bottom > *,
  .blog-items > *,
  .mod-articlesnews-horizontal > *,
  .mod-articles-category-group > * {
    display: block !important;
    width: 100% !important;
    min-width: 0 !important;
    max-width: none !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    box-sizing: border-box !important;
  }

  /* Не позволяем длинным словам выходить за карточку */
  .module-grid *,
  .module-grid-bottom *,
  .blog-items * {
    max-width: 100%;
    overflow-wrap: anywhere;
  }
}

@media (max-width: 560px) {

  .content-shell,
  .content-shell.layout-two,
  .content-shell.layout-three {
    width: calc(100% - 28px) !important;
  }

  .card,
  .moduletable {
    width: 100% !important;
    min-width: 0 !important;
    padding: 20px !important;
  }
}
/* Размер главных заголовков внутри материалов */
.com-content-article__body h1,
.item-page h1 {
    font-size: clamp(2.2rem, 4vw, 3.5rem) !important;
    line-height: 1.08 !important;
    letter-spacing: -0.02em;
    margin-bottom: 32px;
}

/* Размер заголовка на телефонах */
@media (max-width: 560px) {
    .com-content-article__body h1,
    .item-page h1 {
        font-size: 2.25rem !important;
        line-height: 1.12 !important;
        margin-bottom: 24px;
    }
}
/* Нормальный размер заголовков старых материалов */
.item-page h1,
.com-content-article h1,
.com-content-article__body h1,
.page-header h1 {
    font-size: clamp(2.2rem, 4vw, 3.5rem) !important;
    line-height: 1.08 !important;
    letter-spacing: -0.02em;
    margin: 0 0 32px !important;
}

/* Телефоны */
@media (max-width: 560px) {
    .item-page h1,
    .com-content-article h1,
    .com-content-article__body h1,
    .page-header h1 {
        font-size: 2.25rem !important;
        line-height: 1.12 !important;
        margin-bottom: 24px !important;
    }
}
/* Размер заголовков старых материалов */
.item-page h1,
.item-page h1 *,
.item-page h2,
.item-page h2 *,
.com-content-article h1,
.com-content-article h1 *,
.com-content-article h2,
.com-content-article h2 *,
.com-content-article__body h1,
.com-content-article__body h1 *,
.com-content-article__body h2,
.com-content-article__body h2 * {
    font-size: clamp(2rem, 4vw, 3.4rem) !important;
    line-height: 1.1 !important;
    letter-spacing: -0.02em !important;
    margin-top: 0 !important;
    margin-bottom: 28px !important;
}

@media (max-width: 560px) {
    .item-page h1,
    .item-page h1 *,
    .item-page h2,
    .item-page h2 *,
    .com-content-article h1,
    .com-content-article h1 *,
    .com-content-article h2,
    .com-content-article h2 * {
        font-size: 2.1rem !important;
        line-height: 1.15 !important;
    }
}
/* Заголовки в списках и блогах материалов */
.com-content-category-blog .blog-item h2,
.com-content-category-blog .blog-item h2 a,
.blog-items .blog-item .page-header h2,
.blog-items .blog-item .page-header h2 a,
.blog-featured .blog-item .page-header h2,
.blog-featured .blog-item .page-header h2 a,
.blog-item .item-title,
.blog-item .item-title a {
    font-size: clamp(1.35rem, 2vw, 1.75rem) !important;
    line-height: 1.25 !important;
    letter-spacing: normal !important;
    margin-top: 0 !important;
    margin-bottom: 14px !important;
}

/* Размер на телефоне */
@media (max-width: 560px) {
    .com-content-category-blog .blog-item h2,
    .com-content-category-blog .blog-item h2 a,
    .blog-items .blog-item .page-header h2,
    .blog-items .blog-item .page-header h2 a,
    .blog-item .item-title,
    .blog-item .item-title a {
        font-size: 1.25rem !important;
        line-height: 1.3 !important;
    }
}
/* Заголовки внутри анонсов на страницах со списком материалов */
body .blog .blog-item h1,
body .blog .blog-item h2,
body .blog .blog-item h3,
body .blog-items .blog-item h1,
body .blog-items .blog-item h2,
body .blog-items .blog-item h3,
body .items-leading .blog-item h1,
body .items-leading .blog-item h2,
body .items-leading .blog-item h3,
body .items-row .blog-item h1,
body .items-row .blog-item h2,
body .items-row .blog-item h3,
body .blog-item [itemprop="articleBody"] h1,
body .blog-item [itemprop="articleBody"] h2,
body .blog-item [itemprop="articleBody"] h3 {
    font-size: clamp(26px, 3vw, 38px) !important;
    line-height: 1.15 !important;
    letter-spacing: -0.02em !important;
    text-align: left !important;
    margin: 0 0 20px !important;
    max-width: 100% !important;
}
/* ==================================================
   СПИСКИ МАТЕРИАЛОВ: ОТСТУПЫ И НОРМАЛЬНАЯ ПАГИНАЦИЯ
   ================================================== */

/* Больше воздуха между материалами категории */
.com-content-category-blog :where(
  .blog-item,
  .com-content-category-blog__item
) {
  display: flow-root;
  clear: both;
  margin-bottom: 58px !important;
  padding-bottom: 42px !important;
  border-bottom: 1px solid rgba(23, 56, 76, 0.12);
}

/* У последнего материала разделительная линия не нужна */
.com-content-category-blog :where(
  .blog-item,
  .com-content-category-blog__item
):last-child {
  border-bottom: 0;
}

/* Отделяем навигацию от материалов */
.pagination__wrapper,
.com-content-category-blog__navigation,
.com-content-category-blog__pagination {
  clear: both;
  margin-top: 34px !important;
  margin-bottom: 40px !important;
}

/* Надпись «Страница 1 из 8» */
.pagination__wrapper .counter,
.com-content-category-blog__navigation .counter,
.com-content-category-blog__pagination .counter {
  margin: 0 0 14px;
  text-align: center;
  font-size: 14px;
}

/* Горизонтальный ряд кнопок */
ul.pagination,
.pagination {
  display: flex !important;
  flex-direction: row !important;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px;

  width: auto !important;
  margin: 0 !important;
  padding: 0 !important;
  list-style: none !important;
}

/* Убираем точки списка и растянутые овалы */
.pagination > li,
.pagination .page-item {
  display: block !important;
  width: auto !important;
  height: auto !important;
  margin: 0 !important;
  padding: 0 !important;
  list-style: none !important;
}

.pagination > li::marker,
.pagination .page-item::marker {
  content: "";
}

/* Обычная кнопка страницы */
.pagination .page-link,
.pagination a,
.pagination span {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;

  width: auto !important;
  min-width: 40px;
  height: 40px;
  margin: 0 !important;
  padding: 0 12px !important;

  color: var(--accent, #d86c4b);
  background: #fff;
  border: 1px solid rgba(23, 56, 76, 0.18) !important;
  border-radius: 10px !important;
  box-shadow: none !important;
  text-decoration: none;
  line-height: 1;
}

/* Текущая страница */
.pagination .active .page-link,
.pagination .page-item.active .page-link {
  color: #fff !important;
  background: var(--accent, #d86c4b) !important;
  border-color: var(--accent, #d86c4b) !important;
}

/* Неактивные кнопки */
.pagination .disabled .page-link,
.pagination .page-item.disabled .page-link {
  color: #8a9499 !important;
  background: #f5f4f0 !important;
  opacity: 0.65;
}

/* Наведение */
.pagination a:hover,
.pagination .page-link:hover {
  color: #fff !important;
  background: var(--ink, #17384c) !important;
  border-color: var(--ink, #17384c) !important;
}

/* Стрелки, если значки Joomla не загрузились */
.pagination .icon-angle-double-left::before {
  content: "«";
  font-family: inherit !important;
}

.pagination .icon-angle-left::before {
  content: "‹";
  font-family: inherit !important;
}

.pagination .icon-angle-right::before {
  content: "›";
  font-family: inherit !important;
}

.pagination .icon-angle-double-right::before {
  content: "»";
  font-family: inherit !important;
}

/* Телефоны */
@media (max-width: 560px) {
  .com-content-category-blog :where(
    .blog-item,
    .com-content-category-blog__item
  ) {
    margin-bottom: 40px !important;
    padding-bottom: 30px !important;
  }

  .pagination {
    gap: 6px;
  }

  .pagination .page-link,
  .pagination a,
  .pagination span {
    min-width: 36px;
    height: 36px;
    padding: 0 9px !important;
  }
}
/* Исправление материалов на мобильных экранах */
@media (max-width: 700px) {

  .blog-items .blog-item,
  .blog .blog-item,
  .items-row > div {
    display: block !important;
    width: 100% !important;
    clear: both !important;
  }

  .blog-items .item-image,
  .blog .item-image,
  .blog-items .pull-left,
  .blog-items .pull-right,
  .blog-items .float-start,
  .blog-items .float-end {
    float: none !important;
    display: block !important;
    width: 100% !important;
    max-width: none !important;
    margin: 0 0 20px 0 !important;
  }

  .blog-items .item-image img,
  .blog .item-image img {
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    height: auto !important;
    max-height: 320px;
    object-fit: contain;
    object-position: left center;
    border-radius: 16px;
  }

  .blog-items .page-header,
  .blog-items .item-title,
  .blog-items h2,
  .blog .page-header,
  .blog .item-title,
  .blog h2 {
    display: block !important;
    width: 100% !important;
    max-width: none !important;
    margin: 0 0 16px 0 !important;
    text-align: left !important;
    overflow-wrap: normal !important;
    word-break: normal !important;
  }

  .blog-items .item-content,
  .blog-items .item-content p,
  .blog .item-content,
  .blog .item-content p {
    width: 100% !important;
    clear: both !important;
    text-align: left !important;
  }

  .blog-items .blog-item + .blog-item,
  .blog .blog-item + .blog-item {
    margin-top: 42px !important;
    padding-top: 34px !important;
    border-top: 1px solid var(--line);
  }
}
/* Исправление списка материалов на телефоне */
@media (max-width: 700px) {
  .blog-items .blog-item,
  .blog-item,
  .items-leading > div,
  .items-row > div {
    display: flex !important;
    flex-direction: column !important;
    grid-template-columns: 1fr !important;
    align-items: stretch !important;
    width: 100% !important;
    min-width: 0 !important;
  }

  .blog-item > *,
  .blog-item .item-content,
  .blog-item .page-header {
    display: block !important;
    float: none !important;
    clear: both !important;
    width: 100% !important;
    min-width: 0 !important;
    max-width: none !important;
  }

  .blog-item figure,
  .blog-item .item-image,
  .blog-item .pull-left,
  .blog-item .pull-right,
  .blog-item img[align="left"],
  .blog-item img[align="right"] {
    display: block !important;
    float: none !important;
    clear: both !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 0 20px !important;
  }

  .blog-item img {
    display: block !important;
    width: auto !important;
    max-width: 100% !important;
    height: auto !important;
    margin-left: auto !important;
    margin-right: auto !important;
  }

  .blog-item h1,
  .blog-item h2,
  .blog-item h3,
  .blog-item .page-header h2 {
    display: block !important;
    float: none !important;
    clear: both !important;
    width: 100% !important;
    max-width: none !important;
    font-size: 1.65rem !important;
    line-height: 1.15 !important;
    word-break: normal !important;
    overflow-wrap: normal !important;
    hyphens: none !important;
    margin: 0 0 16px !important;
  }
}
/* Старые материалы: картинка сверху, заголовок и текст ниже */
@media (max-width: 700px) {

  .blog-item,
  .com-content-category-blog__item,
  .com-content-featured__item,
  .items-leading > div,
  .items-row > div {
    display: block !important;
    width: 100% !important;
    min-width: 0 !important;
  }

  /* Убираем старое обтекание */
  .blog-item [style*="float"],
  .blog-item [align="left"],
  .blog-item [align="right"],
  .com-content-category-blog__item [style*="float"],
  .com-content-featured__item [style*="float"] {
    float: none !important;
    clear: both !important;
  }

  /* Картинка занимает отдельную строку */
  .blog-item figure,
  .blog-item .item-image,
  .blog-item .pull-left,
  .blog-item .pull-right,
  .com-content-category-blog__item figure,
  .com-content-category-blog__item .item-image,
  .com-content-featured__item figure,
  .com-content-featured__item .item-image {
    display: block !important;
    float: none !important;
    clear: both !important;
    width: 100% !important;
    margin: 0 0 22px !important;
    text-align: center !important;
  }

  .blog-item img,
  .com-content-category-blog__item img,
  .com-content-featured__item img {
    display: block !important;
    float: none !important;
    clear: both !important;
    width: auto !important;
    max-width: 100% !important;
    height: auto !important;
    margin: 0 auto 22px !important;
  }

  /* Заголовок на всю ширину под картинкой */
  .blog-item .page-header,
  .blog-item .item-title,
  .blog-item h1,
  .blog-item h2,
  .blog-item h3,
  .com-content-category-blog__item .page-header,
  .com-content-category-blog__item .item-title,
  .com-content-category-blog__item h1,
  .com-content-category-blog__item h2,
  .com-content-category-blog__item h3,
  .com-content-featured__item .page-header,
  .com-content-featured__item .item-title,
  .com-content-featured__item h1,
  .com-content-featured__item h2,
  .com-content-featured__item h3 {
    display: block !important;
    float: none !important;
    clear: both !important;
    width: 100% !important;
    max-width: none !important;
    margin: 0 0 16px !important;
    font-size: 1.65rem !important;
    line-height: 1.2 !important;
    word-break: normal !important;
    overflow-wrap: normal !important;
    hyphens: none !important;
  }

  /* Исправляем материалы со старой табличной разметкой */
  .blog-item table,
  .blog-item tbody,
  .blog-item tr,
  .blog-item td,
  .com-content-category-blog__item table,
  .com-content-category-blog__item tbody,
  .com-content-category-blog__item tr,
  .com-content-category-blog__item td {
    display: block !important;
    float: none !important;
    clear: both !important;
    width: 100% !important;
    max-width: 100% !important;
  }
}