/* Страницы дерева каталога: С02 все группы, С03 группа, С04 категория */
.groups-filter { width: 100%; max-width: 330px; }
.groups-filter .input { background: var(--card); border-color: var(--line-strong); }
.group-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.group-card { display: flex; align-items: center; gap: 14px; padding: 16px; min-height: 84px; color: var(--text); height: 100%; }
.group-card:hover { text-decoration: none; border-color: #C9D6EA; }
.group-card b { display: block; font-size: 15px; line-height: 1.25; }
.tasks-card { display: grid; grid-template-columns: 280px 1fr; gap: 24px; align-items: center; margin-top: 36px; }
.tasks-card h2 { font-size: 22px; margin-bottom: 6px; }

.cat-grid { list-style: none; padding: 0; margin: 24px 0 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.cat-card { padding: 12px 12px 16px; display: flex; flex-direction: column; gap: 12px; }
.cat-card__photo { display: grid; place-items: center; aspect-ratio: 2.3 / 1; border-radius: 10px; background: var(--bg); color: #A9B6CA; }
.cat-card__title { font-size: 20px; padding: 0 4px; }
.cat-card__title a { display: flex; align-items: center; justify-content: space-between; gap: 8px; color: var(--text); }
.cat-card .chips { padding: 0 4px; }
.cat-card .chip { min-height: 32px; font-size: 13px; padding: 0 12px; background: var(--card); }
.chip--more { color: var(--muted); }
.cat-card__photo img { width: 100%; height: 100%; object-fit: cover; border-radius: 10px; }
.cat-card__photo { overflow: hidden; }
.cat-card--calc { background: var(--primary-soft); border-color: transparent; padding: 20px; justify-content: flex-start; }
.cat-card--calc .icon-tile { background: #fff; }
.cat-card__link { font-weight: 800; color: var(--primary); display: inline-flex; align-items: center; gap: 4px; }
.calc-links { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.calc-link { display: flex; align-items: center; gap: 14px; padding: 14px 16px; color: var(--text); height: 100%; }
.calc-link:hover { text-decoration: none; border-color: #C9D6EA; }
.calc-link > span:nth-child(2) { flex: 1; }
.calc-link b { display: block; font-size: 15px; }
.cat-head__right { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.cat-card__meta { margin-top: auto; padding: 0 4px; font-size: 13px; color: var(--muted); }

.about { margin-top: 40px; border-top: 1px solid var(--line-strong); border-bottom: 1px solid var(--line-strong); }
.about summary { list-style: none; display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 18px 0; font-weight: 800; font-size: 17px; cursor: pointer; min-height: 44px; }
.about summary::-webkit-details-marker { display: none; }
.about[open] summary .icon { transform: rotate(180deg); }
.about__text { max-width: 720px; line-height: 1.6; color: var(--text); padding-bottom: 20px; }
.about__text p + p { margin-top: 12px; }

.cat-head { align-items: flex-end; }
.mat-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; max-width: 760px; }
.mat-row { display: flex; gap: 16px; align-items: center; padding: 14px; }
.mat-row__photo { width: 84px; height: 72px; border-radius: 10px; background: var(--bg); color: #A9B6CA; display: grid; place-items: center; flex: none; }
.mat-row__title { font-size: 18px; margin-bottom: 4px; }

@media (max-width: 1100px) {
  .group-grid { grid-template-columns: repeat(3, 1fr); }
  .cat-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 860px) {
  .groups-filter { max-width: none; }
  .group-grid { grid-template-columns: 1fr; gap: 10px; }
  .group-card { min-height: 68px; padding: 12px 14px; }
  .tasks-card { grid-template-columns: 1fr; }
  .cat-grid { grid-template-columns: 1fr; gap: 12px; margin-top: 18px; }
  .calc-links { grid-template-columns: 1fr; }
  .cat-card__photo { aspect-ratio: 3 / 1; }
  .mat-row { padding: 12px; gap: 12px; }
  .mat-row__photo { width: 64px; height: 56px; }
  .mat-row__title { font-size: 16px; }
}
