/* Каталог штампов для вырубки pro-color.ru (ТЗ-32, 32Б): хаб, категории, карточки. Подключается после tech.css (hero, шаги, FAQ, таблица, лайтбокс). */

/* ---------- первый экран ---------- */
/* ссылки внутри текста — с подчёркиванием (контраст ссылки с окружающим текстом, Lighthouse) */
.tk-muted a, .st-cat-links a, .st-alt-note a, .st-collage figcaption a, .st-die figcaption a { text-decoration: underline; text-underline-offset: 2px; }
.st-hero-side { display: flex; flex-direction: column; gap: 14px; }
.st-hero-side .tk-stat span a { text-decoration: underline; text-underline-offset: 2px; }
.st-anchor { scroll-margin-top: calc(var(--pc-sticky-top, 90px) + 8px); }
.st-hero-side > img { width: 100%; height: auto; border-radius: var(--pc-radius-lg); box-shadow: var(--pc-shadow); background: #F4EFE6; }
.st-hero-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
.st-hero-actions .btn .bi, .st-actions .btn .bi { margin-right: 4px; }
.st-cat-links { margin: 14px 0 0; font-size: 15px; color: var(--pc-text-light); }
.st-code { display: inline-block; font-weight: 700; font-size: 12.5px; letter-spacing: .04em; padding: 2px 8px; border-radius: 99px; background: var(--pc-dark); color: #fff; font-variant-numeric: tabular-nums; }

/* ---------- подбор по размеру ---------- */
.st-search-sec { scroll-margin-top: calc(var(--pc-sticky-top, 90px) + 8px); }
.st-search-box { border: 1px solid var(--pc-border); border-radius: var(--pc-radius-lg); padding: 24px; background: #fff; box-shadow: var(--pc-shadow-sm); }
.st-search-head h2 { font-size: 24px; margin: 0 0 6px; }
.st-search-head p { margin: 0 0 16px; color: var(--pc-text-light); font-size: 15px; }
.st-search { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 16px 24px; }
.st-search-dims { display: flex; align-items: flex-end; gap: 8px; }
.st-search label > span, .st-tol legend, .st-sort > span { display: block; font-size: 13px; color: var(--pc-text-light); margin-bottom: 4px; font-weight: 400; float: none; padding: 0; }
.st-search label small { color: var(--pc-text-light); }
.st-search input[type=number] { width: 104px; height: 44px; padding: 8px 12px; border: 1px solid #CFD5DC; border-radius: var(--pc-radius); font-size: 17px; font-variant-numeric: tabular-nums; }
.st-search input[type=number]:focus, .st-search select:focus, .st-sort select:focus { border-color: var(--pc-cyan); outline: 2px solid rgba(0, 160, 227, .25); outline-offset: 0; }
.st-x { font-size: 20px; color: #9AA3AE; padding-bottom: 9px; }
.st-search-opts { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 16px; }
.st-search select, .st-sort select { height: 44px; padding: 8px 34px 8px 12px; border: 1px solid #CFD5DC; border-radius: var(--pc-radius); font-size: 15px; background: #fff; max-width: 280px; }
.st-tol { border: 0; margin: 0; padding: 0; min-width: 0; }
.st-tol label { display: inline-block; margin: 0; }
.st-tol input { position: absolute; opacity: 0; pointer-events: none; }
.st-tol label span { display: inline-flex; align-items: center; height: 44px; padding: 0 12px; border: 1px solid #CFD5DC; margin-left: -1px; font-size: 15px; color: var(--pc-dark); cursor: pointer; background: #fff; }
.st-tol label:first-of-type span { border-radius: var(--pc-radius) 0 0 var(--pc-radius); margin-left: 0; }
.st-tol label:last-of-type span { border-radius: 0 var(--pc-radius) var(--pc-radius) 0; }
.st-tol input:checked + span { background: var(--pc-dark); border-color: var(--pc-dark); color: #fff; position: relative; }
.st-tol input:focus-visible + span { outline: 2px solid var(--pc-cta); outline-offset: 1px; }
.st-search .btn { height: 44px; }
.st-results { margin-top: 20px; border-top: 1px solid var(--pc-border); padding-top: 16px; }
.st-res-head { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; margin-bottom: 12px; font-size: 15px; color: var(--pc-text-light); }
.st-res-head b { color: var(--pc-dark); }
.st-res { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.st-res a { display: grid; grid-template-columns: 72px 1fr; gap: 10px; align-items: center; padding: 8px; border: 1px solid var(--pc-border); border-radius: var(--pc-radius); color: var(--pc-dark); background: #fff; height: 100%; }
.st-res a:hover { border-color: var(--pc-cyan); box-shadow: var(--pc-shadow); }
.st-res img { width: 72px; height: 54px; object-fit: contain; background: #F7F5F0; border-radius: 4px; }
.st-res img.is-svg { background: #fff; padding: 3px; }
.st-res b { display: block; font-size: 14px; line-height: 1.25; }
.st-res small { display: flex; flex-wrap: wrap; gap: 4px 6px; align-items: center; margin-top: 4px; font-size: 12.5px; color: #555; }
.st-res .st-code { margin-bottom: 2px; }
.st-res a > span { display: flex; flex-direction: column; align-items: flex-start; }
.st-match { display: inline-block; padding: 1px 7px; border-radius: 99px; font-size: 11.5px; font-weight: 700; }
.st-match--exact { background: #E3F5EA; color: #1B7A43; }
.st-match--close { background: #FFF1E6; color: #B24A0B; }
.st-match--far { background: #EEF1F4; color: #4F4F4E; }
.st-res-note { margin: 12px 0 0; font-size: 14px; color: var(--pc-text-light); }

/* ---------- категории на хабе ---------- */
.st-cats { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 16px; }
.st-cat { display: flex; flex-direction: column; height: 100%; background: #fff; border: 1px solid var(--pc-border); border-radius: var(--pc-radius-lg); overflow: hidden; color: var(--pc-dark); transition: box-shadow .2s, transform .2s; }
.st-cat:hover { box-shadow: var(--pc-shadow-lg); transform: translateY(-2px); color: var(--pc-dark); }
.st-cat-img { aspect-ratio: 4 / 3; background: #F4EFE6; }
.st-cat-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.st-cat-body { display: flex; flex-direction: column; gap: 4px; padding: 14px 16px 16px; flex: 1 1 auto; }
.st-cat-body > b { font-size: 17px; line-height: 1.25; }
.st-cat-n { font-size: 14px; color: var(--pc-text-light); }
.st-cat-minis { display: flex; gap: 6px; margin-top: 8px; }
.st-cat-minis img { width: 48px; height: 36px; object-fit: contain; border-radius: 4px; background: #F7F5F0; }

/* ---------- обозначения линий ---------- */
.st-line path { stroke-width: 3; fill: none; stroke-linecap: butt; }
.st-line--cut path, .st-op--cut path { stroke: #E30613; }
.st-line--crease path, .st-op--crease path { stroke: #1F9D55; stroke-dasharray: 6 4; }
.st-line--perf path, .st-op--perf path { stroke: #8032A0; stroke-dasharray: 2 3; }
.st-legend { list-style: none; margin: 12px 0; padding: 0; display: grid; gap: 10px; }
.st-legend li { display: grid; grid-template-columns: 52px auto 1fr; gap: 10px; align-items: baseline; font-size: 15px; }
.st-legend li b { color: var(--pc-dark); }
.st-legend li span { color: var(--pc-text-light); font-size: 14px; }
.st-legend--compact { display: flex; flex-wrap: wrap; gap: 8px 22px; }
.st-legend--compact li { grid-template-columns: 52px auto; }
.st-leg-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 40px; align-items: center; }
.st-leg-row { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 16px 48px; align-items: center; }
.st-leg-row h2 { margin-bottom: 4px; }
.st-leg-row p { margin: 0; }
.st-collage { margin: 0; }
.st-collage img { width: 100%; height: auto; border-radius: var(--pc-radius-lg); border: 1px solid var(--pc-border); background: #fff; }
.st-collage figcaption { margin-top: 8px; font-size: 13.5px; color: var(--pc-text-light); text-align: center; }
.st-steps { grid-template-columns: repeat(3, minmax(0, 1fr)); }

/* ---------- нет подходящего ---------- */
.st-alt { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.st-alt-card { display: flex; flex-direction: column; gap: 6px; padding: 20px; border: 1px solid var(--pc-border); border-radius: var(--pc-radius-lg); color: var(--pc-dark); background: #fff; transition: border-color .2s, box-shadow .2s; }
.st-alt-card:hover { border-color: var(--pc-cta); box-shadow: var(--pc-shadow); color: var(--pc-dark); }
.st-alt-card .bi { font-size: 26px; color: var(--pc-cta); }
.st-alt-card b { font-size: 16.5px; }
.st-alt-card span { font-size: 14.5px; color: var(--pc-text-light); line-height: 1.45; }
.st-alt-note { margin: 16px 0 0; }

/* ---------- сетка карточек ---------- */
.st-list-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 10px 20px; margin-bottom: 16px; }
.st-list-head h2 { font-size: 24px; margin: 0; }
.st-sort { display: flex; align-items: center; gap: 8px; margin: 0; }
.st-sort > span { margin: 0; }
.st-filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 18px; }
.st-filters button { display: inline-flex; align-items: center; gap: 6px; height: 38px; padding: 0 14px; border-radius: 99px; border: 1px solid #CFD5DC; background: #fff; color: var(--pc-dark); font-size: 14.5px; font-weight: 600; cursor: pointer; }
.st-filters button span { font-weight: 400; color: var(--pc-text-light); font-size: 13px; }
.st-filters button:hover { border-color: var(--pc-dark); }
.st-filters button[aria-pressed="true"] { background: var(--pc-dark); border-color: var(--pc-dark); color: #fff; }
.st-filters button[aria-pressed="true"] span { color: rgba(255, 255, 255, .7); }
.st-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.st-grid--paged > .st-card:nth-child(n+25) { display: none; }
.st-grid--paged.is-js > .st-card { display: none; }
.st-grid--paged.is-js > .st-card.is-on { display: block; }
.st-card a { display: flex; flex-direction: column; height: 100%; background: #fff; border: 1px solid var(--pc-border); border-radius: var(--pc-radius-lg); overflow: hidden; color: var(--pc-dark); transition: box-shadow .2s, border-color .2s; }
.st-card a:hover { box-shadow: var(--pc-shadow-lg); border-color: #C9D2DB; color: var(--pc-dark); }
.st-card-img { display: block; aspect-ratio: 4 / 3; background: #F7F5F0; }
.st-card-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.st-card-img.is-svg { background: #fff; padding: 14px; border-bottom: 1px solid #EEF1F4; }
.st-card-img.is-svg img { object-fit: contain; }
.st-card-body { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; padding: 12px 14px 14px; flex: 1 1 auto; }
.st-card-title { font-size: 15.5px; line-height: 1.3; }
.st-card-meta { display: flex; flex-wrap: wrap; gap: 2px 10px; font-size: 13.5px; color: #555; margin-top: auto; }
.st-more-wrap { text-align: center; margin-top: 24px; }
.st-empty { padding: 24px; text-align: center; color: var(--pc-text-light); }

/* ---------- карточка штампа ---------- */
.st-card-hero { padding: 24px 0 48px; background: linear-gradient(180deg, #F7F9FB 0, #fff 100%); }
.st-card-grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 40px; align-items: start; margin-top: 12px; }
.st-col { display: flex; flex-direction: column; gap: 28px; min-width: 0; }
.st-dl h2 { margin-bottom: 12px; }
.st-nw { white-space: nowrap; }
.st-ph h2 { margin-bottom: 12px; }
.st-viz { margin: 0; }
.st-viz a { display: block; border-radius: var(--pc-radius-lg); overflow: hidden; background: #F4EFE6; cursor: zoom-in; }
.st-viz img { width: 100%; height: auto; display: block; }
.st-viz figcaption { margin-top: 8px; font-size: 13.5px; color: var(--pc-text-light); display: flex; gap: 8px; align-items: baseline; }
.st-badge { display: inline-block; flex: 0 0 auto; padding: 1px 8px; border-radius: 99px; font-size: 12px; font-weight: 700; background: #FFF1E6; color: #B24A0B; }
.st-card-info h1 { font-size: clamp(26px, 3vw, 36px); line-height: 1.15; margin: 6px 0 14px; }
.st-have { display: flex; gap: 10px; align-items: center; padding: 12px 14px; border-radius: var(--pc-radius); background: #E9F7EF; color: #17603A; font-size: 15.5px; margin: 0 0 16px; }
.st-have .bi { font-size: 22px; }
.st-have b { color: #17603A; }
.st-facts { margin-bottom: 18px; }
.st-facts th { width: 44%; font-weight: 400 !important; color: var(--pc-text-light) !important; }
.st-facts td { font-weight: 600; color: var(--pc-dark); }
.st-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.st-actions .btn-lg { width: 100%; }
.st-actions .btn small { font-weight: 400; opacity: .75; margin-left: 4px; }
.st-share.is-copied span::after { content: " — ссылка скопирована"; }

.st-dl-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 40px; align-items: start; }
.st-dl-list { list-style: none; margin: 0 0 12px; padding: 0; display: grid; gap: 8px; }
.st-dl-list a { display: grid; grid-template-columns: 28px 1fr auto; gap: 10px; align-items: center; padding: 12px 14px; border: 1px solid var(--pc-border); border-radius: var(--pc-radius); color: var(--pc-dark); font-weight: 600; background: #fff; }
.st-dl-list a:hover { border-color: var(--pc-cta); color: var(--pc-dark); }
.st-dl-list .bi { font-size: 22px; color: var(--pc-cta); }
.st-dl-list small { color: var(--pc-text-light); font-weight: 400; }
.st-howto { margin: 16px 0 8px; padding: 14px 16px 14px 34px; background: #F7F9FB; border-radius: var(--pc-radius); font-size: 14.5px; color: var(--pc-text); }
.st-howto li { margin: 2px 0; }
.st-leg-box { padding: 20px; border: 1px solid var(--pc-border); border-radius: var(--pc-radius-lg); }
.st-leg-box h3 { font-size: 18px; margin: 0; }

/* развёртка */
.st-die { margin: 0; border: 1px solid var(--pc-border); border-radius: var(--pc-radius-lg); background: #fff; padding: 14px; }
.st-die-bar { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; margin-bottom: 10px; }
.st-die-ops, .st-die-views, .st-seg { display: flex; flex-wrap: wrap; gap: 6px; }
.st-die-bar button { display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 12px; border-radius: 99px; border: 1px solid #CFD5DC; background: #fff; font-size: 13.5px; font-weight: 600; color: var(--pc-dark); cursor: pointer; }
.st-die-bar button:hover { border-color: var(--pc-dark); }
.st-op[aria-pressed="false"] { opacity: .45; text-decoration: line-through; }
.st-op path { stroke-width: 3; fill: none; }
.st-seg button[aria-pressed="true"] { background: var(--pc-dark); color: #fff; border-color: var(--pc-dark); }
.st-die-stage { position: relative; padding: 22px 0 0 26px; }
.st-die-stage[hidden] { display: none; }
.st-dim { position: absolute; font-size: 12px; color: #555; font-variant-numeric: tabular-nums; white-space: nowrap; }
.st-dim--w { top: 0; left: 26px; right: 0; text-align: center; border-bottom: 1px solid #B8C0C9; line-height: 18px; }
.st-dim--w::before, .st-dim--w::after { content: ""; position: absolute; bottom: -4px; width: 1px; height: 8px; background: #B8C0C9; }
.st-dim--w::before { left: 0; } .st-dim--w::after { right: 0; }
.st-dim--h { left: 0; top: 22px; bottom: 0; width: 18px; border-right: 1px solid #B8C0C9; writing-mode: vertical-rl; transform: rotate(180deg); text-align: center; }
.st-die-svg { width: 100%; max-height: 640px; display: flex; justify-content: center; background-color: #fff; background-image: linear-gradient(#F1F4F7 1px, transparent 1px), linear-gradient(90deg, #F1F4F7 1px, transparent 1px); background-size: 20px 20px; }
.st-die-svg svg { width: 100%; height: 100%; max-height: 640px; display: block; overflow: visible; }
.st-die-svg path { stroke-width: 1.6px; transition: stroke-width .15s, opacity .15s; }
.st-die-svg path.crease { stroke-dasharray: 7 4; }
.st-die-svg path.perf { stroke-dasharray: 2 3; }
.st-die-svg svg:hover path { opacity: .35; }
.st-die-svg svg:hover path:hover { opacity: 1; stroke-width: 3.5px; }
.st-die.no-cut path.cut, .st-die.no-crease path.crease, .st-die.no-perf path.perf, .st-zoom.no-cut path.cut, .st-zoom.no-crease path.crease, .st-zoom.no-perf path.perf { display: none; }
.st-die figcaption { margin-top: 10px; font-size: 13.5px; color: var(--pc-text-light); }

/* увеличение развёртки */
.st-zoom { position: fixed; inset: 0; z-index: 2000; background: rgba(10, 22, 40, .94); display: flex; flex-direction: column; }
.st-zoom[hidden] { display: none; }
.st-zoom-top { display: flex; align-items: center; gap: 8px; padding: 10px 14px; color: #fff; }
.st-zoom-top b { margin-right: auto; font-size: 15px; }
.st-zoom-top button { width: 44px; height: 44px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .14); color: #fff; font-size: 20px; cursor: pointer; }
.st-zoom-top button:hover { background: rgba(255, 255, 255, .25); }
.st-zoom-pane { flex: 1 1 auto; overflow: auto; padding: 16px; cursor: grab; touch-action: pan-x pan-y; }
.st-zoom-pane.is-drag { cursor: grabbing; }
.st-zoom-pane svg { display: block; margin: 0 auto; background: #fff; border-radius: 6px; max-width: none; height: auto; }
.st-zoom-pane path { stroke-width: 1.6px; }
.st-zoom-pane path.crease { stroke-dasharray: 7 4; }
.st-zoom-pane path.perf { stroke-dasharray: 2 3; }

/* фото, описание */
.st-photos { display: flex; flex-wrap: wrap; gap: 14px; }
.st-photos figure { margin: 0; }
.st-photos a { display: block; border-radius: var(--pc-radius); overflow: hidden; border: 1px solid var(--pc-border); cursor: zoom-in; background: #F7F5F0; }
.st-photos img { display: block; height: 220px; width: auto; max-width: 100%; object-fit: cover; }
.st-photos figure:only-child img, .st-photos figure:first-child:nth-last-child(2) img, .st-photos figure:first-child:nth-last-child(2) ~ figure img { height: 340px; }
.st-photos figcaption { font-size: 13px; color: var(--pc-text-light); margin-top: 6px; }
.st-about { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 40px; }
.st-desc { font-size: 17px; line-height: 1.6; margin: 0; max-width: 760px; }
.st-grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.st-grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }

/* ---------- блок «Готовые штампы» на страницах каталога и «Услуг» (StPromo) ---------- */
.st-search-box--embed { box-shadow: none; padding: 18px 20px; margin-bottom: 24px; background: #fff; }
.st-search-box--embed .st-search-head h3 { font-size: 18px; margin: 0 0 4px; }
.st-search-box--embed .st-search-head p { margin-bottom: 12px; font-size: 14.5px; }
.st-promo-more { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; margin: 24px 0 0; }
.st-promo-more .btn .bi { margin-left: 4px; }
.st-promo-all { font-size: 15px; text-decoration: underline; text-underline-offset: 2px; }
.st-code-input { font-weight: 700; letter-spacing: .04em; background: #F3F6F9 !important; }

/* ---------- адаптив ---------- */
@media (max-width: 1199.98px) {
  .st-grid, .st-grid--4 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 991.98px) {
  .st-dl-grid, .st-about, .st-leg-grid { grid-template-columns: minmax(0, 1fr); gap: 24px; }
  .st-card-grid { display: flex; flex-direction: column; gap: 24px; }
  .st-col { display: contents; }
  .st-o1 { order: 1; } .st-o2 { order: 2; } .st-o3 { order: 3; } .st-o4 { order: 4; } .st-o5 { order: 5; }
  .st-grid, .st-grid--4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .st-alt, .st-steps { grid-template-columns: minmax(0, 1fr); }
  .st-leg-row { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 575.98px) {
  .st-hero-side .tk-stats--3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .st-hero-side .tk-stats--3 .tk-stat:last-child { grid-column: 1 / -1; }
  .st-promo-more .btn { width: 100%; }
  .st-search-box { padding: 16px; }
  .st-search-dims { width: 100%; }
  .st-search-dims label { flex: 1 1 0; min-width: 0; }
  .st-search input[type=number] { width: 100%; }
  .st-search-opts, .st-search-opts .st-sel, .st-search select { width: 100%; max-width: none; }
  .st-search .btn { width: 100%; }
  .st-tol label span { padding: 0 10px; }
  .st-grid, .st-grid--4 { gap: 10px; }
  .st-card-body { padding: 10px; }
  .st-card-title { font-size: 14px; }
  .st-card-meta { font-size: 12.5px; }
  .st-photos img, .st-photos figure:only-child img, .st-photos figure:first-child:nth-last-child(2) img, .st-photos figure:first-child:nth-last-child(2) ~ figure img { height: 200px; }
  .st-actions .btn { width: 100%; }
  .st-cats { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .st-cat-body > b { font-size: 15px; }
  .st-cat-minis { display: none; }
  .st-die { padding: 10px; }
  .st-legend li { grid-template-columns: 52px minmax(0, 1fr); }
  .st-legend li span { grid-column: 1 / -1; }
}
@media (prefers-reduced-motion: reduce) { .st-cat, .st-cat:hover { transition: none; transform: none; } }
