/* CDO Global — Каталог ИИ-тренажёров для вузов (/trainers/)
   Автономный CSS раздела: токены повторяют тёмную тему сайта (projects/css/styles.css),
   классы с префиксами .tr- (каталог) и .td- (страница тренажёра), чтобы не конфликтовать
   с глобальными стилями шапки, формы (cta-form.css) и a11y-contrast.css. */

:root {
  --tr-bg: #0B0F0C;
  --tr-bg-2: #0F1511;
  --tr-surface: rgba(255, 255, 255, .035);
  --tr-surface-2: rgba(255, 255, 255, .06);
  --tr-surface-3: rgba(255, 255, 255, .09);
  --tr-border: rgba(255, 255, 255, .09);
  --tr-border-2: rgba(255, 255, 255, .16);
  --tr-text: #F3F6F2;
  --tr-text-2: rgba(243, 246, 242, .78);
  --tr-text-3: rgba(243, 246, 242, .58);
  --tr-lime: #74D414;
  --tr-lime-2: #8BE12A;
  --tr-lime-soft: rgba(116, 212, 20, .14);
  --tr-lime-line: rgba(116, 212, 20, .38);
  --tr-ink: #0E1A06;
  --tr-radius: 18px;
  --tr-radius-sm: 10px;
  --tr-container: 1200px;
  --tr-header-h: 60px;
  --tr-font: 'Manrope', 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --tr-shadow: 0 18px 50px rgba(0, 0, 0, .45);
  --tr-ease: cubic-bezier(.2, .7, .2, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--tr-header-h) + 76px); -webkit-text-size-adjust: 100%; }
body.tr-page {
  margin: 0;
  background: var(--tr-bg);
  color: var(--tr-text);
  font-family: var(--tr-font);
  font-size: 16px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
body.tr-page a { color: inherit; text-decoration: none; }
.tr-page main img:not(.cdo-cta-block img), .tr-page .tr-footer img { max-width: 100%; height: auto; display: block; }
.tr-page main :is(button, input, select):not(.cdo-cta-block *) { font: inherit; color: inherit; }
body.tr-page :focus-visible { outline: 2px solid var(--tr-lime); outline-offset: 2px; border-radius: 6px; }

.skip-link { position: absolute; left: -9999px; }
.skip-link:focus { left: 1rem; top: 1rem; background: var(--tr-lime); color: var(--tr-ink); padding: .5rem .75rem; border-radius: 8px; z-index: 9999; }

.tr-container { max-width: var(--tr-container); margin: 0 auto; padding: 0 20px; }
.tr-visually-hidden { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

/* ---------- Общие элементы ---------- */
.tr-eyebrow {
  display: inline-flex; align-items: center; gap: .55rem;
  font-size: 12.5px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase;
  color: var(--tr-lime);
}
.tr-eyebrow::before { content: ''; width: 22px; height: 2px; background: var(--tr-lime); border-radius: 2px; }

.tr-breadcrumbs { font-size: 13.5px; color: var(--tr-text-3); }
.tr-breadcrumbs ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: .4rem; }
.tr-breadcrumbs li + li::before { content: '/'; margin-right: .4rem; opacity: .5; }
.tr-breadcrumbs a:hover { color: var(--tr-text); }
.tr-breadcrumbs [aria-current] { color: var(--tr-text-2); }

.tr-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  min-height: 46px; padding: 0 1.3rem; border-radius: 999px;
  font-weight: 700; font-size: 15px; line-height: 1.2; cursor: pointer;
  border: 1px solid transparent; transition: transform .18s var(--tr-ease), background .18s, border-color .18s, color .18s;
  text-decoration: none;
}
.tr-btn:hover { transform: translateY(-1px); }
.tr-btn--primary { background: var(--tr-lime); color: var(--tr-ink); }
.tr-btn--primary:hover { background: var(--tr-lime-2); color: var(--tr-ink); }
.tr-btn--ghost { background: transparent; color: var(--tr-text); border-color: var(--tr-border-2); }
.tr-btn--ghost:hover { border-color: var(--tr-lime-line); background: var(--tr-surface); }
.tr-btn--sm { min-height: 38px; padding: 0 1rem; font-size: 14px; }

.tr-pill {
  display: inline-flex; align-items: center; gap: .35rem;
  padding: .3rem .7rem; border-radius: 999px; font-size: 12.5px; font-weight: 600; line-height: 1.3;
  background: var(--tr-surface-2); border: 1px solid var(--tr-border); color: var(--tr-text-2); white-space: nowrap;
}
.tr-pill--lime { background: var(--tr-lime-soft); border-color: var(--tr-lime-line); color: #CFF59E; }
.tr-pill--flag { background: var(--tr-lime); border-color: var(--tr-lime); color: var(--tr-ink); font-weight: 800; letter-spacing: .04em; text-transform: uppercase; font-size: 11.5px; }
.tr-pill--status { background: rgba(255,255,255,.04); border-style: dashed; color: var(--tr-text-3); }

.tr-section { padding: 64px 0; }
.tr-section--tight { padding: 40px 0; }
.tr-section-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 1rem 2rem; margin-bottom: 28px; }
.tr-section-title { font-size: clamp(24px, 3vw, 34px); line-height: 1.15; font-weight: 800; letter-spacing: -.015em; margin: .35rem 0 0; }
.tr-section-sub { color: var(--tr-text-2); font-size: 16.5px; max-width: 760px; margin: .6rem 0 0; }

/* ---------- Hero каталога ---------- */
.tr-hero {
  position: relative; overflow: hidden;
  padding: 64px 0 40px;
  background:
    radial-gradient(900px 420px at 80% -10%, rgba(116, 212, 20, .16), transparent 60%),
    radial-gradient(600px 300px at 10% 110%, rgba(116, 212, 20, .08), transparent 60%),
    linear-gradient(180deg, #0D1310 0%, var(--tr-bg) 100%);
  border-bottom: 1px solid var(--tr-border);
}
.tr-hero::before {
  content: ''; position: absolute; inset: 0; pointer-events: none; opacity: .5;
  background-image: linear-gradient(rgba(255,255,255,.035) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.035) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: linear-gradient(180deg, rgba(0,0,0,.9), transparent 90%);
  -webkit-mask-image: linear-gradient(180deg, rgba(0,0,0,.9), transparent 90%);
}
.tr-hero .tr-container { position: relative; }
.tr-hero-grid { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, .95fr); gap: 40px; align-items: end; }
.tr-hero h1 { font-size: clamp(32px, 4.6vw, 54px); line-height: 1.05; letter-spacing: -.02em; font-weight: 800; margin: 18px 0 18px; }
.tr-hero h1 em { font-style: normal; color: var(--tr-lime); }
.tr-hero-lead { font-size: clamp(16.5px, 1.4vw, 19px); color: var(--tr-text-2); max-width: 640px; margin: 0; }
.tr-hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }
.tr-hero-note { margin-top: 18px; font-size: 13.5px; color: var(--tr-text-3); max-width: 620px; }

.tr-stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.tr-stat {
  padding: 18px 18px 16px; border-radius: var(--tr-radius-sm);
  background: var(--tr-surface); border: 1px solid var(--tr-border);
  backdrop-filter: blur(6px);
}
.tr-stat b { display: block; font-size: 30px; line-height: 1; font-weight: 800; letter-spacing: -.02em; color: var(--tr-text); }
.tr-stat b small { font-size: 16px; font-weight: 700; color: var(--tr-lime); margin-left: .15rem; }
.tr-stat span { display: block; margin-top: 8px; font-size: 13.5px; color: var(--tr-text-3); line-height: 1.35; }

/* Быстрые подборки */
.tr-presets { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 30px; }
.tr-presets-label { font-size: 13px; color: var(--tr-text-3); align-self: center; margin-right: 4px; }
.tr-preset {
  display: inline-flex; align-items: center; gap: .45rem; padding: .5rem .95rem; border-radius: 999px;
  background: var(--tr-surface-2); border: 1px solid var(--tr-border); color: var(--tr-text-2);
  font-size: 13.5px; font-weight: 600; cursor: pointer; transition: border-color .15s, color .15s, background .15s;
}
.tr-preset:hover, .tr-preset.is-active { border-color: var(--tr-lime-line); color: var(--tr-text); background: var(--tr-lime-soft); }

/* ---------- Панель инструментов ---------- */
.tr-toolbar {
  position: sticky; top: var(--tr-header-h); z-index: 30;
  background: rgba(11, 15, 12, .88); backdrop-filter: saturate(140%) blur(10px); -webkit-backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid var(--tr-border);
}
.tr-toolbar-row { display: flex; align-items: center; gap: 12px; padding: 12px 0; flex-wrap: wrap; }
.tr-search { position: relative; flex: 1 1 320px; min-width: 240px; }
.tr-search svg { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); width: 18px; height: 18px; color: var(--tr-text-3); pointer-events: none; }
.tr-search input {
  width: 100%; height: 46px; padding: 0 44px 0 42px; border-radius: 12px;
  background: var(--tr-surface-2); border: 1px solid var(--tr-border); color: var(--tr-text);
  transition: border-color .15s, background .15s;
}
.tr-search input::placeholder { color: var(--tr-text-3); }
.tr-search input::-webkit-search-cancel-button, .tr-search input::-webkit-search-decoration { -webkit-appearance: none; appearance: none; display: none; }
.tr-search input:focus { border-color: var(--tr-lime-line); background: var(--tr-surface-3); }
.tr-search input:focus-visible, .tr-select-wrap select:focus-visible { outline: 2px solid var(--tr-lime); outline-offset: 2px; }
.tr-search-clear {
  position: absolute; right: 8px; top: 50%; transform: translateY(-50%);
  width: 30px; height: 30px; border-radius: 50%; border: 0; background: transparent; color: var(--tr-text-3); cursor: pointer; display: none; align-items: center; justify-content: center; font-size: 20px; line-height: 1;
}
.tr-search.has-value .tr-search-clear { display: inline-flex; }
.tr-search-clear:hover { background: var(--tr-surface-3); color: var(--tr-text); }

.tr-count { font-size: 14px; color: var(--tr-text-3); white-space: nowrap; }
.tr-count b { color: var(--tr-text); font-weight: 700; }

.tr-select-wrap { position: relative; }
.tr-select-wrap select {
  appearance: none; -webkit-appearance: none; height: 46px; padding: 0 40px 0 14px; border-radius: 12px;
  background: var(--tr-surface-2); border: 1px solid var(--tr-border); color: var(--tr-text); cursor: pointer; max-width: 280px;
}
.tr-select-wrap select:focus { border-color: var(--tr-lime-line); }
.tr-select-wrap::after { content: ''; position: absolute; right: 16px; top: 50%; width: 8px; height: 8px; border-right: 2px solid var(--tr-text-3); border-bottom: 2px solid var(--tr-text-3); transform: translateY(-70%) rotate(45deg); pointer-events: none; }
.tr-select-wrap select option { background: #111814; color: #fff; }

.tr-view { display: inline-flex; border: 1px solid var(--tr-border); border-radius: 12px; overflow: hidden; }
.tr-view button {
  width: 46px; height: 46px; display: inline-flex; align-items: center; justify-content: center;
  background: var(--tr-surface-2); border: 0; cursor: pointer; color: var(--tr-text-3); transition: background .15s, color .15s;
}
.tr-view button + button { border-left: 1px solid var(--tr-border); }
.tr-view button svg { width: 18px; height: 18px; }
.tr-view button[aria-pressed="true"] { background: var(--tr-lime-soft); color: var(--tr-lime); }
.tr-view button:hover { color: var(--tr-text); }

.tr-filters-toggle { display: none; }

/* Активные фильтры */
.tr-active { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 0 0 12px; }
.tr-active:empty { display: none; }
.tr-active-pill {
  display: inline-flex; align-items: center; gap: .4rem; padding: .32rem .45rem .32rem .75rem; border-radius: 999px;
  background: var(--tr-lime-soft); border: 1px solid var(--tr-lime-line); color: #DDF7B8; font-size: 13px; font-weight: 600; cursor: pointer;
}
.tr-active-pill span { opacity: .6; font-weight: 500; }
.tr-active-pill b { font-weight: 800; font-size: 15px; line-height: 1; margin-left: .15rem; opacity: .8; }
.tr-active-pill:hover b { opacity: 1; }
.tr-active-reset { background: transparent; border: 0; color: var(--tr-text-3); font-size: 13px; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; padding: .3rem .4rem; }
.tr-active-reset:hover { color: var(--tr-text); }

/* ---------- Компоновка каталога ---------- */
.tr-catalog { display: grid; grid-template-columns: 272px minmax(0, 1fr); gap: 32px; padding-top: 28px; padding-bottom: 56px; align-items: start; }

.tr-filters { position: sticky; top: calc(var(--tr-header-h) + 82px); max-height: calc(100vh - var(--tr-header-h) - 100px); overflow: auto; padding-right: 6px; scrollbar-width: thin; }
.tr-filters-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.tr-filters-head h2 { font-size: 15px; font-weight: 800; margin: 0; letter-spacing: .02em; }
.tr-filters-head button { background: none; border: 0; color: var(--tr-text-3); font-size: 13px; cursor: pointer; padding: 4px 6px; }
.tr-filters-head button:hover { color: var(--tr-text); }
.tr-filters-close { display: none; }

.tr-fgroup { border: 0; margin: 0; padding: 14px 0; border-top: 1px solid var(--tr-border); }
.tr-fgroup legend { float: left; width: 100%; padding: 0; margin: 0 0 10px; font-size: 13px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--tr-text-3); }
.tr-fgroup legend + * { clear: both; }
.tr-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.tr-chip { position: relative; display: inline-flex; }
.tr-chip input { position: absolute; opacity: 0; width: 1px; height: 1px; margin: 0; pointer-events: none; }
.tr-chip span {
  display: inline-flex; align-items: center; gap: .4rem; padding: .42rem .8rem; border-radius: 999px;
  background: var(--tr-surface-2); border: 1px solid var(--tr-border); color: var(--tr-text-2); font-size: 13.5px; line-height: 1.25;
  cursor: pointer; transition: border-color .15s, background .15s, color .15s; user-select: none;
}
.tr-chip span em { font-style: normal; color: var(--tr-text-3); font-size: 12px; }
.tr-chip:hover span { border-color: var(--tr-border-2); color: var(--tr-text); }
.tr-chip input:checked + span { background: var(--tr-lime-soft); border-color: var(--tr-lime-line); color: #E4FAC7; }
.tr-chip input:checked + span em { color: var(--tr-lime); }
.tr-chip input:focus-visible + span { outline: 2px solid var(--tr-lime); outline-offset: 2px; }
.tr-chip.is-zero span { opacity: .4; }
.tr-chip.is-zero input:checked + span { opacity: 1; }
.tr-fgroup .tr-more { background: none; border: 0; color: var(--tr-lime); font-size: 13px; font-weight: 600; cursor: pointer; padding: 8px 0 0; }
.tr-fgroup .tr-more:hover { text-decoration: underline; }
.tr-fgroup[data-collapsed="true"] .tr-chip.is-extra { display: none; }
.tr-chip.is-hidden { display: none; }
.tr-chip-logo { width: 16px; height: 16px; object-fit: contain; flex: 0 0 auto; }
.tr-chip-search { margin: 0 0 10px; }
.tr-chip-search input {
  width: 100%; height: 38px; padding: 0 12px; border-radius: 10px; border: 1px solid var(--tr-border); background: var(--tr-surface);
  color: var(--tr-text); font: inherit; font-size: 13.5px; outline: none;
}
.tr-chip-search input::placeholder { color: var(--tr-text-3); }
.tr-chip-search input:focus-visible { border-color: var(--tr-lime-line); box-shadow: 0 0 0 3px rgba(116, 212, 20, .14); }
.tr-chip-search input::-webkit-search-cancel-button { filter: invert(1) opacity(.6); }
.tr-legal { margin: 26px 0 0; font-size: 12.5px; line-height: 1.5; color: var(--tr-text-3); max-width: 900px; }

/* ---------- Сетка карточек ---------- */
.tr-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; list-style: none; margin: 0; padding: 0; }
.tr-grid > li { display: flex; min-width: 0; }

.tr-card {
  position: relative; display: flex; flex-direction: column; width: 100%;
  background: var(--tr-surface); border: 1px solid var(--tr-border); border-radius: var(--tr-radius);
  overflow: hidden; color: inherit; transition: transform .22s var(--tr-ease), border-color .22s, box-shadow .22s;
}
.tr-card:hover, .tr-card:focus-within { transform: translateY(-4px); border-color: var(--tr-lime-line); box-shadow: var(--tr-shadow); }
.tr-card:focus-visible { outline: 2px solid var(--tr-lime); outline-offset: 3px; }
.tr-card-media { position: relative; aspect-ratio: 16 / 9; overflow: hidden; background: #0d1410; }
.tr-card-media > img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--tr-ease); }
.tr-card:hover .tr-card-media > img { transform: scale(1.04); }
.tr-card-media::after { content: ''; position: absolute; inset: auto 0 0 0; height: 46%; background: linear-gradient(180deg, transparent, rgba(11, 15, 12, .75)); pointer-events: none; }
.tr-card-badges { position: absolute; top: 12px; left: 12px; right: 12px; display: flex; justify-content: space-between; gap: 8px; z-index: 2; }
.tr-card-badges .tr-pill--status { background: rgba(11, 15, 12, .78); border-color: rgba(255,255,255,.22); color: var(--tr-text-2); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }

/* Логотипы сред и инструментов поверх обложки (учебные профили интерфейсов) */
.tr-card-tools, .td-cover-tools {
  --tr-tile: 38px; --tr-tile-logo: 23px; --tr-tile-gap: 5px;
  position: absolute; right: 12px; bottom: 12px; z-index: 2;
  display: grid; grid-template-columns: repeat(var(--tr-cols, 4), var(--tr-tile)); gap: var(--tr-tile-gap);
  justify-content: end; pointer-events: none;
}
.tr-tile, .td-tile {
  display: inline-flex; align-items: center; justify-content: center; width: var(--tr-tile); height: var(--tr-tile);
  border-radius: 10px; background: rgba(11, 15, 12, .66); border: 1px solid rgba(255,255,255,.14);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); box-shadow: 0 6px 18px rgba(0,0,0,.28);
  color: #E8EDE6; font-size: 11px; font-weight: 700; letter-spacing: .02em; pointer-events: auto; overflow: hidden;
}
.tr-tile img, .td-tile img { width: var(--tr-tile-logo); height: var(--tr-tile-logo); object-fit: contain; display: block; }
.tr-tile-abbr { display: block; font-size: 8px; line-height: 1.1; font-weight: 800; text-transform: uppercase; letter-spacing: .03em; text-align: center; padding: 0 2px; white-space: nowrap; }
.tr-tile-abbr--long { font-size: 6.5px; letter-spacing: 0; }
.tr-tile--more, .td-tile--more { background: rgba(116, 212, 20, .22); border-color: rgba(116, 212, 20, .45); color: #E4FAC7; font-size: 12px; }
.tr-card-media:hover .tr-tile { border-color: rgba(255,255,255,.3); }
/* На странице тренажёра — панель всех сред вдоль нижнего края обложки */
.td-cover-tools {
  --tr-tile: 44px; --tr-tile-logo: 26px; --tr-tile-gap: 5px;
  left: 0; right: 0; bottom: 0; display: flex; flex-wrap: wrap; justify-content: flex-start;
  padding: 34px 14px 12px; background: linear-gradient(180deg, rgba(11, 15, 12, 0), rgba(11, 15, 12, .82) 45%);
}
.tr-card-tools .tr-tile-abbr { font-size: 7px; }
.tr-card-tools .tr-tile-abbr--long { font-size: 5.8px; }
.tr-card-tools .tr-tile--more { font-size: 11px; }
.tr-grid.is-list .tr-card-tools { --tr-tile: 32px; --tr-tile-logo: 20px; --tr-tile-gap: 4px; right: 8px; bottom: 8px; }
.tr-grid.is-list .tr-tile-abbr { font-size: 6px; }
.tr-grid.is-list .tr-tile-abbr--long { font-size: 5px; }
.tr-grid.is-list .tr-card-tools .tr-tile--more { font-size: 10px; }
.tr-card-body { display: flex; flex-direction: column; gap: 10px; padding: 18px 18px 16px; flex: 1; }
.tr-card-dir { font-size: 12.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--tr-lime); }
.tr-card h3 { font-size: 20px; line-height: 1.25; font-weight: 800; letter-spacing: -.01em; margin: 0; }
.tr-card h3 a::after { content: ''; position: absolute; inset: 0; z-index: 1; }
.tr-card p { margin: 0; font-size: 14.5px; line-height: 1.5; color: var(--tr-text-2); display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.tr-card-meta { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 2px; }
.tr-card-meta .tr-pill { font-size: 12px; padding: .25rem .6rem; }
.tr-card-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: auto; padding-top: 12px; border-top: 1px solid var(--tr-border); }
.tr-card-tags { display: flex; flex-wrap: nowrap; gap: 6px; min-width: 0; overflow: hidden; flex: 1 1 auto; -webkit-mask-image: linear-gradient(90deg, #000 70%, transparent); mask-image: linear-gradient(90deg, #000 70%, transparent); }
.tr-card-tags span { font-size: 12px; color: var(--tr-text-3); background: var(--tr-surface-2); padding: .2rem .5rem; border-radius: 6px; white-space: nowrap; }
.tr-card-more { font-size: 14px; font-weight: 700; color: var(--tr-lime); white-space: nowrap; }
.tr-card:hover .tr-card-more { text-decoration: underline; text-underline-offset: 3px; }

/* Список */
.tr-grid.is-list { grid-template-columns: 1fr; gap: 14px; }
.tr-grid.is-list .tr-card { flex-direction: row; align-items: stretch; }
.tr-grid.is-list .tr-card-media { flex: 0 0 300px; aspect-ratio: auto; min-height: 180px; }
.tr-grid.is-list .tr-card-media::after { background: linear-gradient(90deg, transparent, rgba(11, 15, 12, .6)); inset: 0 0 0 auto; width: 40%; height: auto; }
.tr-grid.is-list .tr-card-body { padding: 20px 22px; }
.tr-grid.is-list .tr-card p { -webkit-line-clamp: 2; }
.tr-grid.is-list .tr-card h3 { font-size: 22px; }

/* Пустое состояние / показать ещё */
.tr-empty { display: none; padding: 48px 24px; text-align: center; border: 1px dashed var(--tr-border-2); border-radius: var(--tr-radius); color: var(--tr-text-2); }
.tr-empty.is-visible { display: block; }
.tr-empty h3 { margin: 0 0 8px; font-size: 20px; color: var(--tr-text); }
.tr-empty p { margin: 0 0 18px; }
.tr-more-wrap { display: flex; justify-content: center; margin-top: 28px; }
.tr-more-wrap[hidden] { display: none; }
.tr-sr-status { position: absolute; left: -9999px; }

/* ---------- Как устроен тренажёр ---------- */
.tr-how { border-top: 1px solid var(--tr-border); background: linear-gradient(180deg, var(--tr-bg) 0%, var(--tr-bg-2) 100%); }
.tr-steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; counter-reset: step; }
.tr-step { position: relative; padding: 24px 22px 22px; border-radius: var(--tr-radius); background: var(--tr-surface); border: 1px solid var(--tr-border); }
.tr-step::before { counter-increment: step; content: counter(step, decimal-leading-zero); display: inline-block; font-size: 13px; font-weight: 800; letter-spacing: .1em; color: var(--tr-lime); margin-bottom: 14px; }
.tr-step h3 { margin: 0 0 8px; font-size: 19px; line-height: 1.3; }
.tr-step p { margin: 0; color: var(--tr-text-2); font-size: 15px; }

/* ---------- Полный указатель ---------- */
.tr-index { border-top: 1px solid var(--tr-border); }
.tr-index ul { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px 32px; }
.tr-index li { padding: 12px 0; border-bottom: 1px solid var(--tr-border); display: flex; flex-direction: column; gap: 4px; }
.tr-index li a { font-weight: 700; }
.tr-index li a:hover { color: var(--tr-lime); }
.tr-index li small { color: var(--tr-text-3); font-size: 13.5px; }

/* ---------- FAQ ---------- */
.tr-faq details { border: 1px solid var(--tr-border); border-radius: var(--tr-radius-sm); background: var(--tr-surface); margin-bottom: 10px; }
.tr-faq summary { list-style: none; cursor: pointer; padding: 18px 54px 18px 20px; font-weight: 700; font-size: 17px; position: relative; }
.tr-faq summary::-webkit-details-marker { display: none; }
.tr-faq summary::after { content: '+'; position: absolute; right: 20px; top: 50%; transform: translateY(-50%); width: 26px; height: 26px; border-radius: 50%; border: 1px solid var(--tr-border-2); display: grid; place-items: center; color: var(--tr-lime); font-weight: 600; }
.tr-faq details[open] summary::after { content: '–'; }
.tr-faq details > div { padding: 0 20px 20px; color: var(--tr-text-2); }
.tr-faq details > div p { margin: 0 0 .7rem; }
.tr-faq details > div p:last-child { margin-bottom: 0; }

/* ---------- Футер ---------- */
.tr-footer { border-top: 1px solid var(--tr-border); padding: 48px 0 28px; margin-top: 24px; background: var(--tr-bg-2); color: var(--tr-text-2); font-size: 14.5px; }
.tr-footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 32px; }
.tr-footer h4 { color: var(--tr-text); font-size: 15px; margin: 0 0 12px; }
.tr-footer ul { list-style: none; margin: 0; padding: 0; }
.tr-footer li { margin: 0 0 8px; }
.tr-footer a:hover { color: var(--tr-lime); }
.tr-footer-brand img { height: 26px; width: auto; margin-bottom: 12px; }
.tr-footer-brand p { margin: 0; max-width: 420px; color: var(--tr-text-3); }
.tr-footer-bottom { margin-top: 32px; padding-top: 18px; border-top: 1px solid var(--tr-border); display: flex; flex-wrap: wrap; gap: 10px 24px; justify-content: space-between; font-size: 13px; color: var(--tr-text-3); }

/* ---------- Страница тренажёра ---------- */
.td-hero {
  position: relative; overflow: hidden; padding: 36px 0 44px;
  background:
    radial-gradient(800px 380px at 85% 0%, rgba(116, 212, 20, .14), transparent 60%),
    linear-gradient(180deg, #0D1310 0%, var(--tr-bg) 100%);
  border-bottom: 1px solid var(--tr-border);
}
.td-hero::before { content: ''; position: absolute; inset: 0; pointer-events: none; opacity: .45; background-image: linear-gradient(rgba(255,255,255,.035) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.035) 1px, transparent 1px); background-size: 48px 48px; mask-image: linear-gradient(180deg, rgba(0,0,0,.9), transparent 95%); -webkit-mask-image: linear-gradient(180deg, rgba(0,0,0,.9), transparent 95%); }
.td-hero .tr-container { position: relative; }
.td-hero-grid { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: 44px; align-items: center; margin-top: 26px; }
.td-badges { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.td-hero h1 { font-size: clamp(30px, 4.2vw, 50px); line-height: 1.06; letter-spacing: -.02em; font-weight: 800; margin: 0 0 14px; }
.td-subtitle { font-size: clamp(18px, 1.6vw, 22px); line-height: 1.35; color: var(--tr-lime); font-weight: 600; margin: 0 0 16px; }
.td-lead { font-size: 17px; color: var(--tr-text-2); margin: 0; max-width: 620px; }
.td-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }
.td-cover { position: relative; border-radius: var(--tr-radius); overflow: hidden; border: 1px solid var(--tr-border-2); background: #0d1410; box-shadow: var(--tr-shadow); }
.td-cover::after { content: ''; position: absolute; inset: 0; box-shadow: inset 0 0 0 1px rgba(255,255,255,.04); pointer-events: none; }
.td-cover > img { width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; display: block; }
.td-cover-glow { position: absolute; inset: -40px; background: radial-gradient(closest-side, rgba(116,212,20,.18), transparent 70%); z-index: -1; filter: blur(20px); }

/* Паспорт */
.td-passport { margin-top: -22px; position: relative; z-index: 2; }
.td-passport dl {
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1px; margin: 0;
  background: var(--tr-border); border: 1px solid var(--tr-border); border-radius: var(--tr-radius); overflow: hidden; box-shadow: var(--tr-shadow);
}
.td-passport > dl > div { background: #10171290; background: color-mix(in srgb, var(--tr-bg) 88%, white 4%); padding: 18px 20px; min-width: 0; }
.td-passport dt { font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--tr-text-3); margin-bottom: 6px; }
.td-passport dd { margin: 0; font-size: 15px; line-height: 1.45; color: var(--tr-text); }
.td-passport dd small { display: block; color: var(--tr-text-3); font-size: 13px; margin-top: 2px; }
.td-passport .td-wide { grid-column: span 2; }
.td-passport-note { margin-top: 12px; font-size: 13.5px; color: var(--tr-text-3); }
.td-plats { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.td-plat {
  display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px 4px 6px; border-radius: 999px;
  background: var(--tr-surface-2); border: 1px solid var(--tr-border); color: var(--tr-text-2); font-size: 12.5px; line-height: 1.2;
  text-decoration: none; transition: border-color .15s, color .15s, background .15s;
}
.td-plat img { width: 18px; height: 18px; object-fit: contain; }
.td-plat-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--tr-lime); margin: 0 4px 0 5px; opacity: .8; }
.td-plat:hover { border-color: var(--tr-lime-line); color: var(--tr-text); background: var(--tr-lime-soft); }
.td-plat:focus-visible { outline: 2px solid var(--tr-lime); outline-offset: 2px; }
.td-passport dd a:not(.td-plat) { color: var(--tr-lime-2); text-decoration: underline; text-underline-offset: 3px; }

/* Якорная навигация */
.td-anchors { position: sticky; top: var(--tr-header-h); z-index: 20; background: rgba(11, 15, 12, .9); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-bottom: 1px solid var(--tr-border); margin-top: 28px; }
.td-anchors .tr-container { position: relative; }
.td-anchors ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 2px; overflow-x: auto; scrollbar-width: none; -ms-overflow-style: none; scroll-behavior: smooth; }
.td-anchors.has-overflow .tr-container::after { content: ''; position: absolute; top: 0; bottom: 0; right: 0; width: 72px; background: linear-gradient(90deg, rgba(11, 15, 12, 0), rgba(11, 15, 12, .95)); pointer-events: none; }
.td-anchors.at-end .tr-container::after { opacity: 0; }
.td-anchors ul::-webkit-scrollbar { display: none; }
.td-anchors a { display: inline-block; padding: 14px 10px; font-size: 13.5px; font-weight: 600; color: var(--tr-text-3); white-space: nowrap; border-bottom: 2px solid transparent; }
.td-anchors a:hover { color: var(--tr-text); }
.td-anchors a.is-active { color: var(--tr-text); border-bottom-color: var(--tr-lime); }

/* Контент */
.td-layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 48px; padding-top: 40px; padding-bottom: 24px; align-items: start; }
.td-body { min-width: 0; max-width: 760px; }
.td-body > section { padding: 8px 0 28px; }
.td-body > section + section { border-top: 1px solid var(--tr-border); padding-top: 32px; }
.td-body h2 { font-size: clamp(22px, 2.6vw, 29px); line-height: 1.2; letter-spacing: -.015em; font-weight: 800; margin: 0 0 16px; scroll-margin-top: calc(var(--tr-header-h) + 70px); }
.td-body h3 { font-size: 18.5px; margin: 24px 0 10px; font-weight: 800; }
.td-body p { margin: 0 0 1rem; color: var(--tr-text-2); font-size: 16.5px; line-height: 1.62; }
.td-body p strong, .td-body li strong { color: var(--tr-text); }
.td-body a:not(.tr-btn) { color: var(--tr-lime-2); text-decoration: underline; text-decoration-color: rgba(139, 225, 42, .35); text-underline-offset: 3px; }
.td-body a:not(.tr-btn):hover { text-decoration-color: currentColor; }
.td-body ul, .td-body ol { margin: 0 0 1.1rem; padding-left: 1.25rem; color: var(--tr-text-2); font-size: 16px; }
.td-body li { margin: 0 0 .5rem; line-height: 1.55; }
.td-body ul li::marker { color: var(--tr-lime); }
.td-body ol { list-style: none; padding: 0; counter-reset: li; }
.td-body ol > li { position: relative; padding-left: 44px; margin-bottom: .9rem; }
.td-body ol > li::before { counter-increment: li; content: counter(li); position: absolute; left: 0; top: .05em; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; font-size: 13.5px; font-weight: 800; color: var(--tr-lime); background: var(--tr-lime-soft); border: 1px solid var(--tr-lime-line); }
.td-body code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: .9em; background: var(--tr-surface-2); padding: .1em .4em; border-radius: 5px; color: var(--tr-text); }
.td-body blockquote { margin: 0 0 1.1rem; padding: 16px 20px; border-left: 3px solid var(--tr-lime); background: var(--tr-surface); border-radius: 0 var(--tr-radius-sm) var(--tr-radius-sm) 0; color: var(--tr-text-2); }
.td-body blockquote p:last-child { margin-bottom: 0; }

/* Карточки определений (список «**Заголовок.** текст») */
.td-defs { list-style: none !important; padding: 0 !important; margin: 0 0 1.1rem !important; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.td-defs li { margin: 0 !important; padding: 16px 18px !important; background: var(--tr-surface); border: 1px solid var(--tr-border); border-radius: var(--tr-radius-sm); font-size: 15px !important; line-height: 1.5; }
.td-defs li::marker { content: ''; }
.td-defs li:last-child:nth-child(odd) { grid-column: 1 / -1; }
.td-defs li strong { display: block; color: var(--tr-text); font-size: 15.5px; margin-bottom: 4px; }
.td-defs li strong::after { content: ''; display: block; width: 26px; height: 2px; background: var(--tr-lime); margin-top: 8px; opacity: .8; }

/* Роли ИИ-команды */
.td-roles { list-style: none !important; padding: 0 !important; margin: 0 0 1.1rem !important; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.td-roles li { margin: 0 !important; display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 14px; padding: 16px 18px !important; background: var(--tr-surface); border: 1px solid var(--tr-border); border-radius: var(--tr-radius-sm); font-size: 15px !important; line-height: 1.5; }
.td-roles li::marker { content: ''; }
.td-roles .td-avatar { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; font-size: 15px; color: var(--tr-ink); background: linear-gradient(135deg, var(--tr-lime), #B9F56A); box-shadow: 0 0 0 4px var(--tr-lime-soft); }
.td-roles li strong { display: block; color: var(--tr-text); margin-bottom: 3px; font-size: 15.5px; }

/* Таблицы */
.td-table-wrap { overflow-x: auto; margin: 0 0 1.2rem; border: 1px solid var(--tr-border); border-radius: var(--tr-radius-sm); -webkit-overflow-scrolling: touch; }
.td-body table { width: 100%; border-collapse: collapse; font-size: 15px; min-width: 520px; }
.td-body th, .td-body td { text-align: left; vertical-align: top; padding: 12px 14px; border-bottom: 1px solid var(--tr-border); color: var(--tr-text-2); line-height: 1.5; }
.td-body th { background: var(--tr-surface-2); color: var(--tr-text); font-weight: 700; font-size: 13.5px; letter-spacing: .02em; }
.td-body tr:last-child td { border-bottom: 0; }
.td-body td:first-child { color: var(--tr-text); font-weight: 600; white-space: nowrap; }

/* Галерея макетов */
.td-gallery { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin: 0 0 14px; }
.td-gallery figure { margin: 0; border: 1px solid var(--tr-border); border-radius: var(--tr-radius-sm); overflow: hidden; background: var(--tr-surface); }
.td-gallery a { display: block; width: 100%; padding: 0; border: 0; background: none; cursor: zoom-in; line-height: 0; }
.td-gallery a:focus-visible { outline: 2px solid var(--tr-lime); outline-offset: -2px; }
.td-gallery img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; }
.td-gallery figcaption { padding: 10px 14px 12px; font-size: 13.5px; color: var(--tr-text-3); line-height: 1.4; }
.td-gallery-note { font-size: 13.5px; color: var(--tr-text-3); margin: 0 0 1rem; }
.td-lightbox { border: 0; padding: 0; background: transparent; max-width: min(96vw, 1400px); }
.td-lightbox::backdrop { background: rgba(5, 8, 6, .9); backdrop-filter: blur(6px); }
.td-lightbox img { width: 100%; height: auto; max-height: 80vh; object-fit: contain; border-radius: 12px; }
.td-lightbox figure { padding-top: 50px; }
.td-lightbox-close { position: absolute; top: 0; right: 0; margin: 0; z-index: 1; width: 40px; height: 40px; border-radius: 50%; border: 1px solid rgba(255, 255, 255, .35); background: rgba(255, 255, 255, .12); color: #fff; cursor: pointer; font-size: 22px; line-height: 1; }
.td-lightbox-close:hover { background: rgba(255, 255, 255, .22); }
.td-lightbox-close:focus-visible { outline: 2px solid var(--tr-lime); outline-offset: 2px; }
.td-lightbox figcaption { color: var(--tr-text-2); font-size: 14px; text-align: center; margin-top: 10px; }

/* Боковая колонка */
.td-aside { position: sticky; top: calc(var(--tr-header-h) + 70px); display: flex; flex-direction: column; gap: 16px; }
.td-aside-card { padding: 20px; border-radius: var(--tr-radius); background: var(--tr-surface); border: 1px solid var(--tr-border); }
.td-aside-card h3 { margin: 0 0 10px; font-size: 16px; font-weight: 800; }
.td-aside-card p { margin: 0 0 14px; font-size: 14.5px; color: var(--tr-text-2); line-height: 1.5; }
.td-aside-card .tr-btn { width: 100%; }
.td-aside-card ul { list-style: none; margin: 0; padding: 0; }
.td-aside-card li { display: flex; gap: 10px; align-items: flex-start; padding: 8px 0; border-top: 1px solid var(--tr-border); font-size: 14.5px; color: var(--tr-text-2); }
.td-aside-card li:first-child { border-top: 0; padding-top: 0; }
.td-aside-card li::before { content: ''; flex: 0 0 8px; width: 8px; height: 8px; border-radius: 50%; background: var(--tr-lime); margin-top: 7px; }
.td-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.td-tags span { font-size: 12.5px; color: var(--tr-text-2); background: var(--tr-surface-2); border: 1px solid var(--tr-border); padding: .25rem .6rem; border-radius: 999px; }

/* Статус */
.td-status { margin: 8px 0 0; padding: 18px 20px; border-radius: var(--tr-radius-sm); border: 1px dashed var(--tr-border-2); background: var(--tr-surface); color: var(--tr-text-2); font-size: 14.5px; line-height: 1.55; }
.td-status strong { color: var(--tr-text); }
.td-status p { margin: 0 0 .5rem; font-size: 14.5px; }
.td-status p:last-child { margin: 0; }

/* Похожие тренажёры */
.td-related { border-top: 1px solid var(--tr-border); background: var(--tr-bg-2); }

/* Форма CTA — локальные правки поверх cta-form.css */
.cdo-cta-block { scroll-margin-top: 80px; }

/* ---------- Адаптив ---------- */
@media (max-width: 1100px) {
  .tr-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tr-catalog { grid-template-columns: 240px minmax(0, 1fr); gap: 24px; }
  .td-passport dl { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .td-passport .td-wide { grid-column: span 2; }
}
@media (max-width: 960px) {
  .tr-hero { padding: 44px 0 32px; }
  .tr-hero-grid { grid-template-columns: 1fr; gap: 26px; }
  .tr-stats { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .td-hero-grid { grid-template-columns: 1fr; gap: 26px; }
  .td-layout { grid-template-columns: 1fr; gap: 24px; }
  .td-aside { position: static; }
  .tr-footer-grid { grid-template-columns: 1fr 1fr; }
  .tr-steps { grid-template-columns: 1fr; }
}
@media (max-width: 860px) {
  .tr-catalog { grid-template-columns: 1fr; gap: 16px; }
  .tr-filters-toggle { display: inline-flex; align-items: center; gap: .5rem; height: 46px; padding: 0 16px; border-radius: 12px; border: 1px solid var(--tr-border); background: var(--tr-surface-2); cursor: pointer; font-weight: 600; font-size: 14.5px; white-space: nowrap; }
  .tr-filters-toggle b { color: var(--tr-lime); }
  .tr-filters { display: none; position: static; max-height: none; overflow: visible; padding: 18px; border: 1px solid var(--tr-border); border-radius: var(--tr-radius); background: var(--tr-bg-2); }
  .tr-filters.is-open { display: block; }
  .tr-filters-close { display: inline-block; }
  .tr-grid.is-list .tr-card { flex-direction: column; }
  .tr-grid.is-list .tr-card-media { flex: none; aspect-ratio: 16 / 9; min-height: 0; }
  .tr-grid.is-list .tr-card-media::after { inset: auto 0 0 0; width: auto; height: 46%; background: linear-gradient(180deg, transparent, rgba(11, 15, 12, .75)); }
}
@media (max-width: 700px) {
  .tr-grid { grid-template-columns: 1fr; gap: 16px; }
  .tr-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tr-stat b { font-size: 26px; }
  .tr-toolbar { position: static; backdrop-filter: none; -webkit-backdrop-filter: none; }
  .tr-toolbar-row { gap: 10px; }
  .tr-view { display: none; }
  .tr-count { flex: 1 1 auto; text-align: right; }
  .tr-select-wrap { flex: 1 1 160px; }
  .tr-select-wrap select { max-width: 100%; width: 100%; }
  .tr-presets { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 6px; margin-left: -20px; margin-right: -20px; padding-left: 20px; padding-right: 20px; scrollbar-width: none; }
  .tr-presets::-webkit-scrollbar { display: none; }
  .tr-preset, .tr-presets-label { white-space: nowrap; flex: 0 0 auto; }
  .tr-index ul { grid-template-columns: 1fr; }
  .td-defs, .td-roles, .td-gallery { grid-template-columns: 1fr; }
  .td-passport dl { grid-template-columns: 1fr; }
  .td-passport .td-wide { grid-column: auto; }
  .td-passport { margin-top: -12px; }
  .td-cover-tools { --tr-tile: 36px; --tr-tile-logo: 22px; --tr-tile-gap: 4px; padding: 26px 10px 10px; }
  .td-cover-tools .tr-tile-abbr { font-size: 7px; }
  .td-cover-tools .tr-tile-abbr--long { font-size: 5.8px; }
  .tr-footer-grid { grid-template-columns: 1fr; }
  .tr-section { padding: 48px 0; }
  .td-body td:first-child { white-space: normal; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .tr-card, .tr-card-media > img, .tr-btn { transition: none; }
  .tr-card:hover { transform: none; }
}
