/* Rockhockey · карусель «Наши работы». Всё под .wks и .wk, остальной сайт не затрагивает.
   Тема: переменные --wk-* на .wk (или на :root). Шрифт по умолчанию наследуется от сайта. */
.wks, .wk {
  --wk-bg: #fff; --wk-ink: #16181d; --wk-muted: #868b95; --wk-line: #e4e6ea; --wk-ph: #e9ebee;
  --wk-btn: rgba(255,255,255,.92); --wk-shadow: rgba(14,20,34,.42);
  --wk-font: inherit; --wk-radius: 40px;
  --wk-w: clamp(280px, 40vw, 560px); --wk-r: 1; --wk-h: calc(var(--wk-w) * var(--wk-r)); --wk-gap: clamp(14px, 2.4vw, 30px);
}
.wks { background: var(--wk-bg); color: var(--wk-ink); font-family: var(--wk-font); position: relative; overflow: hidden;
  padding-block: clamp(36px, 6vw, 84px); -webkit-font-smoothing: antialiased; }
.wks *, .wks *::before, .wks *::after, .wk *, .wk *::before, .wk *::after { box-sizing: border-box; }
.wks h2, .wks h3, .wks p, .wks figure, .wk h3, .wk p, .wk figure { margin: 0; }
.wk { position: relative; color: var(--wk-ink); }
.wk[hidden] { display: none; }
/* второй ряд: фото джерси на столе, вертикальные карточки той же высоты */
.wk--product { --wk-w: clamp(250px, 32vw, 448px); --wk-r: 1.25; }

.wk-title { text-align: center; font-size: clamp(26px, 3.4vw, 40px); font-weight: 600; letter-spacing: .02em;
  text-transform: uppercase; padding-inline: 16px; margin-bottom: clamp(18px, 3vw, 30px); text-wrap: balance; }
.wk-tabs { display: flex; width: max-content; max-width: calc(100% - 32px); margin: 0 auto clamp(6px, 1.5vw, 14px); padding: 5px; gap: 4px;
  border-radius: 999px; background: var(--wk-line); }
.wk-tabs button { appearance: none; border: 0; background: none; color: var(--wk-muted); font: inherit; font-size: 13px; font-weight: 600;
  letter-spacing: .06em; text-transform: uppercase; padding: 12px 22px; border-radius: 999px; cursor: pointer; white-space: nowrap;
  transition: background .25s, color .25s; }
.wk-tabs button[aria-selected="true"] { background: var(--wk-ink); color: var(--wk-bg); }
.wk-tabs button:focus-visible { outline: 2px solid var(--wk-ink); outline-offset: 2px; }
.wk.is-swap { animation: wk-swap .5s cubic-bezier(.2, .8, .2, 1); }
@keyframes wk-swap { from { opacity: 0; transform: translateY(14px); } }

.wk-stage { position: relative; }
.wk-track { position: relative; display: flex; gap: var(--wk-gap); overflow-x: auto; overflow-y: hidden;
  padding: 26px calc(50% - var(--wk-w) / 2) 10px; scroll-snap-type: x mandatory; overscroll-behavior-x: contain;
  scrollbar-width: none; -webkit-overflow-scrolling: touch; outline: none; }
.wk-track::-webkit-scrollbar { display: none; }
.wk-row { display: contents; }
.wk.is-drag .wk-track { scroll-snap-type: none; }

.wk-slide { flex: 0 0 var(--wk-w); width: var(--wk-w); scroll-snap-align: center; scroll-snap-stop: always; cursor: pointer; }
.wk-slide.is-active { cursor: zoom-in; }
.wk.is-drag .wk-slide { cursor: grabbing; }
.wk-slide:focus { outline: none; }

.wk-card { position: relative; height: var(--wk-h); border-radius: var(--wk-radius); overflow: hidden; background: var(--wk-ph);
  transform: perspective(1400px) rotateY(calc(var(--dc, 0) * -9deg)) scale(calc(1 - var(--a, 0) * .15));
  opacity: calc(1 - var(--a, 0) * .38);
  box-shadow: 0 calc(34px - var(--a, 0) * 18px) 64px -30px var(--wk-shadow);
  will-change: transform, opacity; transition: box-shadow .3s; }
.wk-card img { position: absolute; inset: 0; width: 100%; height: 100%; max-width: none; object-fit: cover; display: block;
  transform: scale(1.14) translateX(calc(var(--dc, 0) * -5%)); user-select: none; -webkit-user-drag: none; pointer-events: none; }

.wk-slide figcaption { margin-top: 22px; padding-inline: 6px; opacity: var(--co, 1);
  transform: translateY(calc(var(--a, 0) * 12px)); pointer-events: none; }
.wk-slide h3 { font-size: 15px; font-weight: 700; letter-spacing: .03em; text-transform: uppercase; line-height: 1.35; }
.wk-slide p { margin-top: 8px; font-size: 14.5px; line-height: 1.65; color: var(--wk-muted); }

/* кнопка под каруселью */
.wk-cta-row { display: flex; justify-content: center; margin-top: clamp(22px, 3vw, 34px); padding-inline: 16px; }
.wk-cta { display: inline-block; background: var(--wk-ink); color: var(--wk-bg); text-decoration: none; font-weight: 600; font-size: 14.5px;
  padding: 16px 28px; border-radius: 999px; transition: transform .15s; text-align: center; }
.wk-cta:hover { transform: translateY(-2px); }
.wk-cta:focus-visible { outline: 2px solid var(--wk-ink); outline-offset: 3px; }

/* стрелки */
.wk-btn { position: absolute; top: calc(26px + var(--wk-h) / 2); width: 58px; height: 58px; margin-top: -29px; border-radius: 50%; border: 0;
  background: var(--wk-btn); color: var(--wk-ink); display: grid; place-items: center; cursor: pointer; z-index: 5; padding: 0;
  box-shadow: 0 12px 32px -10px var(--wk-shadow); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
  transition: transform .2s, opacity .2s; }
.wk-btn:hover { transform: scale(1.08); }
.wk-btn:active { transform: scale(.95); }
.wk-btn[disabled] { opacity: 0; pointer-events: none; }
.wk-btn:focus-visible { outline: 2px solid var(--wk-ink); outline-offset: 3px; }
.wk-btn svg { width: 22px; height: 22px; }
.wk-prev { left: calc(50% - var(--wk-w) / 2 - 29px); }
.wk-next { right: calc(50% - var(--wk-w) / 2 - 29px); }

/* курсор «тяни» (только мышь) */
.wk-cursor { position: absolute; left: 0; top: 0; z-index: 6; width: 96px; height: 96px; margin: -48px 0 0 -48px; border-radius: 50%;
  background: var(--wk-ink); color: var(--wk-bg); display: none; place-items: center; pointer-events: none; opacity: 0;
  font-size: 12px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase;
  transform: translate3d(var(--cx, 0px), var(--cy, 0px), 0) scale(var(--cs, .4)); transition: opacity .2s, scale .2s; }
.wk-cursor span { display: flex; align-items: center; gap: 8px; }
.wk-cursor svg { width: 11px; height: 11px; }
.wk.has-cursor .wk-cursor { display: grid; }
.wk.has-cursor .wk-track, .wk.has-cursor .wk-slide { cursor: none; }
.wk.has-cursor.is-hover .wk-cursor { opacity: 1; --cs: 1; }
.wk.has-cursor.is-drag .wk-cursor { --cs: .82; }
.wk.has-cursor.on-btn .wk-cursor { opacity: 0; --cs: .4; }

/* подсказка на карточке */
.wk-hint { position: absolute; left: 50%; top: calc(26px + var(--wk-h) - 58px); transform: translateX(-50%); z-index: 4; pointer-events: none;
  display: flex; align-items: center; gap: 10px; padding: 11px 18px; border-radius: 999px; background: var(--wk-btn);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); color: var(--wk-ink);
  font-size: 12px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; white-space: nowrap;
  box-shadow: 0 10px 28px -10px var(--wk-shadow); transition: opacity .4s, transform .4s; }
.wk-hint svg { width: 14px; height: 14px; }
.wk-hint svg:first-child { animation: wk-l 1.5s ease-in-out infinite; }
.wk-hint svg:last-child { animation: wk-r 1.5s ease-in-out infinite; }
@keyframes wk-l { 50% { transform: translateX(-5px); } }
@keyframes wk-r { 50% { transform: translateX(5px); } }
.wk.is-touched .wk-hint { opacity: 0; transform: translate(-50%, 10px); }

/* низ: прогресс и счётчик */
.wk-foot { display: flex; align-items: center; gap: 20px; width: min(var(--wk-w), calc(100% - 32px)); margin: 26px auto 0; }
.wk-bar { position: relative; flex: 1; height: 3px; border-radius: 3px; background: var(--wk-line); overflow: hidden; }
.wk-bar i { position: absolute; left: 0; top: 0; bottom: 0; width: calc(100% / var(--n, 1)); border-radius: 3px; background: var(--wk-ink);
  transform: translateX(calc(var(--pa, 0) * 100%)); }
.wk-bar i:nth-child(1) { --pa: var(--p1, 0); }
.wk-bar i:nth-child(2) { --pa: var(--p2, -9); }
.wk-count { font-variant-numeric: tabular-nums; font-size: 14px; font-weight: 600; letter-spacing: .06em; white-space: nowrap; }
.wk-count span { color: var(--wk-muted); font-weight: 500; }

/* вход: покачивание подсказывает, что влево и вправо есть ещё */
.wk.is-in .wk-card { animation: wk-in .9s cubic-bezier(.2, .8, .2, 1) backwards; animation-delay: calc(var(--ad, 0) * .08s); }
@keyframes wk-in { from { opacity: 0; translate: calc(var(--dc, 0) * 80px) 34px; } }
.wk.is-in:not(.is-touched) .wk-track { animation: wk-nudge 1.7s cubic-bezier(.45, 0, .2, 1) .9s 1; }
@keyframes wk-nudge { 0%, 100% { transform: none; } 38% { transform: translateX(-70px); } 70% { transform: translateX(12px); } }

@media (max-width: 760px) {
  .wks, .wk { --wk-w: min(78vw, 420px); --wk-gap: 12px; --wk-radius: 30px; }
  .wk--product { --wk-w: min(64vw, 340px); }
  .wk-tabs button { padding: 11px 16px; font-size: 12px; }
  .wk-btn { display: none; }
  .wk-hint { top: calc(26px + var(--wk-h) - 54px); font-size: 11px; padding: 10px 16px; }
  .wk-slide p { font-size: 14px; }
}
@media (prefers-reduced-motion: reduce) {
  .wk.is-in .wk-card, .wk.is-in:not(.is-touched) .wk-track, .wk-hint svg, .wk.is-swap { animation: none; }
  .wk-card, .wk-slide figcaption { transition: none; }
}

/* ---------- просмотр на весь экран (вне .wk, поэтому свои значения) */
html.wkl-lock { overflow: hidden; }
.wkl { --wkl-o: 1; position: fixed; inset: 0; z-index: 2147483000; display: flex; flex-direction: column; align-items: center; justify-content: center;
  background: rgba(9, 11, 16, calc(.94 * var(--wkl-o))); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  color: #fff; font-family: Montserrat, system-ui, sans-serif; opacity: 0; transition: opacity .22s ease; touch-action: none; -webkit-font-smoothing: antialiased; }
.wkl[hidden] { display: none; }
.wkl, .wkl * { box-sizing: border-box; }
.wkl.is-in { opacity: 1; } .wkl.is-out { opacity: 0; }
.wkl-stage { position: relative; flex: 1 1 auto; width: 100%; min-height: 0; overflow: hidden; cursor: grab; user-select: none; -webkit-user-select: none; }
.wkl.is-drag .wkl-stage { cursor: grabbing; }
.wkl-p { position: absolute; inset: 0; margin: 0; display: flex; align-items: center; justify-content: center; padding: 64px 16px 8px; will-change: transform; }
.wkl-p img { max-width: min(94vw, 1100px); max-height: 100%; width: auto; height: auto; object-fit: contain; border-radius: 22px; box-shadow: 0 30px 80px rgba(0,0,0,.5); background: #1b1e26; pointer-events: none; }
.wkl.is-in .wkl-p:nth-child(2) img { animation: wkl-pop .38s cubic-bezier(.2,.8,.2,1); }
@keyframes wkl-pop { from { transform: scale(.92); } to { transform: none; } }
.wkl-x, .wkl-a { position: absolute; display: grid; place-items: center; width: 48px; height: 48px; border: 0; border-radius: 50%; padding: 0; cursor: pointer;
  background: rgba(255,255,255,.12); color: #fff; transition: background .2s, transform .2s; -webkit-tap-highlight-color: transparent; }
.wkl-x:hover, .wkl-a:hover { background: rgba(255,255,255,.24); } .wkl-x:active, .wkl-a:active { transform: scale(.94); }
.wkl-x:focus-visible, .wkl-a:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }
.wkl-x { top: max(14px, env(safe-area-inset-top, 0px)); right: max(14px, env(safe-area-inset-right, 0px)); z-index: 2; }
.wkl-a { top: 50%; margin-top: -24px; z-index: 2; }
.wkl-l { left: max(18px, env(safe-area-inset-left, 0px)); } .wkl-r { right: max(18px, env(safe-area-inset-right, 0px)); }
.wkl.is-single .wkl-a { display: none; }
.wkl-cap { flex: 0 0 auto; width: 100%; max-width: 620px; padding: 14px 20px calc(30px + env(safe-area-inset-bottom, 0px)); text-align: center; }
.wkl-cap h3 { margin: 0; font-size: 14px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; }
.wkl-cap p { display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; margin: 6px 0 0; font-size: 14px; line-height: 1.6; color: rgba(255,255,255,.62); }
.wkl-n { position: absolute; top: max(26px, calc(env(safe-area-inset-top, 0px) + 12px)); left: max(20px, env(safe-area-inset-left, 0px)); z-index: 2; font-size: 13px; font-weight: 600; letter-spacing: .12em; color: rgba(255,255,255,.7); font-variant-numeric: tabular-nums; }
@media (max-width: 760px), (hover: none) { .wkl-a { display: none; } .wkl-p { padding: 60px 10px 4px; } .wkl-p img { max-width: 96vw; border-radius: 18px; } }
@media (prefers-reduced-motion: reduce) { .wkl, .wkl-x, .wkl-a { transition: none; } .wkl.is-in .wkl-p:nth-child(2) img { animation: none; } }

/* ---------- правка при интеграции на print.rockhockey.ru (2026-10-20), первое из двух отличий от пакета.
   Подписи в рядах разной длины, поэтому ряды разной высоты, и секция прыгала при смене таба
   (на 390px: 834 → 885px). Оба ряда в одной ячейке грида: высота секции = большему ряду,
   неактивный ряд остаётся в раскладке, но невидим, не кликается и не получает фокус. */
.wks { display: grid; grid-template-columns: minmax(0, 1fr); }
.wks > * { min-width: 0; }
.wks > .wk { grid-row: 3; grid-column: 1; }
.wks > .wk-cta-row { grid-row: 4; }
.wk[hidden] { display: block; visibility: hidden; pointer-events: none; }
/* Вторая правка: в пакете при prefers-reduced-motion стрелки подсказки продолжали качаться —
   `.wk-hint svg { animation: none }` слабее исходных `.wk-hint svg:first-child / :last-child`. */
@media (prefers-reduced-motion: reduce) {
  .wk-hint svg:first-child, .wk-hint svg:last-child { animation: none; }
}
