/* Эффект «блеклая карточка оживает». Без JS и на устройствах без наведения блеклости нет:
   .typing-ready ставит typing.js только при (hover: hover). Заголовки карточек (kicker, summary) не тускнеют. */
[data-type] dd { position: relative; }
.ty { position: absolute; inset: 0; color: var(--c-ink); opacity: 0; pointer-events: none; transition: opacity 0.4s; }
.ty i { font-style: normal; }
.ty i + i { visibility: hidden; }
.is-typing .ty { opacity: 1; transition: none; }
.is-typing dd { color: transparent; }

/* Цветные карточки (.stack__group, .bigcard) и строки списка (.row) не блеклим целиком: тускнеет только описание, иначе текст теряет контраст */
.typing-ready [data-type]:not(.stack__group, .bigcard, .row) {
  filter: saturate(0.8);
  box-shadow: 0 2px 6px -2px rgba(42, 38, 35, 0.08);
  transition: transform 0.4s cubic-bezier(0.2, 0.7, 0.2, 1), box-shadow 0.4s, filter 0.4s;
}
/* цветные группы стека: подъём и тень плавные, как у историй (раньше вставали скачком за один кадр) */
.typing-ready .stack__group[data-type], .typing-ready .bigcard[data-type] { transition: transform 0.4s cubic-bezier(0.2, 0.7, 0.2, 1), box-shadow 0.4s; }
.typing-ready [data-type] dt,
.typing-ready [data-type] dd {
  color: rgba(42, 38, 35, 0.56);
  transition: color 0.4s;
}
.typing-ready [data-type].is-on {
  filter: none;
  transform: translateY(-7px) scale(1.01);
  box-shadow: 0 20px 38px -14px rgba(42, 38, 35, 0.3);
}
.typing-ready [data-type].is-on .ty { opacity: 1; }
.typing-ready [data-type].is-on dt { color: var(--c-ink-2); }
/* fade на карточках .bigcard (услуги, кейсы, «Кому подойдёт») и строках .row (статьи): блекнет описание, заголовок и итог читаются сразу */
.typing-ready .bigcard[data-type] .bigcard__text,
.typing-ready .bigcard[data-type] .card__dash li,
.typing-ready .row[data-type] .row__text {
  color: var(--c-ink-2); /* было 0.6 альфы (~3.8:1 на пастели), читалось плохо; теперь вторичный текст 7:1 и до наведения (аудит 15/10/2026, п. 12) */
  transition: color 0.4s;
}
.typing-ready [data-type].is-on .bigcard__text,
.typing-ready .row[data-type].is-on .row__text { color: var(--c-ink-2); }
.typing-ready .bigcard[data-type].is-on .card__dash li { color: var(--c-ink); }
/* строка списка без подъёма и тени: список не рассыпается, оживает только текст */
.typing-ready .row[data-type].is-on { transform: none; box-shadow: none; }
[data-type]:focus-visible { outline: 3px solid var(--c-focus); outline-offset: 4px; }

@media (prefers-reduced-motion: reduce) {
  .typing-ready [data-type], .typing-ready [data-type] * { transition: none; }
  .typing-ready [data-type].is-on { transform: none; }
  .typing-ready [data-type].is-on dd { color: var(--c-ink); }
}
