/* category.css - deltas for CategoryPage. Loaded after site.css.
 *
 * .cp-head           - hero with crumbs + h1 + lede + meta + trust
 * .cp-main           - 2-col grid: filters+table | sidebar manager+docs
 * .cp-filters        - filters cluster (chips + selects + toggles)
 * .cp-table          - sortament table with sortable headers
 * .cp-spec-bar       - sticky bottom bar with current spec total
 * .cp-mgr / .cp-dl   - sidebar manager card and download links
 * .cp-detail / .cp-faq / .cp-related - bottom blocks
 */

@import url('./site.css?v=9');

/* ========== HEAD ========================================================== */
.cp-head { padding: 28px 0 24px; background: var(--bg-soft); border-bottom: 1px solid var(--border-1); }
/* ===== TrustStrip на категории — вертикальный список (иконка+текст, gap+центр) ===== */
.trust-strip { display: flex; flex-direction: column; gap: 10px; }
.trust-strip__item { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; color: var(--fg-1); }
.trust-strip__item svg { color: var(--c-accent); flex: 0 0 16px; }
.cp-head h1 { font-size: 40px; font-weight: 600; letter-spacing: -0.015em; line-height: 1.1; margin: 14px 0 12px; max-width: 28ch; }
.cp-head__lede { font-size: 16px; color: var(--fg-2); line-height: 1.55; max-width: 72ch; margin: 0; }
.cp-head__crumbs { font-size: 13px; color: var(--fg-3); display: flex; gap: 6px; align-items: center; flex-wrap: wrap; margin: 0; }
.cp-head__crumbs a { color: var(--fg-3); text-decoration: none; }
.cp-head__crumbs a:hover { color: var(--fg-1); }
.cp-head__crumbs .sep { color: var(--c-steel-300, #c5cdd6); }
.cp-head__crumbs .cur { color: var(--fg-1); }
.cp-head__meta { display: flex; gap: 24px; flex-wrap: wrap; margin-top: 16px; font-size: 13px; color: var(--fg-3); }
.cp-head__meta .t-num { color: var(--fg-1); font-weight: 500; }

/* ========== MAIN GRID ===================================================== */
.cp-main { padding: 36px 0 48px; background: #fff; }
.cp-main__grid { display: grid; grid-template-columns: 1fr 320px; gap: 36px; align-items: start; }
.cp-main__sidebar { display: flex; flex-direction: column; gap: 16px; position: sticky; top: 90px; }

@media (max-width: 1080px) {
  .cp-main__grid { grid-template-columns: 1fr; }
  .cp-main__sidebar { position: static; }
}

/* ========== FILTERS ======================================================= */
.cp-filters {
  background: #fff;
  border: 1px solid var(--border-1);
  border-radius: var(--r-3, 8px);
  padding: 22px 24px;
  display: grid;
  gap: 18px;
  margin-bottom: 20px;
}
.cp-filter__lbl {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--fg-3);
  font-weight: 600;
  margin-bottom: 8px;
}
.cp-filter--inline { display: flex; gap: 12px; align-items: center; }
.cp-filter--inline .cp-filter__lbl { margin-bottom: 0; min-width: 100px; }
.cp-filter__chips { display: flex; gap: 6px; flex-wrap: wrap; }
.cp-chip {
  padding: 6px 12px;
  background: var(--bg-soft);
  border: 1px solid var(--border-1);
  border-radius: 16px;
  font-size: 13px;
  font-family: var(--font-sans);
  color: var(--fg-1);
  cursor: pointer;
  transition: all 0.12s ease;
}
.cp-chip:hover { border-color: var(--c-accent); color: var(--c-accent); }
.cp-chip.is-on { background: var(--c-accent); border-color: var(--c-accent); color: #fff; }
.cp-filter__more { border: 0; background: none; cursor: pointer; font: inherit; font-size: 12.5px; font-weight: 600; color: var(--c-accent); padding: 0 6px; white-space: nowrap; align-self: center; }
.cp-filter__more:hover { text-decoration: underline; }
.cp-select {
  padding: 8px 12px;
  border: 1px solid var(--border-1);
  border-radius: var(--r-2, 6px);
  font-size: 14px;
  background: #fff;
  color: var(--fg-1);
  min-width: 180px;
}
.cp-toggle {
  display: inline-flex; align-items: center; gap: 8px;
  cursor: pointer;
  font-size: 14px;
}
.cp-toggle input { display: none; }
.cp-toggle__box {
  width: 18px; height: 18px;
  border: 1.5px solid var(--border-1);
  border-radius: 4px;
  position: relative;
  flex-shrink: 0;
  transition: all 0.12s ease;
}
.cp-toggle input:checked + .cp-toggle__box {
  background: var(--c-accent);
  border-color: var(--c-accent);
}
.cp-toggle input:checked + .cp-toggle__box::after {
  content: ""; position: absolute; left: 5px; top: 1px;
  width: 5px; height: 10px;
  border: solid #fff; border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}
.cp-toggle__lbl { color: var(--fg-1); }

/* ========== TABLE ========================================================= */
.cp-table {
  background: #fff;
  border: 1px solid var(--border-1);
  border-radius: var(--r-3);
  overflow: hidden;
}
.cp-table .tbl { margin: 0; }
.cp-table .tbl th.is-sortable:hover { color: var(--c-accent); }
.cp-add {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 6px 10px;
  background: transparent;
  border: 1px solid var(--border-1);
  border-radius: var(--r-2, 6px);
  font-size: 12px;
  font-family: var(--font-sans);
  color: var(--fg-1);
  cursor: pointer;
  transition: all 0.12s ease;
}
.cp-add:hover { border-color: var(--c-accent); color: var(--c-accent); }
.cp-add.is-added { background: var(--c-accent); border-color: var(--c-accent); color: #fff; }

/* ========== SPEC BAR ===================================================== */
.cp-spec-bar {
  position: sticky; bottom: 16px;
  margin-top: 20px;
  padding: 16px 22px;
  background: var(--c-graphite, #1F2937);
  color: #fff;
  border-radius: var(--r-3);
  display: flex; justify-content: space-between; align-items: center;
  gap: 16px;
  box-shadow: 0 8px 24px -10px rgba(0,0,0,0.3);
  z-index: 50;
}
.cp-spec-bar__lbl { font-size: 11px; text-transform: uppercase; letter-spacing: 0.06em; color: rgba(255,255,255,0.6); font-weight: 600; }
.cp-spec-bar__sub { font-size: 14px; color: #fff; margin-top: 2px; }

/* ========== SIDEBAR (manager + docs) ====================================== */
.cp-mgr {
  background: #fff;
  border: 1px solid var(--border-1);
  border-radius: var(--r-3);
  padding: 20px;
}
.cp-mgr__row { display: flex; gap: 12px; align-items: center; margin-bottom: 12px; }
.cp-mgr__av {
  width: 48px; height: 48px;
  border-radius: 50%;
  background: repeating-linear-gradient(45deg, #F4F6F9 0 6px, #EDF0F4 6px 12px);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-mono);
  font-size: 9px;
  color: var(--c-steel-500, #8d99a8);
}
.cp-mgr__av { overflow: hidden; }
.cp-mgr__photo { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; display: block; }
.cp-mgr__name { font-size: 14px; font-weight: 600; color: var(--fg-1); }
.cp-mgr__role { font-size: 12px; color: var(--fg-3); }
.cp-mgr__promise {
  padding: 8px 12px;
  background: var(--c-success-soft, #e6f5ec);
  color: var(--c-success, #1f8a5b);
  border-radius: var(--r-2);
  font-size: 12px;
  font-weight: 500;
  text-align: center;
  margin-bottom: 12px;
}
.cp-mgr__btns { display: flex; flex-direction: column; gap: 8px; }
.cp-mgr__btns .btn { width: 100%; justify-content: center; }

.cp-dl {
  background: #fff;
  border: 1px solid var(--border-1);
  border-radius: var(--r-3);
  padding: 18px 20px;
  display: flex; flex-direction: column; gap: 4px;
}
.cp-dl__t {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--fg-3);
  font-weight: 600;
  margin-bottom: 8px;
}
.cp-dl a {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 0;
  font-size: 13px;
  color: var(--fg-1);
  text-decoration: none;
  border-bottom: 1px solid var(--border-1);
}
.cp-dl a:last-child { border-bottom: 0; }
.cp-dl a:hover { color: var(--c-accent); }
.cp-dl a svg { color: var(--fg-3); flex-shrink: 0; }

/* ========== DETAIL / FAQ / RELATED ======================================== */
.cp-detail { padding: 48px 0 32px; background: var(--bg-soft); border-top: 1px solid var(--border-1); }
.cp-detail h2 { font-size: 26px; font-weight: 600; margin: 0 0 20px; letter-spacing: -0.01em; }
.cp-detail h3 { font-size: 18px; font-weight: 600; margin: 24px 0 10px; }
.cp-detail p { font-size: 15px; line-height: 1.65; color: var(--fg-2); margin: 0 0 14px; max-width: 80ch; }
.cp-detail strong { color: var(--fg-1); }

.cp-faq { padding: 32px 0 48px; background: #fff; }
.cp-faq h2 { font-size: 26px; font-weight: 600; margin: 0 0 24px; letter-spacing: -0.01em; }

.cp-related { padding: 32px 0 48px; background: var(--bg-soft); border-top: 1px solid var(--border-1); }
.cp-related h2 { font-size: 26px; font-weight: 600; margin: 0 0 24px; letter-spacing: -0.01em; }
.cp-related__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.cp-related__grid h3 { font-size: 12px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--fg-3); font-weight: 600; margin: 0 0 12px; }
.cp-related__grid ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 2px; }
.cp-related__grid li a {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: var(--r-2, 6px);
  text-decoration: none;
  color: var(--fg-1);
  font-size: 14px;
  transition: background 0.12s ease;
}
.cp-related__grid li a:hover { background: #fff; }
.cp-related__grid li .url { font-family: var(--font-mono); font-size: 11px; color: var(--fg-3); margin-top: 2px; }
.cp-related__grid li svg { color: var(--fg-3); }

@media (max-width: 1000px) { .cp-related__grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px)  { .cp-related__grid { grid-template-columns: 1fr; } }

/* ===== MOBILE ADAPT (Claude Design, 2026-05-25) — допис. в конец, каскад после всех правил ===== */
/* ============================================================================
   MOBILE ADAPT · Category page (CategoryPage.jsx → .cp-*)
   ----------------------------------------------------------------------------
   Подключается ПОСЛЕ category.css. Десктоп (>900px) НЕ трогаем.
   Брейкпоинты:
     ≤ 900px  — планшет: head + filters компактнее, таблица — горизонтальный
                скролл с залипающей первой колонкой, сайдбар уже под таблицей
                (это берёт на себя 1080-брейк из category.css).
     ≤ 600px  — телефон: фильтры в столбик, таблица → СТЕК КАРТОЧЕК через
                data-label (см. CategoryPage.jsx: каждый <td> получает
                data-label={col.label} и data-col-key={col.key};
                action-td помечен .cp-add-cell). Spec-bar на всю ширину,
                сайдбар = тач-френдли стек.
   Тач-таргеты: chip ≥ 36px, select/кнопка ≥ 44px на телефоне.
   Работает одинаково для armatura (7 колонок), dvutavr и list-gk (10 колонок).
   ============================================================================ */

/* ============================================================================
   TABLET · 600–900px
   ============================================================================ */
@media (max-width: 900px) {

  /* --- HEAD ----------------------------------------------------------- */
  .cp-head { padding: 22px 0 20px; }
  .cp-head h1 {
    font-size: 30px;
    line-height: 1.12;
    margin: 12px 0 10px;
    max-width: none;
  }
  .cp-head__lede { font-size: 15px; line-height: 1.55; }
  .cp-head__crumbs { font-size: 12px; gap: 5px; }
  .cp-head__meta {
    gap: 14px;
    row-gap: 6px;
    margin-top: 14px;
    font-size: 12.5px;
  }

  /* --- MAIN GRID (уже 1 колонка <1080) -------------------------------- */
  .cp-main { padding: 28px 0 40px; }
  .cp-main__grid { gap: 24px; }
  /* min-width: 0 на левом столбце сетки — иначе таблица с min-width 720px
     раздвигает grid-track шире вьюпорта и .tbl-wrap не скроллится: страница
     уезжает в горизонтальный скролл вместо таблицы. */
  .cp-main__grid > div { min-width: 0; }
  /* Сайдбар уже не sticky (правило в category.css). На планшете —
     manager + docs в один ряд, чтобы не съедать вертикальное пространство. */
  .cp-main__sidebar { flex-direction: row; flex-wrap: wrap; gap: 12px; }
  .cp-main__sidebar > * { flex: 1 1 320px; min-width: 0; }

  /* --- FILTERS -------------------------------------------------------- */
  .cp-filters { padding: 18px 16px; gap: 14px; margin-bottom: 16px; }
  .cp-filter__lbl { font-size: 10.5px; }
  .cp-filter--inline { gap: 10px; align-items: center; }
  .cp-filter--inline .cp-filter__lbl { min-width: 88px; margin-bottom: 0; }
  .cp-select {
    min-width: 0;
    flex: 1;
    min-height: 40px;
    font-size: 14px;
  }
  .cp-filter__chips { gap: 5px; }
  .cp-chip {
    padding: 7px 12px;
    font-size: 12.5px;
    min-height: 32px;
    display: inline-flex;
    align-items: center;
  }
  .cp-toggle { min-height: 40px; }

  /* --- TABLE: горизонт-скролл + sticky первая колонка ----------------- */
  .cp-table { border-radius: var(--r-3); overflow: hidden; }
  .cp-table .tbl-wrap {
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
  }
  .cp-table .tbl {
    min-width: 720px;
    font-size: 13px;
    border-collapse: separate;
    border-spacing: 0;
  }
  .cp-table .tbl th,
  .cp-table .tbl td { padding: 11px 12px; }

  .cp-table .tbl thead th:first-child,
  .cp-table .tbl tbody td:first-child {
    position: sticky;
    left: 0;
    z-index: 2;
    background: #fff;
    box-shadow: 1px 0 0 var(--border-1);
  }
  .cp-table .tbl thead th:first-child {
    background: var(--bg-soft);
    z-index: 3;
  }
  .cp-table .tbl tbody tr:hover td:first-child { background: var(--bg-soft); }

  .cp-add {
    padding: 6px 10px;
    font-size: 12px;
    min-height: 36px;
    white-space: nowrap;
  }

  /* --- SPEC BAR ------------------------------------------------------- */
  .cp-spec-bar { padding: 14px 18px; gap: 12px; bottom: 12px; }
  .cp-spec-bar__sub { font-size: 13px; }
  .cp-spec-bar .btn { min-height: 40px; font-size: 13px; padding: 0 14px; }

  /* --- SIDEBAR -------------------------------------------------------- */
  .cp-mgr, .cp-dl { padding: 18px; }
  .cp-mgr__btns .btn { min-height: 44px; }

  /* --- DETAIL / FAQ / RELATED ---------------------------------------- */
  .cp-detail { padding: 36px 0 24px; }
  .cp-detail h2 { font-size: 22px; }
  .cp-detail h3 { font-size: 16px; margin: 20px 0 8px; }
  .cp-detail p { font-size: 14.5px; line-height: 1.6; }

  .cp-faq { padding: 24px 0 36px; }
  .cp-faq h2 { font-size: 22px; margin-bottom: 18px; }

  .cp-related { padding: 28px 0 36px; }
  .cp-related h2 { font-size: 22px; margin-bottom: 18px; }
  .cp-related__grid { gap: 20px; }
}


/* ============================================================================
   PHONE · ≤ 600px
   ============================================================================ */
@media (max-width: 600px) {

  /* Глобальный gutter уменьшаем (даже если mobile-adapt.css не подгружен) */
  :root { --gutter: 16px; }

  /* Тач-таргеты по умолчанию для кнопок внутри страницы */
  .cp-main .btn { min-height: 44px; }
  .cp-main .btn--sm { min-height: 40px; }

  /* --- HEAD ----------------------------------------------------------- */
  .cp-head { padding: 18px 0; }
  .cp-head h1 {
    font-size: 26px;
    line-height: 1.15;
    margin: 10px 0 10px;
    letter-spacing: -0.01em;
  }
  .cp-head__lede { font-size: 14px; line-height: 1.55; }
  .cp-head__crumbs { font-size: 11.5px; gap: 4px; }
  .cp-head__crumbs .sep { font-size: 10px; }
  .cp-head__meta {
    flex-direction: column;
    gap: 6px;
    margin-top: 12px;
    padding: 12px 0 0;
    font-size: 12px;
    border-top: 1px solid var(--border-1);
  }

  /* --- MAIN ----------------------------------------------------------- */
  .cp-main { padding: 22px 0 32px; }
  .cp-main__grid { gap: 18px; }
  .cp-main__sidebar { flex-direction: column; gap: 10px; }
  .cp-main__sidebar > * { flex: none; }

  /* --- FILTERS: компактно --------------------------------------------- */
  .cp-filters {
    padding: 14px;
    gap: 14px;
    margin-bottom: 14px;
    border-radius: var(--r-2);
  }
  .cp-filter__lbl { font-size: 10.5px; margin-bottom: 6px; }

  /* multi → чипы переносятся, тач ≥ 36px */
  .cp-filter__chips { gap: 6px; }
  .cp-chip {
    padding: 8px 12px;
    font-size: 13px;
    min-height: 36px;
    border-radius: 18px;
    display: inline-flex;
    align-items: center;
  }

  /* single → лейбл сверху, select 100% × 44px */
  .cp-filter--inline {
    flex-direction: column;
    align-items: stretch;
    gap: 6px;
  }
  .cp-filter--inline .cp-filter__lbl {
    min-width: 0;
    margin-bottom: 0;
  }
  .cp-select {
    width: 100%;
    min-width: 0;
    height: 44px;
    font-size: 14px;
    padding: 0 12px;
  }

  /* toggle: tap-area 44 */
  .cp-toggle { min-height: 44px; gap: 10px; font-size: 14px; }
  .cp-toggle__box { width: 20px; height: 20px; }


  /* --- TABLE → СТЕК КАРТОЧЕК ------------------------------------------ */
  .cp-table {
    background: transparent;
    border: 0;
    border-radius: 0;
    overflow: visible;
  }
  .cp-table .tbl-wrap {
    overflow: visible;
    border: 0;
    border-radius: 0;
  }
  .cp-table .tbl {
    display: block;
    width: 100%;
    min-width: 0;
    border: 0;
    border-collapse: separate;
    border-spacing: 0;
    background: transparent;
  }
  .cp-table .tbl thead { display: none; }
  .cp-table .tbl tbody { display: block; }

  /* Карточка-строка */
  .cp-table .tbl tr {
    display: block;
    position: relative;
    background: #fff;
    border: 1px solid var(--border-1);
    border-radius: var(--r-3);
    padding: 14px 16px 12px;
    margin-bottom: 10px;
    box-shadow: 0 1px 2px rgba(15, 23, 32, 0.03);
  }
  .cp-table .tbl tr:last-child { margin-bottom: 0; }

  /* Обычная ячейка: label слева, value справа, одной строкой.
     Пустые/служебные td с colspan (empty-state) исключаем. */
  .cp-table .tbl td:not([colspan]) {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 12px;
    padding: 7px 0;
    border: 0;
    border-bottom: 1px dashed var(--border-1);
    font-size: 13.5px;
    color: var(--fg-1);
    text-align: left;
    white-space: normal;
    vertical-align: baseline;
  }
  .cp-table .tbl td:not([colspan])::before {
    content: attr(data-label);
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--fg-3);
    font-weight: 500;
    font-family: var(--font-sans);
    flex: 0 0 auto;
    line-height: 1.3;
  }
  /* Числовые/моно — на значении */
  .cp-table .tbl td.t-num,
  .cp-table .tbl td.num { font-family: var(--font-mono); }
  .cp-table .tbl td.t-num::before,
  .cp-table .tbl td.num::before { font-family: var(--font-sans); }

  /* Первая колонка — крупный «заголовок» карточки (без лейбла).
     В armatura это «⌀12», в list-gk «4×1500×6000», и т.п. */
  .cp-table .tbl td:first-child:not([colspan]) {
    display: block;
    font-size: 19px;
    font-weight: 600;
    line-height: 1.2;
    color: var(--fg-1);
    padding: 0 116px 12px 0;     /* room для stock-бейджа справа сверху */
    margin-bottom: 6px;
    border-bottom: 1px solid var(--border-1);
    font-family: var(--font-mono);
    letter-spacing: -0.005em;
  }
  .cp-table .tbl td:first-child:not([colspan])::before { display: none; }
  .cp-table .tbl td:first-child:not([colspan]) a {
    color: var(--c-accent);
    text-decoration: none;
    font-weight: 600;
  }

  /* Бейдж наличия — абсолют в правом-верхнем углу карточки */
  .cp-table .tbl td[data-col-key="stockTxt"] {
    position: absolute;
    top: 14px;
    right: 16px;
    padding: 0;
    margin: 0;
    border: 0;
    display: block;
    max-width: 112px;
    text-align: right;
  }
  .cp-table .tbl td[data-col-key="stockTxt"]::before { display: none; }
  .cp-table .tbl td[data-col-key="stockTxt"] .badge {
    font-size: 10.5px;
    line-height: 1.25;
    white-space: normal;
    display: inline-block;
    max-width: 100%;
  }

  /* Цена ₽/т — крупнее, моно, отделена линией; всегда последняя пара
     перед action-кнопкой в обеих категориях (armatura и list-gk). */
  .cp-table .tbl td[data-col-key="pricePerT"] {
    padding: 10px 0 4px;
    margin-top: 4px;
    border-top: 1px solid var(--border-1);
    border-bottom: 0;
    font-family: var(--font-mono);
    font-size: 18px;
    font-weight: 600;
    color: var(--fg-1);
    align-items: baseline;
  }
  .cp-table .tbl td[data-col-key="pricePerT"]::before {
    content: "Цена, ₽/т";
    color: var(--fg-3);
    font-size: 11px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-family: var(--font-sans);
  }

  /* Action-cell: кнопка «В спецификацию» на всю ширину карточки */
  .cp-table .tbl td.cp-add-cell {
    display: block;
    padding: 12px 0 0;
    margin-top: 4px;
    border-top: 1px solid var(--border-1);
    border-bottom: 0;
  }
  .cp-table .tbl td.cp-add-cell::before { display: none; }
  .cp-table .tbl td.cp-add-cell .cp-add {
    width: 100%;
    justify-content: center;
    min-height: 44px;
    font-size: 14px;
    padding: 0 14px;
    background: transparent;
    color: var(--c-accent);
    border: 1px solid var(--c-accent);
    border-radius: var(--r-2);
  }
  .cp-table .tbl td.cp-add-cell .cp-add.is-added {
    background: var(--c-accent);
    border-color: var(--c-accent);
    color: #fff;
  }

  /* Пустое состояние (rows.length === 0) — одной плашкой */
  .cp-table .tbl td[colspan] {
    display: block;
    padding: 22px 16px !important;
    text-align: center;
    font-size: 13px;
    color: var(--fg-3);
    border: 0;
  }


  /* --- SPEC BAR (sticky bottom) --------------------------------------- */
  .cp-spec-bar {
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
    padding: 14px 16px;
    bottom: 84px;          /* над глобальной StickyCTA */
    border-radius: var(--r-3);
    box-shadow: 0 12px 28px -10px rgba(0, 0, 0, 0.35);
  }
  .cp-spec-bar__lbl { font-size: 10.5px; }
  .cp-spec-bar__sub { font-size: 13px; line-height: 1.4; }
  /* Кнопочный div (inline-style display:flex) — растягиваем на всю ширину
     и делим пополам. Перекрываем inline-style через !important. */
  .cp-spec-bar > div:last-child {
    display: flex !important;
    width: 100%;
    gap: 8px;
  }
  .cp-spec-bar > div:last-child .btn {
    flex: 1;
    min-height: 44px;
    font-size: 13.5px;
    padding: 0 12px;
  }


  /* --- SIDEBAR: manager + docs --------------------------------------- */
  .cp-mgr {
    padding: 16px;
    border-radius: var(--r-2);
  }
  .cp-mgr__row { gap: 12px; margin-bottom: 12px; }
  .cp-mgr__av { width: 44px; height: 44px; font-size: 9px; }
  .cp-mgr__name { font-size: 14px; }
  .cp-mgr__role { font-size: 12px; }
  .cp-mgr__promise { font-size: 12px; padding: 9px 12px; margin-bottom: 12px; }
  .cp-mgr__btns { gap: 8px; }
  .cp-mgr__btns .btn { min-height: 44px; font-size: 14px; width: 100%; }

  .cp-dl { padding: 16px; border-radius: var(--r-2); }
  .cp-dl__t { font-size: 10.5px; margin-bottom: 4px; }
  .cp-dl a {
    padding: 12px 0;
    font-size: 13.5px;
    min-height: 44px;
    gap: 12px;
  }
  .cp-dl a svg { flex: 0 0 16px; }


  /* --- DETAIL --------------------------------------------------------- */
  .cp-detail { padding: 28px 0 22px; }
  .cp-detail h2 { font-size: 20px; margin-bottom: 14px; }
  .cp-detail h3 { font-size: 16px; margin: 20px 0 8px; }
  .cp-detail p { font-size: 14px; line-height: 1.62; margin-bottom: 12px; }


  /* --- FAQ ------------------------------------------------------------ */
  .cp-faq { padding: 22px 0 30px; }
  .cp-faq h2 { font-size: 20px; margin-bottom: 14px; }
  .cp-faq .acc-head {
    font-size: 14px;
    padding: 14px 16px;
    min-height: 52px;
    line-height: 1.35;
  }
  .cp-faq .acc-body {
    padding: 0 16px 14px;
    font-size: 13.5px;
    line-height: 1.55;
  }


  /* --- RELATED ------------------------------------------------------- */
  .cp-related { padding: 26px 0 32px; }
  .cp-related h2 { font-size: 20px; margin-bottom: 16px; }
  /* .cp-related__grid: уже 1 колонка <560 в category.css */
  .cp-related__grid { gap: 20px; }
  .cp-related__grid h3 { font-size: 11px; margin-bottom: 8px; }
  .cp-related__grid li a {
    padding: 11px 12px;
    font-size: 13.5px;
    min-height: 48px;
    gap: 8px;
  }
  .cp-related__grid li .url { font-size: 10.5px; }
}

/* ========== SERVER FILTERS & PAGINATION (spec_catalog_pagination) ========== */
/* Чипы/тоггл теперь <a>-ссылки (фильтр считает сервер): вид тот же, без подчёркивания. */
a.cp-chip { text-decoration: none; display: inline-block; }
a.cp-toggle { text-decoration: none; }
.cp-toggle.is-on .cp-toggle__box { background: var(--c-accent); border-color: var(--c-accent); }
.cp-toggle.is-on .cp-toggle__box::after {
  content: ""; position: absolute; left: 5px; top: 1px;
  width: 5px; height: 10px;
  border: solid #fff; border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}
.cp-found { font-size: 13px; color: var(--fg-3); margin-left: 14px; }
.cp-table .tbl th.is-sortable a { color: inherit; text-decoration: none; }
.cp-sort-arrow { margin-left: 4px; color: var(--c-accent); }
.cp-chip.is-hidden { display: none; }

/* ========== PAGINATION (server-side) ====================================== */
/* Блок из Claude Design (pagination-preview.html, 05.07): перенос CSS 1:1. */
.cp-pager {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 20px;
  font-family: var(--font-sans);
}
/* Назад / Вперёд */
.cp-pager__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 40px;
  padding: 0 16px;
  background: var(--bg-soft);
  border: 1px solid var(--border-1);
  border-radius: var(--r-2, 6px);
  color: var(--fg-1);
  font-size: 14px;
  font-weight: 500;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
  transition: border-color 0.12s ease, color 0.12s ease, background-color 0.12s ease;
}
.cp-pager__btn:hover { border-color: var(--c-accent); color: var(--c-accent); }
.cp-pager__btn[rel="prev"]::before { content: "\2039"; font-size: 18px; line-height: 0; margin-top: -1px; }
.cp-pager__btn[rel="next"]::after { content: "\203A"; font-size: 18px; line-height: 0; margin-top: -1px; }
/* окно с номерами */
.cp-pager__nums { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; justify-content: center; }
/* номер-ссылка и текущий делят базовую геометрию */
.cp-pager__num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  min-height: 40px;
  padding: 0 6px;
  border: 1px solid var(--border-1);
  border-radius: var(--r-2, 6px);
  background: var(--bg-soft);
  color: var(--fg-1);
  font-size: 14px;
  font-weight: 500;
  font-family: var(--font-mono);
  line-height: 1;
  text-decoration: none;
  transition: border-color 0.12s ease, color 0.12s ease, background-color 0.12s ease;
}
a.cp-pager__num:hover { border-color: var(--c-accent); color: var(--c-accent); }
.cp-pager__num.is-current {
  background: var(--c-accent);
  border-color: var(--c-accent);
  color: #fff;
  font-weight: 600;
  cursor: default;
}
/* многоточие-разрыв */
.cp-pager__gap {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 24px;
  min-height: 40px;
  color: var(--fg-3);
  font-family: var(--font-mono);
  font-size: 14px;
  user-select: none;
}
@media (max-width: 768px) {
  .cp-pager { gap: 6px; justify-content: space-between; }
  .cp-pager__nums { gap: 3px; flex: 1; }
  .cp-pager__num { min-width: 36px; padding: 0 3px; font-size: 13px; }
  .cp-pager__gap { min-width: 16px; }
  .cp-pager__btn { padding: 0 12px; font-size: 13px; }
}
