/* Федеральная арбитражная палата — прототип дизайна */
:root {
  --bg: #f7f6f3;
  --surface: #ffffff;
  --surface-2: #fbfaf8;
  --ink: #1f2125;
  --ink-2: #3a3d43;
  --muted: #61656c;
  --line: #e4e0d9;
  --line-strong: #cfc9bf;
  --brand: #6b1e24;
  --brand-hover: #561419;
  --brand-soft: #f4ebe9;
  --graphite: #2b2d31;
  --graphite-2: #383a3f;
  --ok: #2f6b3f;
  --ok-soft: #eaf3ec;
  --warn: #8a5a00;
  --warn-soft: #fbf3e2;
  --err: #9b1c1c;
  --err-soft: #fbecec;
  --radius: 10px;
  --radius-sm: 6px;
  --shadow: 0 1px 2px rgba(31, 33, 37, .04), 0 4px 16px rgba(31, 33, 37, .05);
  --serif: "PT Serif", Georgia, "Times New Roman", serif;
  --sans: "Inter", "PT Sans", "Segoe UI", system-ui, -apple-system, Roboto, Arial, sans-serif;
  --wrap: 1200px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 16px/1.6 var(--sans);
}
img { max-width: 100%; height: auto; }
a { color: var(--brand); text-underline-offset: 3px; }
a:hover { color: var(--brand-hover); }
:focus-visible { outline: 3px solid rgba(107, 30, 36, .35); outline-offset: 2px; border-radius: 4px; }

h1, h2, h3, h4 { font-family: var(--serif); color: var(--ink); line-height: 1.25; margin: 0 0 .6em; font-weight: 700; }
h1 { font-size: clamp(1.75rem, 1.2rem + 2vw, 2.6rem); }
h2 { font-size: clamp(1.35rem, 1.1rem + 1vw, 1.8rem); }
h3 { font-size: 1.2rem; }
p { margin: 0 0 1em; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 16px; }
@media (min-width: 720px) { .wrap { padding: 0 28px; } }

.skip-link { position: absolute; left: -9999px; top: 8px; background: var(--brand); color: #fff; padding: 8px 14px; z-index: 100; border-radius: 6px; }
.skip-link:focus { left: 16px; color: #fff; }

/* ---------- шапка (начинается от верхнего края страницы; телефон и почта — в «Контактах», подвале и мобильном меню) ---------- */

/* логотип в подвале */
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); }
.brand:hover { color: var(--ink); }
.brand__mark { width: 46px; height: 46px; flex: none; }
.brand__name { font-family: var(--serif); font-weight: 700; line-height: 1.15; font-size: 1.05rem; letter-spacing: .01em; }
.brand__name small { display: block; font-family: var(--sans); font-weight: 500; font-size: .72rem; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin-top: 3px; }

/* ---------- шапка: бордовый градиент, золотые акценты (по утверждённому образцу) ---------- */
.header {
  --hdr-gold: #c9a15a;
  --hdr-serif: "Times New Roman", Times, "PT Serif", Georgia, serif;
  position: relative; z-index: 50; color: #f3e7d3;
  background:
    radial-gradient(38% 90% at 70% 0%, rgba(176, 32, 46, .55) 0%, rgba(176, 32, 46, 0) 100%),
    radial-gradient(30% 80% at 100% 100%, rgba(150, 22, 34, .45) 0%, rgba(150, 22, 34, 0) 100%),
    radial-gradient(28% 70% at 0% 100%, rgba(140, 20, 30, .4) 0%, rgba(140, 20, 30, 0) 100%),
    linear-gradient(100deg, #3c060b 0%, #560c14 30%, #66111b 55%, #570d15 78%, #430810 100%);
  border-bottom: 5px solid transparent;
  border-image: linear-gradient(90deg, #a77d3e, #d6b06c 30%, #c49a55 70%, #a77d3e) 1;
}
.header .wrap {
  display: grid; grid-template-columns: auto auto minmax(0, 1fr) auto;
  grid-template-areas: "mark div title search" "mark div nav nav";
  column-gap: 32px; align-items: center; padding-top: 28px;
}
.hdr__mark { grid-area: mark; display: block; padding-bottom: 14px; line-height: 0; cursor: default; }  /* герб — без ссылки */
/* Государственный герб РФ — официальное изображение (векторный SVG) без изменений, только масштаб.
   Показывается фоном, а не <img>: нет пункта «Сохранить изображение», нельзя перетащить, на телефонах нет меню
   долгого нажатия. Пропорции — как у исходного SVG (93.965 × 103.254 мм). */
.hdr__emblem { display: block; height: 142px; aspect-ratio: 93.965 / 103.254;
  background: url("../img/gerb-rf-2/gerb-rf-2.svg") center / contain no-repeat;
  filter: drop-shadow(0 2px 3px rgba(0, 0, 0, .4));
  -webkit-user-select: none; user-select: none; -webkit-user-drag: none; -webkit-touch-callout: none; }
.hdr__divider { grid-area: div; align-self: stretch; width: 2px; margin: 4px 0 18px; background: linear-gradient(180deg, #b48a46, #e2c181 50%, #b48a46); }
.hdr__title {
  grid-area: title; justify-self: start; text-decoration: none; text-transform: uppercase;
  font: 700 2.6rem/1.08 var(--hdr-serif); letter-spacing: .055em; margin-bottom: 8px;
  color: #e3c07c;
  background: linear-gradient(180deg, #f8e6b8 0%, #e2bd76 42%, #b98a42 68%, #e7c98a 100%);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 2px 1px rgba(30, 2, 6, .55));
}
.hdr__title > span { display: block; white-space: nowrap; }
.hdr__title:focus-visible { outline-color: rgba(226, 193, 129, .7); }
.hdr__search { grid-area: search; width: 320px; }

.search { display: flex; align-items: center; position: relative; }
.search input {
  width: 100%; height: 50px; padding: 0 52px 0 18px; border-radius: 8px;
  border: 1.5px solid var(--hdr-gold, #c9a15a); background: rgba(40, 4, 8, .22);
  font: 400 1.05rem var(--hdr-serif, var(--serif)); color: #fff4e3;
  -webkit-appearance: none; appearance: none;
}
.search input::placeholder { color: #eadbc3; opacity: 1; }
.search input::-webkit-search-cancel-button { -webkit-appearance: none; }
.search input:focus { outline: none; border-color: #e6c886; box-shadow: 0 0 0 3px rgba(226, 193, 129, .28); }
.search button {
  position: absolute; right: 6px; top: 50%; transform: translateY(-50%); width: 40px; height: 40px;
  display: grid; place-items: center; border: 0; border-radius: 6px; background: transparent; color: #fff4e3; cursor: pointer;
}
.search button:hover { color: #f3d896; }
.search button svg { width: 24px; height: 24px; stroke-width: 2.4; }

.nav { grid-area: nav; }
.nav ul { list-style: none; margin: 0; padding: 0; display: flex; justify-content: space-between; gap: 8px; }
.nav a {
  position: relative; display: flex; align-items: center; gap: 10px; padding: 15px 6px 19px;
  color: #f6ecdc; text-decoration: none; font: 400 1.22rem/1.2 var(--hdr-serif); white-space: nowrap;
}
.nav a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 3px; height: 3px; border-radius: 2px;
  background: linear-gradient(90deg, #d9b56f, #f0d79e, #d9b56f); transform: scaleX(0); transition: transform .15s;
}
.nav a:hover { color: #fff; }
.nav a:hover::after { transform: scaleX(.6); }
.nav a[aria-current="page"] { color: #fff; }
.nav a[aria-current="page"]::after { transform: scaleX(1); }
.nav__home { width: 24px; height: 24px; color: #e8c987; flex: none; margin-top: -3px; }
.nav__search { display: none; }
.nav__contacts { display: none; }   /* контакты в раскрывающемся меню — только на телефонах и планшетах */
.nav__toggle {
  grid-area: search; justify-self: end; display: none; align-items: center; gap: 8px;
  border: 1.5px solid var(--hdr-gold); background: transparent; color: #f3e2bf;
  padding: 9px 14px; border-radius: 8px; font: 500 .95rem var(--sans); cursor: pointer;
}
.nav__toggle:hover { background: rgba(255, 255, 255, .06); }
.nav__toggle svg { width: 18px; height: 18px; }

@media (max-width: 1240px) {
  .header .wrap { column-gap: 24px; }
  .hdr__emblem { height: 124px; }
  .hdr__title { font-size: 2.15rem; }
  .hdr__search { width: 270px; }
  .nav a { font-size: 1.1rem; padding-left: 4px; padding-right: 4px; }
}
@media (max-width: 1080px) {
  .hdr__title { font-size: 1.8rem; }
  .hdr__search { width: 230px; }
  .nav a { font-size: .98rem; gap: 7px; }
  .nav__home { width: 20px; height: 20px; }
}

/* планшеты и телефоны: компактная шапка, меню и поиск — в раскрывающейся панели */
@media (max-width: 1000px) {
  .header { position: sticky; top: 0; border-bottom-width: 3px; }
  .header .wrap { grid-template-areas: "mark div title search"; column-gap: 14px; padding-top: 10px; padding-bottom: 10px; }
  .hdr__mark { padding-bottom: 0; }
  .hdr__title { margin-bottom: 0; }
  .hdr__emblem { height: 58px; }
  .hdr__divider { margin: 2px 0; width: 1.5px; }
  .hdr__title { font-size: 1.15rem; letter-spacing: .045em; }
  .hdr__search { display: none; }
  .nav__toggle { display: inline-flex; }
  .nav {
    display: none; position: absolute; left: 0; right: 0; top: 100%; padding: 6px 16px 18px;
    background: linear-gradient(180deg, #4f0b12, #3e070c); border-top: 1px solid rgba(201, 161, 90, .45);
    box-shadow: 0 12px 24px rgba(30, 2, 6, .35);
  }
  .nav.is-open { display: block; }
  .nav ul { flex-direction: column; gap: 0; }
  .nav li + li { border-top: 1px solid rgba(201, 161, 90, .18); }
  .nav a { padding: 13px 0 13px 14px; font-size: 1.08rem; }
  .nav a::after { left: 0; right: auto; top: 10px; bottom: 10px; width: 3px; height: auto; transform: scaleY(0); }
  .nav a[aria-current="page"]::after { transform: scaleY(1); }
  .nav__search { display: block; padding-top: 12px; }
  /* верхняя полоса с контактами скрыта — телефон и почта внизу раскрывающегося меню (не дублируются) */
  .nav__contacts {
    display: flex; flex-wrap: wrap; gap: 6px 28px; margin-top: 14px; padding: 12px 0 0 14px;
    border-top: 1px solid rgba(201, 161, 90, .18);
  }
  .nav .nav__contacts a { padding: 6px 0; font: 400 .95rem/1.4 var(--sans); color: #f1e4c8; white-space: nowrap; }
  .nav .nav__contacts a::after { content: none; }
  .nav .nav__contacts a:hover { color: #fff; text-decoration: underline; }
}
@media (min-width: 720px) and (max-width: 1000px) { .nav { padding-left: 28px; padding-right: 28px; } }
@media (max-width: 480px) {
  .header .wrap { column-gap: 10px; }
  .hdr__emblem { height: 48px; }
  .hdr__title { font-size: .86rem; letter-spacing: .035em; }
  .nav__toggle { padding: 8px 10px; }
}
@media (max-width: 360px) {
  .hdr__divider { display: none; }
  .hdr__title { font-size: .8rem; }
  .hdr__title > span { white-space: normal; }
}

/* страница результатов поиска */
.search-page { padding: 24px 0 56px; max-width: 900px; }
.search-page__summary { color: var(--muted); }
.search-hits { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.search-hit { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 22px; }
.search-hit time, .search-hit__kind { font-size: .82rem; color: var(--muted); }
.search-hit h2 { font-size: 1.1rem; margin: 4px 0 6px; }
.search-hit h2 a { text-decoration: none; }
.search-hit h2 a:hover { text-decoration: underline; }
.search-hit p { margin: 0; font-size: .94rem; color: var(--ink-2); }
.search-hit mark { background: #f6e7c1; color: inherit; padding: 0 1px; border-radius: 2px; }

/* ---------- кнопки ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 22px; border-radius: var(--radius-sm); border: 1px solid transparent;
  font: 600 .97rem/1.2 var(--sans); text-decoration: none; cursor: pointer; transition: background .15s, border-color .15s, color .15s;
}
.btn svg { width: 18px; height: 18px; flex: none; }
.btn--primary { background: var(--brand); color: #fff; }
.btn--primary:hover { background: var(--brand-hover); color: #fff; }
.btn--ghost { background: transparent; color: var(--ink); border-color: var(--line-strong); }
.btn--ghost:hover { border-color: var(--ink-2); color: var(--ink); }
.btn--light { background: #fff; color: var(--brand); }
.btn--light:hover { background: var(--brand-soft); color: var(--brand-hover); }
.btn--outline-light { background: transparent; color: #fff; border-color: rgba(255, 255, 255, .45); }
.btn--outline-light:hover { border-color: #fff; color: #fff; background: rgba(255, 255, 255, .06); }
.btn[disabled] { opacity: .6; cursor: progress; }

/* ---------- главная: первый экран ---------- */
.hero { background: linear-gradient(180deg, var(--graphite) 0%, #25272b 100%); color: #e9e6e0; position: relative; overflow: hidden; }
.hero .wrap { display: grid; grid-template-columns: 1.35fr 1fr; gap: 48px; align-items: center; padding-top: 52px; padding-bottom: 52px; position: relative; z-index: 1; }
.hero h1 { color: #fff; margin-bottom: 18px; }
.hero__lead { font-size: 1.1rem; color: #d6d2cb; max-width: 40em; margin-bottom: 0; }
.hero__actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 28px; }
/* декоративная эмблема справа: только линии, без текста */
.hero__art { display: flex; justify-content: center; align-items: center; color: rgba(255, 255, 255, .14); pointer-events: none; }
.hero__art svg { width: 100%; max-width: 240px; height: auto; display: block; }
.hero__art .accent { stroke: rgba(201, 169, 165, .35); }
@media (max-width: 900px) {
  .hero .wrap { grid-template-columns: 1fr; gap: 28px; padding-top: 40px; padding-bottom: 40px; }
  .hero__art { display: none; }
}

/* ---------- секции ---------- */
.section { padding: 56px 0; }
.section--white { background: var(--surface); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.section__head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; margin-bottom: 28px; flex-wrap: wrap; }
.section__head h2 { margin: 0; }
.section__head p { margin: 6px 0 0; color: var(--muted); }
/* главная: число материалов архива — только на компьютерах и планшетах; на смартфонах (в том числе в горизонтальном
   положении) строки нет, а под заголовком сразу ссылка «Полная лента новостей» */
@media (max-width: 640px), (max-height: 500px) and (orientation: landscape) { .news-total { display: none; } }
.link-arrow { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; text-decoration: none; }
.link-arrow svg { width: 16px; height: 16px; transition: transform .15s; }
.link-arrow:hover svg { transform: translateX(3px); }
@media (max-width: 640px) { .section { padding: 40px 0; } }

/* быстрые разделы */
.tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.tile {
  display: flex; gap: 16px; align-items: flex-start; padding: 22px; background: var(--surface);
  border: 1px solid var(--line); border-radius: var(--radius); text-decoration: none; color: var(--ink);
  transition: border-color .15s, box-shadow .15s, transform .15s;
}
.tile:hover { border-color: var(--line-strong); box-shadow: var(--shadow); color: var(--ink); transform: translateY(-1px); }
.tile__icon { width: 44px; height: 44px; border-radius: 10px; background: var(--brand-soft); color: var(--brand); display: grid; place-items: center; flex: none; }
.tile__icon svg { width: 22px; height: 22px; }
.tile h3 { font-size: 1.08rem; margin: 2px 0 4px; }
.tile p { margin: 0; color: var(--muted); font-size: .92rem; line-height: 1.5; }
.tile--accent { background: var(--brand); border-color: var(--brand); color: #fff; }
.tile--accent:hover { color: #fff; border-color: var(--brand-hover); background: var(--brand-hover); }
.tile--accent h3 { color: #fff; }
.tile--accent p { color: #ecd9d6; }
.tile--accent .tile__icon { background: rgba(255, 255, 255, .12); color: #fff; }
/* сетка из 6 долей: по 3 карточки в ряд; если в последнем ряду две — они делят ряд пополам, без пустой ячейки */
.tiles { grid-template-columns: repeat(6, 1fr); }
.tile { grid-column: span 2; }
.tile:nth-child(3n+1):nth-last-child(2), .tile:nth-child(3n+1):nth-last-child(2) + .tile { grid-column: span 3; }
.tile:nth-child(3n+1):last-child { grid-column: 1 / -1; }
@media (max-width: 900px) {
  .tiles { grid-template-columns: repeat(2, 1fr); }
  .tile, .tile:nth-child(3n+1):nth-last-child(2), .tile:nth-child(3n+1):nth-last-child(2) + .tile { grid-column: auto; }
  .tiles > .tile:nth-child(odd):last-child { grid-column: 1 / -1; }
}
@media (max-width: 560px) { .tiles { grid-template-columns: 1fr; } }

/* новости */
.news-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.news-card {
  display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 22px; text-decoration: none; color: var(--ink); transition: border-color .15s, box-shadow .15s;
}
.news-card:hover { border-color: var(--line-strong); box-shadow: var(--shadow); color: var(--ink); }
.news-card time { font-size: .82rem; color: var(--brand); font-weight: 600; letter-spacing: .02em; }
.news-card h3 { font-size: 1.08rem; margin: 8px 0 8px; line-height: 1.35; }
.news-card p { color: var(--muted); font-size: .92rem; margin: 0; line-height: 1.5; }
.news-card--lead { grid-row: span 2; background: var(--surface-2); }
.news-card--lead h3 { font-size: 1.35rem; }
@media (max-width: 900px) { .news-grid { grid-template-columns: 1fr 1fr; } .news-card--lead { grid-row: auto; grid-column: 1 / -1; } }
@media (max-width: 560px) { .news-grid { grid-template-columns: 1fr; } }

/* принципы */
.principles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--surface); }
.principle { padding: 28px; border-right: 1px solid var(--line); }
.principle:last-child { border-right: 0; }
.principle__num { font-family: var(--serif); color: var(--brand); font-size: 1.6rem; font-weight: 700; line-height: 1; margin-bottom: 14px; }
.principle h3 { font-size: 1.1rem; }
.principle p { color: var(--muted); margin: 0; font-size: .95rem; }
@media (max-width: 900px) { .principles { grid-template-columns: 1fr; } .principle { border-right: 0; border-bottom: 1px solid var(--line); } .principle:last-child { border-bottom: 0; } }

/* структура (округа) */
.districts { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.district {
  display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 16px 18px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-sm); text-decoration: none; color: var(--ink);
}
.district:hover { border-color: var(--brand); color: var(--brand); }
.district span { font-weight: 600; font-size: .95rem; line-height: 1.3; }
.district em { font-style: normal; font-size: .8rem; color: var(--muted); white-space: nowrap; }
@media (max-width: 1000px) { .districts { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .districts { grid-template-columns: 1fr; } }

/* полезные ссылки */
.links-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0 32px; margin: 0; padding: 0; list-style: none; }
.links-list li { border-bottom: 1px solid var(--line); }
.links-list a { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 14px 2px; text-decoration: none; color: var(--ink); font-weight: 500; }
.links-list a:hover { color: var(--brand); }
.links-list svg { width: 16px; height: 16px; color: var(--muted); flex: none; }
@media (max-width: 720px) { .links-list { grid-template-columns: 1fr; } }

/* контакты (полоса) */
.contact-band { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.contact-item { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.contact-item h3 { font-family: var(--sans); font-size: .78rem; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); font-weight: 600; margin-bottom: 8px; }
.contact-item p { margin: 0; font-weight: 500; }
.contact-item a { text-decoration: none; }
@media (max-width: 900px) { .contact-band { grid-template-columns: 1fr; } }

/* ---------- внутренние страницы ---------- */
.page-head { background: var(--surface); border-bottom: 1px solid var(--line); padding: 28px 0 30px; }
.page-head h1 { margin: 10px 0 0; }
.page-head p { margin: 10px 0 0; color: var(--muted); max-width: 52em; }
.crumbs { font-size: .86rem; color: var(--muted); }
.crumbs ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.crumbs li + li::before { content: "/"; margin-right: 6px; color: var(--line-strong); }
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--brand); text-decoration: underline; }

.layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 40px; padding: 40px 0 64px; }
.layout--single { grid-template-columns: minmax(0, 1fr); max-width: 860px; }
@media (max-width: 1000px) { .layout { grid-template-columns: 1fr; gap: 28px; padding: 28px 0 48px; } }

.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; }
@media (max-width: 560px) { .card { padding: 20px; } }

.prose { font-size: 1.02rem; color: var(--ink-2); overflow-wrap: anywhere; }
.prose h2 { margin-top: 1.4em; }
.prose h3, .prose h4 { margin-top: 1.3em; }
.prose ul, .prose ol { padding-left: 1.3em; margin: 0 0 1.1em; }
.prose li { margin-bottom: .35em; }
.prose table { border-collapse: collapse; width: 100%; margin: 1em 0; font-size: .95rem; display: block; overflow-x: auto; }
.prose td, .prose th { border: 1px solid var(--line); padding: 8px 10px; vertical-align: top; }
.prose blockquote { margin: 1em 0; padding: 4px 0 4px 18px; border-left: 3px solid var(--brand); color: var(--muted); }
.prose hr { border: 0; border-top: 1px solid var(--line); margin: 1.6em 0; }
.prose > :first-child { margin-top: 0; }

/* Типографика основного текста: только абзацы, пункты списков и цитаты внутри текстовых страниц */
.prose p, .prose li, .prose blockquote {
  line-height: 1.6;
  max-width: 75ch;                 /* не длиннее ~75 знаков в строке */
  text-align: left;                /* по левому краю: без растянутых пробелов */
  hyphens: none;                   /* слова не разрываются переносами */
  -webkit-hyphens: none;
  letter-spacing: normal;
  word-spacing: normal;
}
.prose p { margin: 0 0 1em; }
.prose li p { margin-bottom: .4em; }
/* обычные интервалы для всего текста статьи, включая вложенные элементы старых материалов */
.prose, .prose * { letter-spacing: normal; word-spacing: normal; text-justify: auto; }

/* Блок «Источник» внизу новости */
.news-source {
  margin: 1.8em 0 0 !important; padding-top: 14px; border-top: 1px solid var(--line);
  font-size: .92rem; color: var(--muted); max-width: none !important;
}
.news-source a { word-break: break-word; }
.news-source .news-source__credit { margin: 0 0 8px; color: var(--ink-2); max-width: none; }
.news-source .news-source__note { margin: 0 0 8px; max-width: none; }
.news-source dl { margin: 0; display: grid; grid-template-columns: max-content 1fr; gap: 4px 12px; }
.news-source dt { color: var(--muted); }
.news-source dd { margin: 0; color: var(--ink-2); }
@media (max-width: 560px) { .news-source dl { grid-template-columns: 1fr; gap: 0; } .news-source dd { margin-bottom: 6px; } }
.prose blockquote.quote { color: var(--ink-2); }
.prose blockquote.quote footer { margin-top: 6px; font-size: .9rem; color: var(--muted); }
/* в ячейках таблиц ширину строки не ограничиваем */
.prose td p, .prose th p { max-width: none; }

/* Короткая строка с двоеточием перед списком («Виды споров:») — небольшой полужирный подзаголовок */
.prose .list-head {
  font-family: var(--sans); font-size: 1rem; font-weight: 600; line-height: 1.4;
  color: var(--ink); letter-spacing: normal; margin: 1.5em 0 .6em;
}
.prose .list-head + ul, .prose .list-head + ol { margin-top: 0; }

.aside-nav { position: sticky; top: 100px; }
.aside-nav h2 { font-family: var(--sans); font-size: .78rem; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); margin-bottom: 10px; }
.aside-nav ul { list-style: none; margin: 0 0 24px; padding: 0; border-top: 1px solid var(--line); }
.aside-nav li { border-bottom: 1px solid var(--line); }
.aside-nav a { display: block; padding: 11px 4px; color: var(--ink-2); text-decoration: none; font-size: .95rem; }
.aside-nav a:hover, .aside-nav a[aria-current="page"] { color: var(--brand); }
.aside-nav a[aria-current="page"] { font-weight: 600; }
@media (max-width: 1000px) { .aside-nav { position: static; } }

/* список новостей */
.news-list { display: grid; gap: 0; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.news-row { display: grid; grid-template-columns: 150px 1fr; gap: 24px; padding: 20px 24px; border-bottom: 1px solid var(--line); text-decoration: none; color: var(--ink); }
.news-row:last-child { border-bottom: 0; }
.news-row:hover h2 { color: var(--brand); }
.news-row time { color: var(--brand); font-weight: 600; font-size: .9rem; padding-top: 2px; }
.news-row h2 { font-size: 1.12rem; margin: 0 0 6px; transition: color .15s; }
.news-row p { margin: 0; color: var(--muted); font-size: .94rem; }
@media (max-width: 640px) { .news-row { grid-template-columns: 1fr; gap: 6px; padding: 18px; } }

.pager { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 24px; align-items: center; }
.pager a, .pager span {
  min-width: 40px; height: 40px; padding: 0 12px; display: inline-grid; place-items: center; border-radius: var(--radius-sm);
  border: 1px solid var(--line); background: var(--surface); text-decoration: none; color: var(--ink-2); font-weight: 500;
}
.pager a:hover { border-color: var(--brand); color: var(--brand); }
.pager [aria-current="page"] { background: var(--brand); border-color: var(--brand); color: #fff; }
.pager .gap { border: 0; background: none; min-width: 20px; }

.article-meta { display: flex; gap: 16px; flex-wrap: wrap; color: var(--muted); font-size: .92rem; margin-top: 12px; }
.article-nav { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 24px; }
.article-nav a { display: block; padding: 16px 18px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); text-decoration: none; color: var(--ink); font-size: .95rem; }
.article-nav a:hover { border-color: var(--brand); }
.article-nav small { display: block; color: var(--muted); font-size: .8rem; margin-bottom: 4px; }
.article-nav .next { text-align: right; }
@media (max-width: 640px) { .article-nav { grid-template-columns: 1fr; } .article-nav .next { text-align: left; } }

/* структура: подробная страница */
.district-blocks { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.district-block { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; scroll-margin-top: 100px; }
.district-block h2 { font-size: 1.15rem; margin-bottom: 4px; }
.district-block .count { color: var(--muted); font-size: .88rem; margin-bottom: 14px; }
.district-block ul { columns: 2; column-gap: 24px; margin: 0; padding: 0; list-style: none; font-size: .94rem; color: var(--ink-2); }
.district-block li { break-inside: avoid; padding: 3px 0; }
.district-block:target { border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-soft); }
.subjects-aside { margin-top: 28px; padding: 14px 0 14px 18px; border-left: 3px solid var(--line-strong); scroll-margin-top: 100px; }
.subjects-aside h2 { font-family: var(--sans); font-size: .95rem; font-weight: 600; color: var(--ink-2); margin: 0 0 8px; }
.subjects-aside ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 4px 0; font-size: .93rem; color: var(--ink-2); }
.subjects-aside li:not(:last-child)::after { content: "·"; margin: 0 10px; color: var(--muted); }
@media (max-width: 560px) {
  .subjects-aside ul { display: block; }
  .subjects-aside li { padding: 2px 0; }
  .subjects-aside li:not(:last-child)::after { content: none; }
}
.structure-note { margin: 24px 0 0; color: var(--muted); font-size: .88rem; max-width: 60em; }
@media (max-width: 900px) { .district-blocks { grid-template-columns: 1fr; } }
@media (max-width: 480px) { .district-block ul { columns: 1; } }

/* информационные карточки и ссылки */
.doc-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.doc-list a {
  display: flex; gap: 14px; align-items: center; padding: 16px 18px; background: var(--surface);
  border: 1px solid var(--line); border-radius: var(--radius-sm); text-decoration: none; color: var(--ink); font-weight: 500;
}
.doc-list a:hover { border-color: var(--brand); color: var(--brand); }
.doc-list svg { width: 20px; height: 20px; color: var(--brand); flex: none; }
.doc-list .ext { margin-left: auto; color: var(--muted); font-size: .8rem; font-weight: 400; white-space: nowrap; }

/* уведомления */
.notice { display: flex; gap: 14px; padding: 16px 18px; border-radius: var(--radius-sm); border: 1px solid var(--line); background: var(--surface-2); font-size: .96rem; }
.notice svg { width: 22px; height: 22px; flex: none; margin-top: 1px; }
.notice p { margin: 0; }
.notice p + p { margin-top: 6px; }
.notice--info { background: #f3f4f6; border-color: #dfe1e5; }
.notice--info svg { color: var(--graphite-2); }
.notice--demo { background: var(--warn-soft); border-color: #ecd9ae; color: #5c3d00; }
.notice--demo svg { color: var(--warn); }
.notice--ok { background: var(--ok-soft); border-color: #c7dfcd; color: #1f4a2b; }
.notice--ok svg { color: var(--ok); }
.notice--err { background: var(--err-soft); border-color: #efc9c9; color: #6e1414; }
.notice--err svg { color: var(--err); }

/* ---------- «Состав суда» ---------- */
.search-grid { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 28px; align-items: start; padding: 36px 0 64px; }
@media (max-width: 1000px) { .search-grid { grid-template-columns: 1fr; padding: 24px 0 48px; } }

.form-card h2 { font-size: 1.3rem; margin-bottom: 6px; }
.form-card .hint { color: var(--muted); font-size: .93rem; margin-bottom: 22px; }
.fields { display: grid; grid-template-columns: 1fr 1fr; gap: 16px 18px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field--full { grid-column: 1 / -1; }
.field label { font-weight: 600; font-size: .9rem; color: var(--ink-2); }
.field label .opt { font-weight: 400; color: var(--muted); }
.field input {
  width: 100%; padding: 12px 14px; font: 1rem var(--sans); color: var(--ink); background: #fff;
  border: 1px solid var(--line-strong); border-radius: var(--radius-sm); transition: border-color .15s, box-shadow .15s;
}
.field input:hover { border-color: #b3ab9f; }
.field input:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px rgba(107, 30, 36, .14); }
.field input[aria-invalid="true"] { border-color: var(--err); box-shadow: 0 0 0 3px rgba(155, 28, 28, .1); }
.field .err { color: var(--err); font-size: .84rem; min-height: 0; }
.field .err:empty { display: none; }
@media (max-width: 560px) { .fields { grid-template-columns: 1fr; } }

.captcha { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.captcha__img { width: 176px; height: 60px; border: 1px solid var(--line-strong); border-radius: var(--radius-sm); background: #f2efe9; display: block; image-rendering: pixelated; }
.captcha__refresh { display: inline-flex; align-items: center; gap: 6px; background: none; border: 0; color: var(--brand); font: 500 .9rem var(--sans); cursor: pointer; padding: 8px 4px; }
.captcha__refresh svg { width: 16px; height: 16px; }
.captcha__input { max-width: 176px; letter-spacing: .2em; text-transform: uppercase; }

.form-actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 24px; padding-top: 22px; border-top: 1px solid var(--line); }
@media (max-width: 560px) { .form-actions .btn { flex: 1 1 100%; } }

.spinner { width: 18px; height: 18px; border: 2px solid rgba(255, 255, 255, .45); border-top-color: #fff; border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .spinner { animation-duration: 2s; } html { scroll-behavior: auto; } }

.result-wrap { display: grid; gap: 16px; }
.result-placeholder { text-align: center; padding: 48px 28px; color: var(--muted); border-style: dashed; }
.result-placeholder svg { width: 44px; height: 44px; color: var(--line-strong); margin-bottom: 10px; }
.result-placeholder h2 { font-size: 1.1rem; color: var(--ink-2); }
.result-placeholder p { margin: 0; font-size: .94rem; }
.result-loading { display: flex; align-items: center; gap: 14px; color: var(--ink-2); }
.result-loading .spinner { border-color: var(--line); border-top-color: var(--brand); width: 24px; height: 24px; }

.person { padding: 0; overflow: hidden; }
.person__ok { border-radius: 0; border-width: 0 0 1px; padding-left: 26px; padding-right: 26px; }
.person__head { display: flex; gap: 16px; align-items: center; padding: 22px 26px; border-bottom: 1px solid var(--line); background: var(--surface-2); }
.person__avatar { width: 52px; height: 52px; border-radius: 50%; background: var(--brand-soft); color: var(--brand); display: grid; place-items: center; font-family: var(--serif); font-weight: 700; font-size: 1.2rem; flex: none; }
.person__head h2 { font-size: 1.2rem; margin: 0; }
.person__head p { margin: 2px 0 0; color: var(--muted); font-size: .92rem; }
.person dl { margin: 0; display: grid; grid-template-columns: 200px 1fr; }
.person dt, .person dd { margin: 0; padding: 13px 26px; border-bottom: 1px solid var(--line); }
.person dt { color: var(--muted); font-size: .92rem; }
.person dd { font-weight: 500; }
.person dl > :nth-last-child(-n+2) { border-bottom: 0; }
.person__foot { padding: 14px 26px; font-size: .84rem; color: var(--muted); border-top: 1px solid var(--line); background: var(--surface-2); }
@media (max-width: 560px) {
  .person dl { grid-template-columns: 1fr; }
  .person dt { padding-bottom: 0; border-bottom: 0; }
  .person dd { padding-top: 2px; }
  .person__head, .person__foot { padding-left: 20px; padding-right: 20px; }
  .person dt, .person dd { padding-left: 20px; padding-right: 20px; }
}
.badge { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: 999px; font-size: .84rem; font-weight: 600; }
.badge--ok { background: var(--ok-soft); color: var(--ok); }
.badge--off { background: #eeeceb; color: var(--muted); }
.badge--review { background: var(--warn-soft); color: var(--warn); font-size: .76rem; padding: 2px 9px; }
.news-row .badge--review { margin-top: 8px; }

.official { margin-top: 0; }
.official h2 { font-size: 1.05rem; }
.official address { font-style: normal; font-weight: 600; color: var(--ink); margin-top: 6px; }

details.demo-hint { margin-top: 16px; font-size: .92rem; }
details.demo-hint summary { cursor: pointer; color: var(--warn); font-weight: 600; }
details.demo-hint table { border-collapse: collapse; margin-top: 10px; width: 100%; font-size: .86rem; }
details.demo-hint td, details.demo-hint th { border: 1px solid #ecd9ae; padding: 6px 8px; text-align: left; background: #fffaf0; }

/* контакты */
.contact-cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.contact-cards .card h2 { font-size: 1.1rem; }
.contact-cards dl { margin: 0; display: grid; gap: 10px; }
.contact-cards dt { font-size: .8rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.contact-cards dd { margin: 0 0 6px; font-weight: 500; }
.contact-cards--single { grid-template-columns: 1fr; }
.contact-cards--single dl { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 32px; }
@media (max-width: 900px) { .contact-cards { grid-template-columns: 1fr; } }
@media (max-width: 640px) { .contact-cards--single dl { grid-template-columns: 1fr; } }
.textarea { width: 100%; min-height: 140px; padding: 12px 14px; font: 1rem var(--sans); border: 1px solid var(--line-strong); border-radius: var(--radius-sm); resize: vertical; }
.textarea:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px rgba(107, 30, 36, .14); }

.consent { display: flex; gap: 10px; align-items: flex-start; font-weight: 400 !important; font-size: .92rem; color: var(--ink-2); cursor: pointer; }
.consent input { width: 18px; height: 18px; margin: 2px 0 0; flex: none; accent-color: var(--brand); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-note { align-self: center; color: var(--muted); font-size: .88rem; }
#q-result:not(:empty) { margin-top: 18px; }

/* карта сайта */
.sitemap ul { list-style: none; margin: 0; padding-left: 0; }
.sitemap > ul > li { padding: 12px 0; border-bottom: 1px solid var(--line); font-weight: 600; }
.sitemap ul ul { padding: 6px 0 0 20px; font-weight: 400; }
.sitemap ul ul li { padding: 4px 0; }

/* ---------- подвал ---------- */
.footer { background: var(--graphite); color: #c9c5bd; font-size: .93rem; margin-top: 0; }
.footer .wrap { padding-top: 48px; padding-bottom: 24px; }
.footer__grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.3fr; gap: 32px; }
.footer h2 { font-family: var(--sans); font-size: .76rem; text-transform: uppercase; letter-spacing: .12em; color: #8f8b84; margin-bottom: 14px; }
.footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.footer a { color: #e6e2db; text-decoration: none; }
.footer a:hover { color: #fff; text-decoration: underline; }
.footer .brand { color: #fff; margin-bottom: 14px; }
.footer .brand__name small { color: #9c978f; }
.footer p { margin: 0 0 8px; }
.footer__bottom { border-top: 1px solid #3d3f44; margin-top: 36px; padding-top: 20px; display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; font-size: .84rem; color: #8f8b84; }
@media (max-width: 1000px) { .footer__grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .footer__grid { grid-template-columns: 1fr; gap: 24px; } }

/* Удобные зоны нажатия на сенсорных экранах (внешний вид не меняется) */
@media (pointer: coarse), (max-width: 760px) {
  .crumbs a { display: inline-block; padding: 7px 0; }
  .link-arrow { padding: 7px 0; }
  .contact-item a, .contact-cards dd a { display: inline-block; padding: 6px 0; }
  .sitemap a { display: inline-block; padding: 6px 0; }
  details.demo-hint summary { padding: 6px 0; }
  .consent { padding: 4px 0; }
  .consent input { width: 22px; height: 22px; }
}

.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Служебные отступы вместо встроенных style="..." (CSP без 'unsafe-inline', L-7) */
.u-mt32 { margin-top: 32px; }
.u-mt8 { margin-top: 8px; }
.u-stack16 { display: grid; gap: 16px; }
.u-pad-32-64 { padding-top: 32px; padding-bottom: 64px; }
.u-pad-err { padding: 40px 16px 64px; }
