/* Экотех-Баркемп: слой оформления поверх собранного интерфейса (v1).
   Подключается после основного CSS; ничего не меняет в логике. Откат: убрать <link> polish.css из index.html. */

/* ---------- 1. Плавное растягивание и сворачивание чата ---------- */
main.map { transition: grid-template-columns .5s cubic-bezier(.3,.7,.2,1); }
body.resizing main.map { transition: none; }              /* во время перетаскивания — без задержки */
.chat-slot .card-panel.side:not(.is-full) { min-width: 0; overflow: hidden; }
   /* текст не переносится заново в ходе анимации — края просто «открываются» */
.card-panel.side .side-body { transition: opacity .25s ease; }

/* Сворачивание чата: держим три колонки с нулевой первой — тогда ширина анимируется, а не «щёлкает» */
@media (min-width: 1100px) {
  main.map { transition: grid-template-columns .5s cubic-bezier(.3,.7,.2,1), column-gap .5s cubic-bezier(.3,.7,.2,1); }
  main.map.chat-off { grid-template-columns: 64px minmax(0, 1fr) 300px !important; }   /* вместо чата — узкая полоса-«рейл» */
  main.map.chat-off > .chat-slot { display: contents !important; }
  main.map.chat-off > .chat-slot > .card-panel.side:not(.is-full) {
    opacity: 0; visibility: hidden; pointer-events: none; border-width: 0; box-shadow: none; margin: 0;
    transition: opacity .25s ease, visibility 0s linear .5s;
  }
  main.map:not(.chat-off) > .chat-slot > .card-panel.side:not(.is-full) { transition: opacity .35s ease .08s; }
  main.map > section.gp, main.map > aside.pg { transition: none; }
}

/* ---------- 2. Появление блоков ---------- */
@keyframes ht-rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes ht-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes ht-pulse { 0%,100% { box-shadow: 0 0 0 0 rgba(30,90,158,.45); } 60% { box-shadow: 0 0 0 7px rgba(30,90,158,0); } }
section.gp > .block, section.gp > .credits { animation: ht-rise .5s var(--ease) both; }
section.gp > :nth-child(1) { animation-delay: .02s; }
section.gp > :nth-child(2) { animation-delay: .08s; }
section.gp > :nth-child(3) { animation-delay: .14s; }
section.gp > :nth-child(4) { animation-delay: .20s; }
aside.pg { animation: ht-fade .6s ease .1s both; }

/* ---------- 3. Центр: карточки ---------- */
section.gp { gap: 14px; }
section.gp > .block {
  background: #fff; border: 1px solid rgba(20,32,45,.07); border-radius: 20px; padding: 18px 22px;
  box-shadow: 0 1px 2px rgba(20,32,45,.04), 0 14px 34px -22px rgba(20,32,45,.25);
  -webkit-backdrop-filter: none; backdrop-filter: none;
}
section.gp > .block:hover { border-color: rgba(30,90,158,.22); }
.cab-top h3 { font-size: 21px !important; letter-spacing: -.02em; }
.cab-top .gp-hint { font-size: 13.5px; color: var(--muted); }
.cab-top .btn { border-radius: 99px; padding: 9px 16px; font-size: 14px; }
.gp .block h3 { font-size: 16px; }

/* ---------- 4. Прогресс: шаги и охват вопросов ---------- */
.gp .gp-steps { display: flex; align-items: center; gap: 0; margin: 2px 0 16px; }
.gp .gp-step {
  flex: 0 0 auto; display: flex; align-items: center; gap: 9px; padding: 0; border: 0; background: none; border-radius: 0;
  color: var(--muted); font-size: 14px; font-weight: 550; white-space: nowrap; transition: color .3s;
}
.gp .gp-step:not(:last-child) { flex: 1 1 auto; }
.gp .gp-step:not(:last-child)::after {
  content: ""; flex: 1 1 auto; height: 3px; min-width: 14px; margin: 0 12px; border-radius: 3px;
  background: linear-gradient(90deg, var(--green) 0 var(--p, 0%), rgba(20,32,45,.1) var(--p, 0%) 100%); transition: background .5s;
}
.gp .gp-step.done:not(:last-child)::after { --p: 100%; }
.gp .gp-step i {
  width: 30px; height: 30px; flex: none; display: grid; place-items: center; border-radius: 50%; font-style: normal;
  font-size: 13px; font-weight: 650; background: #fff; border: 2px solid rgba(20,32,45,.14); color: var(--muted);
  transition: background .3s, border-color .3s, color .3s, box-shadow .3s;
}
.gp .gp-step.done i { background: var(--green); border-color: var(--green); color: #fff; }
.gp .gp-step.cur i { border-color: var(--green); color: var(--green-deep); box-shadow: 0 0 0 5px var(--green-soft); animation: ht-pulse 2.4s ease-in-out infinite; }
.gp .gp-step.cur, .gp .gp-step.done { color: var(--ink); }
.gp .gp-step, .gp .gp-step.cur, .gp .gp-step.done { border: 0 !important; background: none !important; box-shadow: none !important; padding: 0 !important; }
.gp .gp-guide {
  margin: 0 0 14px; padding: 11px 15px; border-radius: 14px; background: var(--green-soft);
  border: 1px solid var(--green-line); color: var(--ink-2); font-size: 14px; line-height: 1.5;
}
.gp .gp-guide b { color: var(--green-deep); }
.gp .gp-cov-bar { display: flex; gap: 6px; margin: 2px 0 8px; }
.gp .gp-cov-bar b { flex: 1; height: 9px; border-radius: 9px; background: rgba(20,32,45,.09); transition: background .4s; }
.gp .gp-cov-bar b.partial { background: #f0b45a; }
.gp .gp-cov-bar b.answered { background: var(--green); }
.gp .gp-cov small { color: var(--muted); font-size: 13px; }

/* ---------- 5. «Запись и стенограмма»: плавное раскрытие ---------- */
.gp details { interpolate-size: allow-keywords; }
.gp details > summary {
  list-style: none; display: flex; align-items: center; gap: 10px; cursor: pointer; font-size: 15.5px; font-weight: 600;
  padding: 2px 0; user-select: none;
}
.gp details > summary::-webkit-details-marker { display: none; }
.gp details > summary::before {
  content: ""; width: 9px; height: 9px; flex: none; border-right: 2px solid var(--green-deep); border-bottom: 2px solid var(--green-deep);
  transform: rotate(-45deg); transition: transform .35s var(--ease); margin: 0 4px 0 2px;
}
.gp details[open] > summary::before { transform: rotate(45deg) translate(-2px, -2px); }
.gp details > summary:hover { color: var(--green-deep); }
.gp details::details-content {
  height: 0; overflow: clip; opacity: 0;
  transition: height .42s var(--ease), opacity .3s ease, content-visibility .42s allow-discrete;
}
.gp details[open]::details-content { height: auto; opacity: 1; }
.gp details[open] > div { animation: ht-rise .45s var(--ease) both; }      /* запасной вариант для браузеров без ::details-content */

/* ---------- 6. Кнопки ---------- */
.gp .btn { border-radius: 12px; }
.gp .btn-primary { padding: 11px 20px; font-size: 14.5px; }
.gp .btn:disabled, .btn.btn-primary:disabled { opacity: .45; filter: saturate(.55); cursor: not-allowed; box-shadow: none; transform: none; }
.gp .btn-ghost:disabled { background: transparent; }

/* ---------- 7. Правая панель ---------- */
aside.pg {
  background: #fff; border: 1px solid rgba(20,32,45,.07); border-radius: 20px; padding: 18px 16px 16px;
  box-shadow: 0 1px 2px rgba(20,32,45,.04), 0 14px 34px -22px rgba(20,32,45,.25); scrollbar-width: thin;
}
aside.pg .pg-head { font-size: 11.5px; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; color: var(--muted); margin: 0 2px 6px; }
aside.pg .gs-title { align-items: center; margin: 0 2px 12px; }
aside.pg .gs-title b { font-family: var(--font-display); font-size: 19px; letter-spacing: -.02em; line-height: 1.25; }
aside.pg .gs-title .lnk { color: var(--muted); font-size: 12.5px; text-decoration: none; border-bottom: 1px dashed currentColor; background: none; flex: none; }
aside.pg .gs-title .lnk:hover { color: var(--green-deep); }
aside.pg .pg-dt { display: flex; align-items: center; gap: 10px; font-size: 11.5px; letter-spacing: .09em; color: var(--green-deep); margin: 14px 2px 8px; }
aside.pg .pg-dt::after { content: ""; flex: 1; height: 1px; background: rgba(20,32,45,.09); }
aside.pg .gs-people {
  display: flex; flex-direction: column; gap: 2px; margin: 0 -6px 10px; padding: 0 6px 0 0; max-height: 36vh; overflow-y: auto; scrollbar-width: thin;
  -webkit-mask-image: linear-gradient(#000 calc(100% - 26px), transparent); mask-image: linear-gradient(#000 calc(100% - 26px), transparent);
}
aside.pg .gs-people li {
  display: grid; grid-template-columns: 34px 1fr; column-gap: 11px; align-items: center; padding: 6px 8px; border-radius: 12px;
  font-size: 13.5px; font-weight: 600; line-height: 1.3; color: var(--ink); transition: background .2s;
}
aside.pg .gs-people li:hover { background: rgba(30,90,158,.07); }
aside.pg .gs-people li::before {
  content: attr(data-i); grid-row: 1 / span 2; width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center;
  font-size: 12.5px; font-weight: 700; letter-spacing: .02em; background: hsl(var(--h,212) 42% 90%); color: hsl(var(--h,212) 45% 26%);
}
aside.pg .gs-people li small { display: block; font-size: 12px; font-weight: 400; color: var(--muted); line-height: 1.3; margin-top: 1px; }
aside.pg .pg-board { width: 100%; border-radius: 12px; margin-bottom: 4px; }
aside.pg .pg-item { position: relative; padding: 8px 10px 8px 26px; margin: 0; border-radius: 10px; }
aside.pg .pg-item::before {
  content: ""; position: absolute; left: 6px; top: 13px; width: 10px; height: 10px; border-radius: 50%; background: #fff;
  border: 2px solid rgba(20,32,45,.18); z-index: 1; transition: background .3s, border-color .3s;
}
aside.pg .pg-item::after { content: ""; position: absolute; left: 10px; top: 25px; bottom: -9px; width: 2px; background: rgba(20,32,45,.09); }
aside.pg .pg-item:last-child::after { display: none; }
aside.pg .pg-item.cur::before, aside.pg .pg-item.on::before { background: var(--green); border-color: var(--green); }
aside.pg .pg-item.cur::before { animation: ht-pulse 2.4s ease-in-out infinite; }
aside.pg .pg-item.cur { background: var(--green-soft); border-color: transparent; }
aside.pg .pg-item .pg-t { font-size: 13.5px; font-weight: 550; }
aside.pg .pg-item .pg-m { font-size: 12px; }

/* ---------- 8. Кнопка «Материалы группы» в шапке ---------- */
a.ht-mat {
  display: inline-flex; align-items: center; gap: 8px; height: 34px; padding: 0 14px 0 11px; border-radius: 99px; white-space: nowrap;
  background: var(--green-soft); border: 1px solid var(--green-line); color: var(--green-deep); font: 600 13.5px/1 var(--font-display, Onest, sans-serif);
  text-decoration: none; transition: background .2s, border-color .2s, transform .2s var(--ease), box-shadow .2s;
}
a.ht-mat svg { flex: none; }
a.ht-mat:hover { background: #fff; border-color: var(--green); transform: translateY(-1px); box-shadow: 0 6px 16px -6px rgba(30,90,158,.5); }
@media (max-width: 760px) { a.ht-mat span { display: none; } a.ht-mat { padding: 0 10px; } }

/* ---------- 9. Чат: аккуратнее ---------- */
.card-panel.side .side-head { background: linear-gradient(90deg, var(--sp-soft), transparent 75%); }
.card-panel.side .quick button { border-radius: 14px; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

/* ---------- Исправления: кнопка загрузки аудио, прокрутка страницы над блоком записи ---------- */
.gp .gp-upl .btn {
  background: var(--green-soft); border: 1px solid var(--green-line); color: var(--green-deep); font-weight: 600; padding: 9px 16px;
}
.gp .gp-upl .btn::before {
  content: ""; width: 16px; height: 16px; flex: none; background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 16V4M7 9l5-5 5 5M4 20h16'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 16V4M7 9l5-5 5 5M4 20h16'/%3E%3C/svg%3E") center / contain no-repeat;
}
.gp .gp-upl .btn:hover { background: #fff; border-color: var(--green); }
.gp .modes-page, .gp .modes-body { overscroll-behavior: auto; }   /* колесо мыши прокручивает страницу, а не застревает в блоке */

.gp .gp-upl { margin-bottom: 14px; gap: 12px; }

/* Кнопка «Загрузить аудио»: насыщенная заливка, чтобы не сливалась с белой карточкой */
.gp .gp-upl > button, .gp .gp-upl > .btn, .gp .gp-upl > label.btn {
  background: #d6e2ef !important; border: 1.5px solid var(--green) !important; color: #0f3a6b !important;
  box-shadow: none !important; -webkit-backdrop-filter: none !important; backdrop-filter: none !important;
}
.gp .gp-upl > button:hover, .gp .gp-upl > .btn:hover { background: var(--green) !important; color: #fff !important; }

/* =====================================================================
   v2 — редизайн кабинета группы: шапка-герой, шаги-таблетки, подсказка, состав
   ===================================================================== */

/* ---- Шапка-герой с фотографией ---- */
section.gp > .block.cab {
  position: relative; overflow: hidden; padding: 0; min-height: 178px; display: flex; border: 0;
  background: #fff url(/hero-v2.webp) right 62% / cover no-repeat;
  box-shadow: 0 1px 2px rgba(20,32,45,.05), 0 18px 40px -24px rgba(20,39,60,.35);
}
section.gp > .block.cab::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(90deg, #fff 0%, rgba(255,255,255,.97) 32%, rgba(255,255,255,.72) 48%, rgba(255,255,255,.12) 74%, rgba(255,255,255,0) 100%);
}
section.gp > .block.cab:hover { border: 0; }
.cab .cab-top { position: relative; z-index: 1; width: 100%; padding: 22px 26px 20px; align-items: flex-end; justify-content: space-between; gap: 16px; }
.cab .cab-top > div:first-child { min-width: 0; }
.cab .cab-top > div:first-child::before {
  content: "ЦМС · 28–29.10"; display: inline-flex; align-items: center; gap: 7px; height: 26px; padding: 0 12px 0 9px; border-radius: 99px;
  background: var(--green-soft); color: var(--green-deep); font: 700 11.5px/1 var(--font-display, Onest, sans-serif); letter-spacing: .06em;
}
.cab .cab-top > div:first-child::after { content: none; }
.cab h3 { font-size: 31px !important; font-weight: 650; letter-spacing: -.035em !important; line-height: 1.12; margin: 12px 0 4px !important; }
.cab .gp-hint { font-size: 14px !important; color: var(--ink-2) !important; margin: 0 !important; }
.cab .cab-top > .btn {
  background: rgba(255,255,255,.78); -webkit-backdrop-filter: blur(12px) saturate(1.3); backdrop-filter: blur(12px) saturate(1.3);
  border: 1px solid rgba(255,255,255,.95); box-shadow: 0 6px 20px -8px rgba(20,39,60,.35); color: var(--ink); font-weight: 600; flex: none;
}
.cab .cab-top > .btn:hover { background: #fff; color: var(--green-deep); }
.ht-av { display: flex; align-items: center; margin-top: 14px; }
.ht-av-i {
  width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; margin-left: -8px; font-size: 11px; font-weight: 700;
  background: hsl(var(--h,212) 42% 90%); color: hsl(var(--h,212) 45% 26%); border: 2px solid #fff; box-shadow: 0 2px 6px rgba(20,32,45,.12);
}
.ht-av-i:first-child { margin-left: 0; }
.ht-av-more { margin-left: 10px; font-size: 13px; color: var(--ink-2); }
@media (max-width: 900px) {
  section.gp > .block.cab::before { background: linear-gradient(90deg, #fff 0%, rgba(255,255,255,.94) 55%, rgba(255,255,255,.35) 100%); }
  .cab h3 { font-size: 24px !important; }
}

/* ---- Шаги: текущий — заметная таблетка ---- */
.gp .gp-step.cur { background: var(--green-soft) !important; padding: 4px 16px 4px 4px !important; border-radius: 99px !important; }
.gp .gp-step.cur i { animation: none; box-shadow: none; background: var(--green); border-color: var(--green); color: #fff; }
.gp .gp-step.cur span { font-weight: 650; color: var(--green-deep); }
.gp .gp-step.cur:not(:last-child)::after { margin-left: 12px; }

/* ---- Подсказка «Что делать» с иконкой ---- */
.gp .gp-guide { position: relative; padding: 13px 16px 13px 50px; }
.gp .gp-guide::before {
  content: ""; position: absolute; left: 16px; top: 50%; width: 22px; height: 22px; transform: translateY(-50%); background: var(--green);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 18h6M10 21h4M12 3a6 6 0 0 0-3.6 10.8c.7.6 1.1 1.4 1.1 2.2h5c0-.8.4-1.6 1.1-2.2A6 6 0 0 0 12 3z'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 18h6M10 21h4M12 3a6 6 0 0 0-3.6 10.8c.7.6 1.1 1.4 1.1 2.2h5c0-.8.4-1.6 1.1-2.2A6 6 0 0 0 12 3z'/%3E%3C/svg%3E") center / contain no-repeat;
}

/* ---- «Запись и стенограмма»: иконка слева, стрелка справа ---- */
.gp details > summary { font-size: 17px; font-family: var(--font-display, Onest, sans-serif); letter-spacing: -.01em; padding: 4px 0; }
.gp details > summary::before {
  content: ""; width: 24px; height: 24px; margin: 0; border: 0; transform: none; background: var(--green); flex: none;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M4 10v4M8 6v12M12 3v18M16 8v8M20 11v2'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M4 10v4M8 6v12M12 3v18M16 8v8M20 11v2'/%3E%3C/svg%3E") center / contain no-repeat;
  transition: none;
}
.gp details[open] > summary::before { transform: none; }
.gp details > summary::after {
  content: ""; margin-left: auto; width: 9px; height: 9px; border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted);
  transform: rotate(45deg) translate(-2px, -2px); transition: transform .35s var(--ease), border-color .2s;
}
.gp details[open] > summary::after { transform: rotate(-135deg) translate(-2px, -2px); border-color: var(--green-deep); }
.gp details > summary:hover::after { border-color: var(--green-deep); }

/* ---- Состав группы: свёрнутый список ---- */
aside.pg .gs-people.ht-fold { max-height: none; overflow: visible; -webkit-mask-image: none; mask-image: none; margin-bottom: 2px; }
aside.pg .gs-people.ht-fold li:nth-child(n+7) { display: none; }
#ht-fold {
  display: block; width: 100%; text-align: left; margin: 0 0 10px; padding: 7px 8px; border: 0; background: none; cursor: pointer;
  font: 600 13px/1.2 var(--font-display, Onest, sans-serif); color: var(--green-deep); border-radius: 10px; transition: background .2s;
}
#ht-fold:hover { background: var(--green-soft); }
aside.pg .gs-people li { animation: ht-fade .35s ease both; }

/* ---- Карточки и ритм ---- */
section.gp > .block:not(.cab) { border-radius: 22px; }
aside.pg { border-radius: 22px; }

/* ---- Узкие экраны: компактный степпер и шапка ---- */
@media (max-width: 640px) {
  .gp .gp-steps { flex-wrap: nowrap; justify-content: space-between; }
  .gp .gp-step:not(.cur) span { display: none; }
  .gp .gp-step:not(:last-child)::after { min-width: 10px; margin: 0 7px; }
  .gp .gp-step.cur { padding-right: 14px !important; }
  .top .brand { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  section.gp > .block { padding-left: 16px; padding-right: 16px; }
  .cab .cab-top { padding: 18px 18px 16px; }
}

/* ---- Исправление: раскрытый состав группы не должен ломать шапку ---- */
section.gp > .block.cab { display: block; min-height: 0; background: #fff; padding: 0; }
section.gp > .block.cab::before { content: none; }
.cab .cab-top {
  position: relative; overflow: hidden; min-height: 178px; width: auto;
  background: #fff url(/hero-v2.webp) right 62% / cover no-repeat;
}
.cab .cab-top::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(90deg, #fff 0%, rgba(255,255,255,.97) 32%, rgba(255,255,255,.72) 48%, rgba(255,255,255,.12) 74%, rgba(255,255,255,0) 100%);
}
.cab .cab-top > * { position: relative; z-index: 1; }
.cab .cab-body { position: relative; padding: 18px 26px 22px; border-top: 1px solid rgba(20,32,45,.08); background: #fff; }
@media (max-width: 900px) {
  .cab .cab-top::before { background: linear-gradient(90deg, #fff 0%, rgba(255,255,255,.94) 55%, rgba(255,255,255,.35) 100%); }
}

/* ---- Редактор состава внутри шапки ---- */
.cab .cab-ros { margin: 0 !important; padding: 16px 26px 22px; background: #fff; border-top: 1px solid rgba(20,32,45,.08); animation: ht-rise .4s var(--ease) both; }
.cab .cab-ros > .gp-hint { margin: 0 0 12px; font-size: 13.5px; }
.cab .roster { max-height: 58vh; overflow-y: auto; overscroll-behavior: auto; padding-right: 4px; scrollbar-width: thin; }
.cab .ro-row { grid-template-columns: minmax(0, 1.5fr) minmax(0, 1.4fr) minmax(0, 1.2fr) minmax(0, .9fr) 40px; gap: 8px; align-items: center; margin-bottom: 8px; }
.cab .ro-row.ro-head { position: sticky; top: 0; z-index: 2; background: #fff; padding-bottom: 4px; margin-bottom: 4px; font-size: 12px; color: var(--muted); font-weight: 600; }
.cab .ro-row .inp { min-width: 0; width: 100%; height: 38px; padding: 0 12px; font-size: 14px; border-radius: 10px; }
.cab .ro-row .btn { height: 38px; padding: 0; width: 40px; }
.cab .cab-ros .gp-actions { margin-top: 14px; }
@media (max-width: 760px) {
  .cab .ro-row { grid-template-columns: 1fr 1fr 40px; }
  .cab .ro-row.ro-head { display: none; }
}

/* блоки кабинета не сжимаются: прокручивается колонка, а не обрезается содержимое */
section.gp > * { flex-shrink: 0; }

/* =====================================================================
   v3 — «Запись и стенограмма»: плоский блок вместо вложенной карточки
   ===================================================================== */
@keyframes ht-rec { 0%,100% { box-shadow: 0 0 0 0 rgba(217,83,111,.55); } 60% { box-shadow: 0 0 0 7px rgba(217,83,111,0); } }

/* убираем лишние слои: полоску «группа / моя», вкладку из одной «Запись», рамки и тени вложенной панели */
.gp details aside.card-panel.modes { background: transparent; border: 0 !important; box-shadow: none; border-radius: 0; overflow: visible; }
.gp details aside.card-panel.modes::before { content: none !important; }
.gp details .space-strip,
.gp details .modes-nav:has(> button:only-child) { display: none; }
.gp details .modes-body, .gp details .modes-page { height: auto; overflow: visible; }
.gp details .modes-page { padding: 0; }
.gp details .tab-stack { padding: 0; gap: 16px; }

/* панель загрузки аудио */
.gp .gp-upl { margin: 2px 0 14px; padding: 0; }
.gp .gp-upl .gp-hint { font-size: 13px; color: var(--muted); }

/* карточка записи: статус, «Кто говорит» и кнопка в одну строку */
.gp details .rec-card {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: 14px; row-gap: 12px; align-items: end;
  padding: 18px 20px; border-radius: 20px; border: 1px solid rgba(20,32,45,.08);
  background: linear-gradient(180deg, #f4f7fa, #fff 70%); box-shadow: none; -webkit-backdrop-filter: none; backdrop-filter: none;
}
.gp details .rec-card.is-live { background: linear-gradient(180deg, #fff3f4, #fff 70%); border-color: #f4cdd3; }
.gp details .rec-card > * { grid-column: 1 / -1; margin: 0; }
.gp details .rec-card > .fld-inline { grid-column: 1; }
.gp details .rec-card > .rec-btn.btn-primary,
.gp details .rec-card > .rec-btn.btn-danger { grid-column: 2; width: auto; min-width: 190px; height: 46px; padding: 0 22px; margin: 0; border-radius: 14px; }
.gp details .rec-card > .rec-btn.btn-ghost { grid-column: 1 / -1; width: 100%; height: 42px; }
.gp details .rec-card .rec-state { justify-content: flex-start; gap: 12px; margin: 0; }
.gp details .rec-badge {
  display: inline-flex; align-items: center; gap: 9px; height: 30px; padding: 0 14px 0 11px; border-radius: 99px;
  background: #eef0f2; color: var(--ink-2); font-size: 13.5px; font-weight: 650;
}
.gp details .rec-badge::before { content: ""; width: 10px; height: 10px; border-radius: 50%; background: #aab7ab; flex: none; }
.gp details .rec-badge.live { background: #fde8eb; color: #b3263e; }
.gp details .rec-badge.live::before { background: #d9536f; animation: ht-rec 1.4s ease-in-out infinite; }
.gp details .rec-card .fld-inline span { font-size: 12.5px; font-weight: 600; color: var(--muted); }
.gp details .rec-card .fld-inline .inp { height: 46px; border-radius: 14px; background: #fff; }
.gp details .rec-card .hint { font-size: 12.5px; line-height: 1.5; color: var(--muted); padding-top: 2px; }
.gp details .rec-card .live-line { border-radius: 14px; }
@media (max-width: 720px) {
  .gp details .rec-card { grid-template-columns: 1fr; }
  .gp details .rec-card > .rec-btn.btn-primary, .gp details .rec-card > .rec-btn.btn-danger { grid-column: 1; width: 100%; }
}

/* стенограмма: карточки реплик */
.gp details .tab-stack > .block {
  padding: 18px 20px; border-radius: 20px; border: 1px solid rgba(20,32,45,.08); background: #fff; box-shadow: none;
  -webkit-backdrop-filter: none; backdrop-filter: none;
}
.gp details .tab-stack > .block.grow h3 { font-size: 16px; margin-bottom: 12px; }
.gp details .tab-stack > .block.grow h3::before {
  content: ""; width: 22px; height: 22px; flex: none; background: var(--green);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M14 3H7a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2V8z'/%3E%3Cpath d='M14 3v5h5M9 13h6M9 17h6'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M14 3H7a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2V8z'/%3E%3Cpath d='M14 3v5h5M9 13h6M9 17h6'/%3E%3C/svg%3E") center / contain no-repeat;
}
.gp .transcript.ts-scroll { max-height: min(58vh, 540px); min-height: 0; padding-right: 6px; scrollbar-width: thin; overscroll-behavior: auto; scroll-behavior: smooth; }
.gp .ts-line {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: 12px; padding: 13px 16px; margin-bottom: 10px;
  border: 1px solid rgba(20,32,45,.06); border-radius: 16px; background: #f8f9fa; animation: ht-rise .35s var(--ease) both;
}
.gp .ts-line:first-child { border-top: 1px solid rgba(20,32,45,.06); }
.gp .ts-line > div { grid-column: 1; grid-row: 1; min-width: 0; }
.gp .ts-line > time { grid-column: 2; grid-row: 1; padding-top: 3px; font-size: 12.5px; color: var(--muted); }
.gp .ts-line b {
  display: table; margin-bottom: 7px; padding: 3px 11px; border-radius: 99px; background: var(--green-soft); color: var(--green-deep);
  font-size: 12.5px; font-weight: 650;
}
.gp .ts-line p { font-size: 14.5px; line-height: 1.6; color: var(--ink); }
.gp .ts-scroll.is-empty .hint { font-size: 13.5px; color: var(--muted); }

/* =====================================================================
   v4 — плавное растягивание чата мышью
   ===================================================================== */
/* пока тянем: ширина догоняет курсор короткой анимацией, а не прыгает по пикселям */
body.resizing main.map { transition: none; }          /* ширину ведёт скрипт с плавным сглаживанием (extras.js), колонка и ручка движутся вместе */
body.resizing .chat-slot .card-panel.side,
body.resizing section.gp { user-select: none; }
body.resizing .chat-slot .card-panel.side .side-body { scroll-behavior: auto; }

/* перенос текста меняется спокойнее: без одиноких слов в конце строки и «болтанки» заголовков */
.chat-slot .msg-text, .chat-slot .msg-text p, .chat-slot .hello p, .chat-slot .hello-note, .chat-slot .quick button { text-wrap: pretty; }
.chat-slot .hello h2, .chat-slot .side-head-txt b { text-wrap: balance; }

/* перерасчёт вёрстки одной колонки не затрагивает остальные */
.chat-slot .card-panel.side { contain: layout style; }
.chat-slot .card-panel.side .side-body { overflow-x: hidden; }
.chat-slot .card-panel.side .msg-text, .chat-slot .card-panel.side .hello-note { overflow-wrap: anywhere; }

/* ручка растягивания: плавно реагирует на наведение */
.resize-handle { transition: opacity .2s ease; }
.resize-handle:hover:after, body.resizing .resize-handle:after { opacity: 1; background: var(--green); width: 5px; transition: opacity .2s ease, width .2s ease, background .2s ease; }

/* =====================================================================
   v5 — глифы и окно чата при растягивании
   ===================================================================== */
.ht-gl { display: inline-grid; place-items: center; flex: none; position: relative; line-height: 0; }
.ht-gl svg { display: block; filter: drop-shadow(0 6px 10px rgba(20,39,60,.22)); }

/* знак ИИ вместо плитки с иконкой в шапке чата и в приветствии */
.side-head-ic { background: transparent !important; box-shadow: none !important; width: 38px !important; height: 38px !important; }
.side-head-ic > svg, .hello-ic > svg { display: none; }
.hello-ic { background: transparent !important; box-shadow: none !important; width: 56px !important; height: 56px !important; }
.is-full .hello-ic { width: 72px !important; height: 72px !important; }

/* свёрнутый чат: язычок со знаком ИИ вместо эмодзи */
.chat-tab:not(.on) { font-size: 0; overflow: visible; background: #fff; }
.chat-tab:not(.on) .ht-gl { position: absolute; inset: 0; margin: auto; transform: scale(.9); transition: transform .25s var(--ease); }
.chat-tab:not(.on):hover .ht-gl { transform: scale(1.08); }

aside.pg .gs-title { justify-content: space-between; }
aside.pg .gs-title b { flex: 1; min-width: 0; }

/* окно чата при растягивании: поверх страницы, страница не перестраивается; потом плавно подстраивается */
main.map.ht-dragging .chat-slot .card-panel.side { box-shadow: 0 32px 70px -26px rgba(20,32,45,.5), 0 0 0 1px rgba(30,90,158,.18); transition: box-shadow .2s ease; }
main.map.ht-dragging { user-select: none; }
body.resizing main.map.ht-settle, main.map.ht-settle { transition: grid-template-columns .5s cubic-bezier(.3, .7, .2, 1), column-gap .5s ease; }

/* =====================================================================
   v6 — свёрнутый чат: заметная полоса-рейл с подсказкой (по образцу сворачиваемых панелей СФУ/CSR)
   ===================================================================== */
@media (min-width: 1100px) {
  main.map.chat-off > .chat-tab:not(.on) {
    position: absolute; left: 14px; top: var(--ht-pt, 14px); bottom: 14px; width: 64px; height: auto; transform: none; z-index: 30;
    display: flex; flex-direction: column; align-items: center; justify-content: flex-start; gap: 14px; padding: 18px 0 14px;
    border-radius: 22px; border: 1px solid rgba(20,32,45,.08); background: linear-gradient(180deg, #eef3f8, #fff 62%);
    box-shadow: 0 1px 2px rgba(20,32,45,.04), 0 14px 34px -22px rgba(20,32,45,.3); font-size: 0; overflow: visible; cursor: pointer;
    animation: ht-fade .45s ease .25s both; transition: border-color .2s, box-shadow .25s, background .25s;
  }
  main.map.chat-off > .chat-tab:not(.on):hover { border-color: var(--green); box-shadow: 0 1px 2px rgba(20,32,45,.04), 0 18px 40px -20px rgba(30,90,158,.5); background: linear-gradient(180deg, #e3ebf4, #fff 62%); }
  main.map.chat-off > .chat-tab:not(.on) .ht-gl { position: static; inset: auto; margin: 0; transform: none; order: 1; }
  main.map.chat-off > .chat-tab:not(.on):hover .ht-gl { transform: scale(1.1); }
  /* вертикальная подпись */
  main.map.chat-off > .chat-tab:not(.on)::after {
    content: "ИИ-чат группы"; order: 2; writing-mode: vertical-rl; transform: rotate(180deg); margin-top: 6px;
    font: 600 13.5px/1 var(--font-display, Onest, sans-serif); letter-spacing: .05em; color: var(--ink-2); white-space: nowrap;
  }
  /* круглая кнопка-стрелка внизу: «развернуть» */
  main.map.chat-off > .chat-tab:not(.on)::before {
    content: ""; order: 3; margin-top: auto; width: 34px; height: 34px; border-radius: 50%; flex: none;
    background: var(--green) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 5l7 7-7 7'/%3E%3C/svg%3E") center / 15px no-repeat;
    box-shadow: 0 6px 16px -6px rgba(30,90,158,.7); transition: transform .25s var(--ease), box-shadow .25s;
  }
  main.map.chat-off > .chat-tab:not(.on):hover::before { transform: translateX(3px); box-shadow: 0 8px 20px -6px rgba(30,90,158,.9); }
}

/* подсказка при наведении (для свёрнутого и для открытого состояния) */
.chat-tab .ht-tip {
  position: absolute; left: calc(100% + 10px); top: 50%; transform: translate(-4px, -50%); padding: 6px 11px; border-radius: 9px; white-space: nowrap;
  background: #101a26; color: #fff; font: 600 12.5px/1.2 var(--font-display, Onest, sans-serif); opacity: 0; pointer-events: none; font-size: 12.5px;
  transition: opacity .18s ease, transform .22s var(--ease); z-index: 60;
}
.chat-tab:hover .ht-tip, .chat-tab:focus-visible .ht-tip { opacity: 1; transform: translate(0, -50%); }
main.map:not(.chat-off) > .chat-tab.on .ht-tip { left: calc(100% + 8px); }

/* кнопка «свернуть» на границе открытого чата: круглая, со стрелкой, при наведении заливается */
.chat-tab.on {
  width: 28px; height: 28px; font-size: 17px; line-height: 1; padding: 0 0 2px; color: var(--ink-2); background: #fff;
  border: 1px solid rgba(20,32,45,.16); box-shadow: 0 2px 8px -2px rgba(20,32,45,.28);
  transition: background .2s, color .2s, border-color .2s, transform .25s var(--ease), box-shadow .2s;
}
.chat-tab.on:hover { background: var(--green); color: #fff; border-color: var(--green); transform: scale(1.1); box-shadow: 0 6px 16px -6px rgba(30,90,158,.7); }

/* знак ИИ в свёрнутой полосе крупнее */
main.map.chat-off > .chat-tab:not(.on) .ht-gl { width: 46px !important; height: 46px !important; }
main.map.chat-off > .chat-tab:not(.on) .ht-gl svg { width: 46px; height: 46px; }

/* =====================================================================
   v7 — открытие/закрытие чата как «занавес»: текст не перестраивается, кнопка «свернуть» — в шапке чата
   ===================================================================== */
/* содержимое чата всегда лежит в полной ширине (--chat-w), а колонка просто открывает/закрывает его — текст не прыгает */
.chat-slot .card-panel.side:not(.is-full) > * { width: var(--chat-w, 360px); min-width: 260px; flex-shrink: 0; }
/* пока тянем границу мышью или сразу после отпускания — содержимое следует за шириной окна */
main.map.ht-dragging .chat-slot .card-panel.side > *,
main.map.ht-settle .chat-slot .card-panel.side > * { width: 100%; }
/* мягкий выезд слева вместе с появлением */
@media (min-width: 1100px) {
  main.map.chat-off > .chat-slot > .card-panel.side:not(.is-full) { transform: translateX(-22px); }
  main.map:not(.chat-off) > .chat-slot > .card-panel.side:not(.is-full) { transform: none; transition: opacity .4s ease .06s, transform .55s cubic-bezier(.22, 1, .36, 1); }
  main.map.chat-off > .chat-slot > .card-panel.side:not(.is-full) { transition: opacity .22s ease, transform .4s cubic-bezier(.4, 0, 1, 1), visibility 0s linear .5s; }
}

/* плавающая кнопка на границе больше не нужна: управление — в шапке чата */


/* иконка «свернуть чат» в шапке */
.side-head .ht-collapse { position: relative; color: var(--ink-2); }
.side-head .ht-collapse svg { width: 18px; height: 18px; transition: transform .3s var(--ease); }
.side-head .ht-collapse:hover { color: var(--green-deep); }
.side-head .ht-collapse:hover svg { transform: translateX(-2px); }
.is-full .side-head .ht-collapse { display: none; }
.side-head .ht-collapse::after {
  content: attr(data-tip); position: absolute; top: calc(100% + 8px); right: -4px; padding: 6px 11px; border-radius: 9px; white-space: nowrap;
  background: #101a26; color: #fff; font: 600 12.5px/1.2 var(--font-display, Onest, sans-serif); opacity: 0; transform: translateY(-3px);
  pointer-events: none; transition: opacity .18s ease, transform .22s var(--ease); z-index: 80;
}
.side-head .ht-collapse:hover::after, .side-head .ht-collapse:focus-visible::after { opacity: 1; transform: none; }

/* =====================================================================
   v8 — компактная шапка чата, без «озвучивания»; переключатель чата — в верхней панели
   ===================================================================== */
.side-head .voice-toggle { display: none !important; }                 /* «Озвучивать ответы ИИ» убрано */
.side-head .ht-collapse { display: none !important; }                  /* иконка в шапке чата не нужна */
.card-panel.side .side-head { align-items: center; gap: 10px; padding: 14px 14px 12px; }
.card-panel.side .side-head-txt { min-width: 0; }
.card-panel.side .side-head-txt b {
  display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; font-size: 15px; line-height: 1.25; text-wrap: balance;
}
.card-panel.side .side-head-txt i { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 12.5px; }

/* переключатель чата в верхней панели */
#ht-chat-toggle {
  position: relative; display: inline-flex; align-items: center; gap: 8px; height: 34px; padding: 0 14px 0 11px; border-radius: 99px; cursor: pointer; white-space: nowrap;
  border: 1px solid rgba(20,32,45,.14); background: #fff; color: var(--ink-2); font: 600 13.5px/1 var(--font-display, Onest, sans-serif);
  transition: background .2s, border-color .2s, color .2s, box-shadow .2s, transform .2s var(--ease);
}
#ht-chat-toggle svg { width: 17px; height: 17px; flex: none; transition: transform .3s var(--ease); }
#ht-chat-toggle:hover { border-color: var(--green); color: var(--green-deep); transform: translateY(-1px); box-shadow: 0 6px 16px -8px rgba(30,90,158,.55); }
#ht-chat-toggle.is-on { background: var(--green-soft); border-color: var(--green-line); color: var(--green-deep); }
#ht-chat-toggle.is-on svg .pl { transform: translateX(0); }
#ht-chat-toggle::after {
  content: attr(data-tip); position: absolute; top: calc(100% + 9px); left: 50%; transform: translate(-50%, -3px); padding: 6px 11px; border-radius: 9px; white-space: nowrap;
  background: #101a26; color: #fff; font: 600 12.5px/1.2 var(--font-display, Onest, sans-serif); opacity: 0; pointer-events: none; transition: opacity .18s ease, transform .22s var(--ease); z-index: 90;
}
#ht-chat-toggle:hover::after, #ht-chat-toggle:focus-visible::after { opacity: 1; transform: translate(-50%, 0); }
@media (max-width: 1099px) { #ht-chat-toggle { display: none; } }

/* =====================================================================
   v10 — «свернуть чат»: небольшой выступ за правым краем чата (в зазоре между чатом и центром), ничего не перекрывает
   ===================================================================== */
#ht-chat-toggle { display: none !important; }                        /* кнопки в верхней панели нет */
@media (min-width: 1100px) {
  main.map > .chat-tab.on {
    display: grid !important; place-items: center; z-index: 70 !important;
    top: calc(var(--ht-pt, 14px) + 20px) !important; width: 16px; height: 44px; margin-left: 20px; padding: 0; font-size: 0; line-height: 0; cursor: pointer;
    border: 1px solid rgba(20,32,45,.2); border-left: 0; border-radius: 0 11px 11px 0;
    background: #fff; color: #5b6c5f; box-shadow: 0 6px 14px -8px rgba(20,32,45,.35);
    transition: width .22s var(--ease), background .2s ease, border-color .2s ease, box-shadow .2s ease;
  }
  main.map > .chat-tab.on::before {
    content: ""; width: 10px; height: 10px; background: currentColor;
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M15 5l-7 7 7 7'/%3E%3C/svg%3E") center / contain no-repeat;
            mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M15 5l-7 7 7 7'/%3E%3C/svg%3E") center / contain no-repeat;
    transition: transform .22s var(--ease);
  }
  main.map > .chat-tab.on:hover {
    width: 22px; background: var(--green); border-color: var(--green); color: #fff; transform: none;
    box-shadow: 0 8px 18px -8px rgba(30,90,158,.8);
  }
  main.map > .chat-tab.on:hover::before { transform: translateX(-1px); }
  main.map > .chat-tab.on .ht-tip { left: calc(100% + 10px); }
}

/* =====================================================================
   v11 — запись проще: без поля «Кто говорит» и без пояснения; говорящий подставляется сам (название группы)
   ===================================================================== */
.gp details .rec-card .fld-inline,
.gp details .rec-card > .hint { display: none !important; }
.gp details .rec-card { grid-template-columns: minmax(0, 1fr) auto; align-items: center; row-gap: 12px; }
.gp details .rec-card .rec-state { grid-column: 1; grid-row: 1; }
.gp details .rec-card > .rec-btn.btn-primary,
.gp details .rec-card > .rec-btn.btn-danger { grid-column: 2; grid-row: 1; margin: 0; }
@media (max-width: 720px) {
  .gp details .rec-card { grid-template-columns: 1fr; }
  .gp details .rec-card .rec-state, .gp details .rec-card > .rec-btn.btn-primary, .gp details .rec-card > .rec-btn.btn-danger { grid-column: 1; grid-row: auto; }
}

/* =====================================================================
   v12 — по референсу: карточка записи, «Задачи группы», «Показать полностью»
   ===================================================================== */

/* --- карточка записи: круглый значок, название группы, статус; кнопка справа --- */
.gp details .rec-card { grid-template-columns: 56px minmax(0, 1fr) auto; column-gap: 16px; align-items: center; padding: 18px 20px; }
.gp details .rec-card::before {
  content: ""; grid-column: 1; grid-row: 1; width: 56px; height: 56px; border-radius: 50%; background-color: var(--green-soft);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%231e5a9e' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M4 10v4M8 6v12M12 3v18M16 8v8M20 11v2'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: center; background-size: 26px; box-shadow: inset 0 0 0 1px rgba(30,90,158,.15);
}
.gp details .rec-card.is-live::before { background-color: #fde8eb; box-shadow: inset 0 0 0 1px rgba(217,83,111,.25); animation: ht-rec 1.6s ease-in-out infinite; }
.gp details .rec-card .rec-state { grid-column: 2; grid-row: 1; flex-direction: column; align-items: flex-start; gap: 4px; }
.gp details .rec-card .rec-state .scope-tag { order: 1; background: none; border: 0; padding: 0; font: 650 16px/1.3 var(--font-display, Onest, sans-serif); color: var(--ink); max-width: 100%; }
.gp details .rec-card .rec-state .scope-tag .scope-dot { display: none; }
.gp details .rec-card .rec-state .rec-badge { order: 2; height: auto; padding: 0; background: none; font-size: 13.5px; font-weight: 500; color: var(--muted); gap: 7px; }
.gp details .rec-card .rec-state .rec-badge::before { width: 8px; height: 8px; }
.gp details .rec-card .rec-state .rec-badge.live { color: #b3263e; background: none; }
.gp details .rec-card > .rec-btn.btn-primary, .gp details .rec-card > .rec-btn.btn-danger { grid-column: 3; grid-row: 1; }
.gp details .rec-card > .rec-btn.btn-primary { background: linear-gradient(160deg, #1f538f, #143d6b); box-shadow: 0 10px 22px -10px rgba(20,61,107,.8); }
@media (max-width: 720px) {
  .gp details .rec-card { grid-template-columns: 56px 1fr; }
  .gp details .rec-card > .rec-btn.btn-primary, .gp details .rec-card > .rec-btn.btn-danger { grid-column: 1 / -1; grid-row: 2; width: 100%; }
}

/* --- реплики: «Показать полностью» --- */
.gp .ts-line:not(.ht-open) p { display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
.gp .ts-line .ht-more {
  display: inline-flex; align-items: center; gap: 6px; margin-top: 8px; padding: 0; border: 0; background: none; cursor: pointer;
  font: 600 13px/1 var(--font-display, Onest, sans-serif); color: var(--green-deep);
}
.gp .ts-line .ht-more::after {
  content: ""; width: 7px; height: 7px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg) translate(-1px, -1px); transition: transform .25s var(--ease);
}
.gp .ts-line.ht-open .ht-more::after { transform: rotate(-135deg) translate(-1px, -1px); }
.gp .ts-line .ht-more:hover { text-decoration: underline; text-underline-offset: 3px; }

/* «Запись и стенограмма» всегда раскрыта: без стрелки, заголовок не кликается */
.gp details > summary { pointer-events: none; cursor: default; }
.gp details > summary::after { display: none; }
.gp details > summary:hover { color: inherit; }

/* Приветствие в чате группы: вместо «ИИ группы слушает группу» — «Чем помочь вашей группе?» (текст приложения не трогаем) */
.app.space-group .hello h2 { font-size: 0; line-height: 0; }
.app.space-group .hello h2::before {
  content: "Чем помочь вашей группе?"; display: block; font-size: 23px; line-height: 1.25; letter-spacing: -.03em; font-weight: 650;
  font-family: var(--font-display, Onest, sans-serif); color: var(--ink); text-wrap: balance;
}
.app.space-group .is-full .hello h2::before { font-size: 30px; }

/* =====================================================================
   v13 — «Анализ по вопросам такта»: заголовок со значком, две равные кнопки, плашка статуса
   ===================================================================== */
section.gp > .block.ht-an { padding: 20px 22px 18px; }
section.gp > .block.ht-an > h3 { display: flex; align-items: center; gap: 12px; margin: 0 0 14px; font-size: 17px; letter-spacing: -.015em; }
section.gp > .block.ht-an > h3::before {
  content: ""; width: 24px; height: 24px; flex: none; background: var(--green);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 3v18h18'/%3E%3Cpath d='M18 17V9M13 17V5M8 17v-3'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 3v18h18'/%3E%3Cpath d='M18 17V9M13 17V5M8 17v-3'/%3E%3C/svg%3E") center / contain no-repeat;
}

/* кнопки: две равные, одной высоты, с иконками */
section.gp > .block.ht-an > .gp-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
section.gp > .block.ht-an > .gp-actions > .btn {
  height: 50px; padding: 0 18px; border-radius: 15px; font-size: 15px; font-weight: 600; justify-content: center; gap: 10px; white-space: normal; line-height: 1.2;
  transition: background .2s, border-color .2s, color .2s, box-shadow .2s, transform .15s var(--ease);
}
section.gp > .block.ht-an > .gp-actions > .btn::before { content: ""; width: 19px; height: 19px; flex: none; background: currentColor; }
section.gp > .block.ht-an > .gp-actions > .btn-primary::before {
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9.9 15.5A2 2 0 0 0 8.5 14.1l-6.1-1.6a.5.5 0 0 1 0-1L8.5 9.9A2 2 0 0 0 9.9 8.5l1.6-6.1a.5.5 0 0 1 1 0l1.6 6.1a2 2 0 0 0 1.4 1.4l6.1 1.6a.5.5 0 0 1 0 1l-6.1 1.6a2 2 0 0 0-1.4 1.4l-1.6 6.1a.5.5 0 0 1-1 0z'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9.9 15.5A2 2 0 0 0 8.5 14.1l-6.1-1.6a.5.5 0 0 1 0-1L8.5 9.9A2 2 0 0 0 9.9 8.5l1.6-6.1a.5.5 0 0 1 1 0l1.6 6.1a2 2 0 0 0 1.4 1.4l6.1 1.6a.5.5 0 0 1 0 1l-6.1 1.6a2 2 0 0 0-1.4 1.4l-1.6 6.1a.5.5 0 0 1-1 0z'/%3E%3C/svg%3E") center / contain no-repeat;
}
section.gp > .block.ht-an > .gp-actions > .btn-ghost::before {
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M2 3h20M21 3v11a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V3M7 21l5-5 5 5'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M2 3h20M21 3v11a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V3M7 21l5-5 5 5'/%3E%3C/svg%3E") center / contain no-repeat;
}
/* активные */
section.gp > .block.ht-an > .gp-actions > .btn-primary:not(:disabled) { background: linear-gradient(160deg, #1f538f, #143d6b); color: #fff; box-shadow: 0 12px 24px -12px rgba(20,61,107,.85); }
section.gp > .block.ht-an > .gp-actions > .btn-primary:not(:disabled):hover { transform: translateY(-1px); filter: brightness(1.06); }
section.gp > .block.ht-an > .gp-actions > .btn-ghost:not(:disabled) { background: #fff; border: 1.5px solid var(--green-line); color: var(--green-deep); }
section.gp > .block.ht-an > .gp-actions > .btn-ghost:not(:disabled):hover { background: var(--green-soft); border-color: var(--green); }
/* недоступные: читаемые, спокойные, без «выцветшего» градиента */
section.gp > .block.ht-an > .gp-actions > .btn:disabled {
  opacity: 1; filter: none; box-shadow: none; transform: none; cursor: not-allowed; background: #f2f3f5; border: 1px solid #e3e6e9; color: #8d9a92;
}
section.gp > .block.ht-an > .gp-actions > .btn-primary:disabled { background: #e7ecf2; border-color: #d3dce7; color: #5c7188; }

/* пояснения: первая строка — плашка статуса, остальные — спокойный текст */
section.gp > .block.ht-an > .gp-actions + .gp-hint {
  display: flex; align-items: center; gap: 10px; margin: 14px 0 0; padding: 11px 14px; border-radius: 13px; background: #f5f6f8; border: 1px solid #e5e8eb; color: var(--ink-2); font-size: 14px; line-height: 1.4;
}
section.gp > .block.ht-an > .gp-actions + .gp-hint::before {
  content: ""; width: 18px; height: 18px; flex: none; background: var(--green);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='9'/%3E%3Cpath d='M12 11v5M12 8h.01'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='9'/%3E%3Cpath d='M12 11v5M12 8h.01'/%3E%3C/svg%3E") center / contain no-repeat;
}
section.gp > .block.ht-an > .gp-actions + .gp-hint:empty { display: none; }
section.gp > .block.ht-an > .gp-hint ~ .gp-hint { margin: 10px 4px 0; font-size: 14px; line-height: 1.5; color: var(--muted); }
@media (max-width: 640px) { section.gp > .block.ht-an > .gp-actions { grid-template-columns: 1fr; } }

/* недоступные кнопки анализа: перебиваем градиент приложения, чтобы они не выглядели активными */
section.gp > .block.ht-an > .gp-actions > .btn:disabled { background-image: none !important; background-color: #f2f3f5 !important; border: 1px solid #e3e6e9 !important; color: #8d9a92 !important; box-shadow: none !important; -webkit-backdrop-filter: none !important; backdrop-filter: none !important; }
section.gp > .block.ht-an > .gp-actions > .btn-primary:disabled { background-color: #e7ecf2 !important; border-color: #d3dce7 !important; color: #5c7188 !important; }
section.gp > .block.ht-an > .gp-actions > .btn-primary:not(:disabled) { background-image: linear-gradient(160deg, #1f538f, #143d6b) !important; color: #fff !important; }
section.gp > .block.ht-an > .gp-actions > .btn-ghost:not(:disabled) { background-image: none !important; background-color: #fff !important; }

/* =====================================================================
   v14 — общий фон: панорама сверху, ниже однотонная заливка; верхний блок — обычная белая карточка
   ===================================================================== */
:root { --ht-bg: #f6f7f8; --ht-pt: 14px; }
html, body { background-color: var(--ht-bg) !important; background-image: none !important; }

/* Центральная колонка тянется вплотную к шапке: контент при прокрутке уходит под неё без видимой линии среза.
   Отступ сверху остаётся прежним (14 px). */
@media (min-width: 1100px) {
  main.map > section.gp { margin-top: -14px; padding-top: 14px; }
}
/* верхний блок группы: картинка справа (с мягкими краями вшитыми в файл), размер блока не меняется */
section.gp > .block.cab { background-image: none !important; background-color: #fff !important; }
.cab .cab-top { background: #fff url(/hero-v3.webp) right center / auto 100% no-repeat !important; }
.cab .cab-top::before { display: none !important; }
.cab .cab-top > .btn {
  background: rgba(255,255,255,.82); -webkit-backdrop-filter: blur(12px) saturate(1.3); backdrop-filter: blur(12px) saturate(1.3);
  border: 1px solid rgba(255,255,255,.95); box-shadow: 0 6px 20px -8px rgba(20,39,60,.35);
}
.cab .cab-top > .btn:hover { background: #fff; color: var(--green-deep); }
/* шапка приложения — светлая, чуть прозрачная над панорамой */
.top { background: rgba(255,255,255,.9) !important; }

/* v16: повестка такта на странице группы (v2) */
#ht-agenda{margin:14px 0;padding:20px 22px 18px;border-radius:24px;background:radial-gradient(120% 140% at 0% 0%,#e6edf5 0%,#f6f8fb 55%,#fff 100%);border:1px solid #cfdbe8;box-shadow:0 18px 40px -30px rgba(20,48,80,.55)}
#ht-agenda .ht-ag-h{display:flex;align-items:center;gap:18px}
#ht-agenda .ht-ag-t{flex:1;min-width:0}
#ht-agenda .ht-ag-chip{height:26px;padding:0 13px;border-radius:99px;background:#fff;color:#143d6b;font-size:11px;font-weight:700;letter-spacing:.06em;text-transform:uppercase;display:inline-flex;align-items:center;box-shadow:0 4px 10px -6px rgba(20,48,80,.5)}
#ht-agenda .ht-ag-t>b{display:block;font-size:24px;line-height:1.15;letter-spacing:-.03em;margin:10px 0 3px;color:#0f1318}
#ht-agenda .ht-ag-t small{color:#6f7b6d;font-size:13.5px}
#ht-agenda .ht-ag-ring{position:relative;width:64px;height:64px;flex:none}
#ht-agenda .ht-ag-ring svg{width:100%;height:100%}#ht-agenda .ht-ag-ring circle+circle{transition:stroke-dashoffset .8s cubic-bezier(.2,.8,.2,1)}
#ht-agenda .ht-ag-ring span{position:absolute;inset:0;display:flex;align-items:center;justify-content:center;white-space:nowrap;font-size:12px;color:#6f7b6d;font-weight:600}#ht-agenda .ht-ag-ring span b{font-size:19px;color:#143f70;margin-right:1px}
#ht-agenda ol{list-style:none;margin:16px 0 0;padding:0;display:grid;grid-template-columns:repeat(auto-fit,minmax(230px,1fr));gap:12px}
#ht-agenda li{position:relative;display:flex;flex-direction:column;align-items:flex-start;gap:10px;padding:16px 16px 14px;border-radius:18px;background:#fff;border:1px solid #e3e7ec;box-shadow:0 10px 22px -20px rgba(20,39,60,.6);transition:transform .2s,box-shadow .2s}
#ht-agenda li:hover{transform:translateY(-2px);box-shadow:0 16px 28px -20px rgba(20,39,60,.7)}
#ht-agenda li i{width:32px;height:32px;border-radius:11px;display:grid;place-items:center;font-style:normal;font-weight:700;font-size:14px;background:#eef0f2;color:#3f4853}
#ht-agenda li .ht-q{font-size:14.5px;line-height:1.42;font-weight:550;color:#0f1318;flex:1}
#ht-agenda li em{font-style:normal;font-size:11.5px;font-weight:700;letter-spacing:.02em;padding:4px 11px;border-radius:99px;background:#f0f3f0;color:#6f7b6d}
#ht-agenda li.partial i{background:#fde7bd;color:#b3731a}#ht-agenda li.partial em{background:#fff1d6;color:#b3731a}
#ht-agenda li.answered{background:#f3f6fa}#ht-agenda li.answered i{background:#1e5a9e;color:#fff}#ht-agenda li.answered em{background:#dce6f1;color:#143d6b}#ht-agenda li.answered .ht-q{color:#3f4853}
#ht-agenda li.now{border-color:#1e5a9e;box-shadow:0 0 0 3px rgba(30,90,158,.14),0 18px 30px -22px rgba(20,61,107,.8)}
#ht-agenda li.now i{background:linear-gradient(135deg,#3472b8,#143f70);color:#fff}
#ht-agenda li.now em{background:#143f70;color:#fff;animation:htp 2.4s ease-in-out infinite}
@keyframes htp{50%{box-shadow:0 0 0 5px rgba(30,90,158,.18)}}
@media(max-width:700px){#ht-agenda{padding:16px}#ht-agenda .ht-ag-t>b{font-size:20px}#ht-agenda ol{grid-template-columns:1fr}}
/* v17: разрешение слайда принудительно */
#ht-force{margin-left:8px;border-radius:12px}#ht-force.ht-force-on{background:#e9eff6!important;color:#143d6b!important;border-color:#1e5a9e!important;font-weight:650}

/* v18: «Материалы пленума» */
.ht-pm{background:linear-gradient(180deg,#fff,#fbfcfd)!important;border-radius:24px!important}
.ht-pm>h3{display:flex!important;align-items:center;gap:12px;font-size:20px!important;letter-spacing:-.02em}
.ht-pm>h3::before{content:"";width:40px;height:40px;border-radius:13px;flex:none;background:#e9eff6 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23143d6b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M14 3H7a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2V8z'/%3E%3Cpath d='M14 3v5h5M9 13h6M9 17h4'/%3E%3C/svg%3E") center/22px no-repeat}
.ht-pm>.gp-hint{margin:8px 0 14px!important;padding:11px 14px;border-radius:14px;background:#f3f5f8;border:1px solid #e1e7ee;color:#3f4853!important;font-size:13.5px!important;line-height:1.5}
.ht-pm .gp-q{position:relative;margin:12px 0 0!important;padding:16px 18px!important;border:1px solid #e0e5ea!important;border-radius:20px!important;background:#fff!important;box-shadow:0 12px 26px -22px rgba(20,39,60,.6);transition:box-shadow .2s,transform .2s}
.ht-pm .gp-q:hover{box-shadow:0 18px 32px -22px rgba(20,39,60,.7);transform:translateY(-1px)}
.ht-pm .gp-q h4{display:flex!important;align-items:center;gap:14px;margin:0!important}
.ht-pm .gp-q h4::before{content:"";width:46px;height:46px;border-radius:15px;flex:none;background:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23143d6b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M14 3H7a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2V8z'/%3E%3Cpath d='M14 3v5h5M9 13h6M9 17h4'/%3E%3C/svg%3E") center/24px no-repeat,linear-gradient(135deg,#e1eaf4,#f4f7fb);box-shadow:inset 0 0 0 1px #d2dde9}
.ht-pm .gp-q h4>span:first-child{flex:1;min-width:0;font-size:16.5px;font-weight:650;letter-spacing:-.01em;line-height:1.3}
.ht-pm .gp-q h4 small{display:block;margin-top:3px;font-size:12.5px;font-weight:500;color:#6f7b6d}
.ht-pm .gp-q h4 .gp-st{flex:none;height:32px;padding:0 15px;display:inline-flex;align-items:center;border-radius:99px;background:#e9eff6!important;color:#143d6b!important;font-size:12.5px;font-weight:700;transition:background .15s}
.ht-pm .gp-q h4:hover .gp-st{background:#d6e2ef!important}
.ht-pm .st-md{margin-top:14px;padding:6px 6px 4px 18px;border-left:3px solid #1e5a9e;border-radius:2px;line-height:1.65;font-size:14.5px;animation:htmd .3s ease}
@keyframes htmd{from{opacity:0;transform:translateY(-4px)}}
.ht-pm .gp-actions{margin-top:14px!important;display:flex;gap:8px;flex-wrap:wrap}
.ht-pm .gp-actions .btn{display:inline-flex;align-items:center;gap:8px;height:38px;padding:0 16px!important;border-radius:12px!important;background:#f1f3f6!important;border:1px solid #dde3e9!important;color:#143d6b!important;font-weight:650;transition:background .15s,transform .15s}
.ht-pm .gp-actions .btn:hover{background:#e3eaf2!important}.ht-pm .gp-actions .btn:active{transform:scale(.97)}
.ht-pm .gp-actions .btn::before{content:"";width:17px;height:17px;background:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23143d6b' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 4v11M7 11l5 5 5-5M5 20h14'/%3E%3C/svg%3E") center/contain no-repeat}
.ht-pm .gp-actions .btn[target]::before{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23143d6b' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M2 3h20M21 3v11a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V3M7 21l5-5 5 5'/%3E%3C/svg%3E")}

/* v19: «Анализ по вопросам такта» — карточки вопросов, проще читать */
section.gp > .block.ht-an .gp-q{position:relative;margin:14px 0 0!important;padding:18px 22px 16px 26px!important;border:1px solid #e2e6eb!important;border-radius:20px!important;background:#fff!important;box-shadow:0 12px 26px -22px rgba(20,39,60,.6);overflow:hidden}
section.gp > .block.ht-an .gp-q::before{content:"";position:absolute;left:0;top:0;bottom:0;width:6px;background:#d3dbd5}
section.gp > .block.ht-an .gp-q:has(.gp-st.answered)::before{background:linear-gradient(180deg,#3472b8,#143f70)}
section.gp > .block.ht-an .gp-q:has(.gp-st.partial)::before{background:linear-gradient(180deg,#f3c15f,#e08a00)}
section.gp > .block.ht-an .gp-q h4{display:flex!important;align-items:flex-start;gap:14px;margin:0 0 4px!important;font-size:17px;line-height:1.35;font-weight:650;letter-spacing:-.015em;color:#0f1318}
section.gp > .block.ht-an .gp-q h4>span:first-child{flex:1;min-width:0}
section.gp > .block.ht-an .gp-q .gp-st{flex:none;margin-top:1px;padding:4px 13px!important;border-radius:99px!important;font-size:12px!important;font-weight:700;background:#eef1ee!important;color:#6f7b6d!important;border:0!important}
section.gp > .block.ht-an .gp-q .gp-st.answered{background:#dce6f1!important;color:#143d6b!important}
section.gp > .block.ht-an .gp-q .gp-st.partial{background:#fff1d6!important;color:#b3731a!important}
section.gp > .block.ht-an .gp-q p{margin:12px 0 0!important;font-size:14.5px;line-height:1.62;color:#293038}
section.gp > .block.ht-an .gp-q p>b:first-child{display:block;margin-bottom:3px;font-size:11px;font-weight:700;letter-spacing:.08em;text-transform:uppercase;color:#7b887a}
section.gp > .block.ht-an .gp-q p small{color:#7b887a;font-size:12.5px}
section.gp > .block.ht-an .gp-rel{display:inline-block;margin:6px 0 0;padding:3px 11px;border-radius:99px;font-size:11.5px;font-weight:650;background:#eef3ff;color:#2f5fb8}
section.gp > .block.ht-an .gp-quote{position:relative;margin:10px 0 0!important;padding:11px 14px 11px 40px!important;border:0!important;border-radius:14px!important;background:#f4f6f8!important;font-size:13.5px;line-height:1.55;color:#37453a;font-style:normal}
section.gp > .block.ht-an .gp-quote::before{content:"\201C";position:absolute;left:13px;top:2px;font:700 34px/1.2 Georgia,serif;color:#9fb7d2}
section.gp > .block.ht-an .gp-quote small{display:block;margin-top:4px;font-size:12px;color:#7b887a}
section.gp > .block.ht-an .gp-ref{background:#eef4fb!important}section.gp > .block.ht-an .gp-ref::before{color:#a9c4e6}
section.gp > .block.ht-an .gp-ins{background:linear-gradient(135deg,#f3f6fa,#fff)!important}
section.gp > .block.ht-an .gp-ins::before{background:linear-gradient(180deg,#7a3fd1,#4c2399)!important}
section.gp > .block.ht-an .gp-ins h4{font-size:16px}
section.gp > .block.ht-an .gp-ins p{padding-left:2px}
@media(max-width:640px){section.gp > .block.ht-an .gp-q{padding:16px 16px 14px 20px!important}section.gp > .block.ht-an .gp-q h4{font-size:16px;flex-wrap:wrap;gap:8px}}

/* v20: анализ — сильнее разделить: секции, итог, сворачиваемые цитаты */
section.gp > .block.ht-an{padding:22px 24px 20px}
section.gp > .block.ht-an .gp-q{margin:22px 0 0!important;padding:20px 24px 20px 28px!important;box-shadow:0 16px 34px -26px rgba(20,39,60,.7)}
section.gp > .block.ht-an .gp-q h4{padding-bottom:14px;margin:0 0 4px!important;border-bottom:1px solid #e8ebef;font-size:17.5px}
section.gp > .block.ht-an .gp-q p{margin:0!important;padding:0!important;border:0!important}
section.gp > .block.ht-an .gp-q p.ht-l{margin-top:14px!important;padding:12px 15px!important;border-radius:14px!important;line-height:1.58}
section.gp > .block.ht-an .gp-q p.ht-l-cons{background:#f2f5f8;box-shadow:inset 3px 0 0 #3472b8}
section.gp > .block.ht-an .gp-q p.ht-l-ai{background:#f1f6fd;box-shadow:inset 3px 0 0 #5b8fd9}
section.gp > .block.ht-an .gp-q p.ht-l-gap{background:#fff7e8;box-shadow:inset 3px 0 0 #e8a935}
section.gp > .block.ht-an .gp-q p.ht-l-cons>b:first-child{color:#1c487a}
section.gp > .block.ht-an .gp-q p.ht-l-ai>b:first-child{color:#3b6bb5}
section.gp > .block.ht-an .gp-q p.ht-l-gap>b:first-child{color:#b3731a}
section.gp > .block.ht-an .gp-q h4+p:not(.ht-l),section.gp > .block.ht-an .gp-q .gp-rel+p:not(.ht-l){margin-top:14px!important;color:#3f4853}
section.gp > .block.ht-an .gp-quote{margin:14px 0 0!important}
section.gp > .block.ht-an .gp-quote.ht-long:not(.ht-open){max-height:92px;overflow:hidden;cursor:pointer}
section.gp > .block.ht-an .gp-quote.ht-long{cursor:pointer}
section.gp > .block.ht-an .gp-quote.ht-long::after{content:"Показать полностью ▾";position:absolute;right:0;bottom:0;font-size:12px;font-weight:700;color:#143d6b;background:linear-gradient(90deg,transparent,#f4f6f8 28%);padding:14px 14px 6px 40px;border-radius:0 0 14px 0}
section.gp > .block.ht-an .gp-quote.ht-long.ht-open::after{content:"Свернуть ▴";position:static;display:inline-block;margin-top:6px;padding:0}
/* итог анализа (второй абзац-подсказка) */
section.gp > .block.ht-an > .gp-hint.ht-sum{margin:20px 0 0!important;padding:16px 20px!important;border-radius:18px;background:linear-gradient(135deg,#f3f6fa,#fff);border:1px solid #d6dfea;box-shadow:inset 4px 0 0 #1e5a9e;font-size:15px!important;line-height:1.65;color:#1f262d!important}
section.gp > .block.ht-an > .gp-hint.ht-sum::before{content:"Итог анализа";display:block;margin-bottom:5px;font-size:11px;font-weight:700;letter-spacing:.08em;text-transform:uppercase;color:#143d6b}
section.gp > .block.ht-an > .gp-actions{margin-bottom:6px}

/* v21: текущий трек в повестке */
.ht-ag-now,.ag-now2{display:inline-flex;align-items:center;gap:7px;height:26px;padding:0 13px;margin-left:8px;border-radius:99px;background:#143f70;color:#fff;font-size:11.5px;font-weight:700;letter-spacing:.02em;vertical-align:top}
.ht-ag-now::before,.ag-now2::before{content:"";width:8px;height:8px;border-radius:50%;background:#7cb2f0;animation:htp2 1.6s infinite}
@keyframes htp2{50%{box-shadow:0 0 0 5px rgba(124,178,240,.3)}}

/* v22: навыки ИИ в чате группы */
.ht-sk-btn{display:inline-flex;align-items:center;gap:7px;height:32px;padding:0 13px;border-radius:99px;border:1.5px solid #cbd9e8;background:#fff;color:#143d6b;font-weight:650;font-size:13px;margin-right:6px;transition:all .18s;cursor:pointer}
.ht-sk-btn:hover{background:#e9eff6;border-color:#1e5a9e}
#ht-sk-chip{display:flex;align-items:center;gap:10px;margin:0 0 8px;padding:10px 12px;border-radius:16px;background:linear-gradient(135deg,#e9eff6,#f6f8fb);border:1px solid #cbd9e8}
#ht-sk-chip .ht-sk-dot{width:9px;height:9px;border-radius:50%;background:#1e5a9e;flex:none;animation:htsk 1.6s infinite}@keyframes htsk{50%{box-shadow:0 0 0 6px rgba(30,90,158,.18)}}
#ht-sk-chip b{display:block;font-size:13.5px;line-height:1.25}#ht-sk-chip small{display:block;color:#6f7b6d;font-size:12px;line-height:1.3;margin-top:1px}
#ht-sk-chip button{margin-left:auto;flex:none;height:30px;padding:0 13px;border-radius:99px;border:1.5px solid #e4cdd3;background:#fff;color:#b0314e;font-weight:700;font-size:12.5px;cursor:pointer}
#ht-sk-pop{position:fixed;z-index:200;width:340px;max-width:calc(100vw - 16px);max-height:min(70vh,520px);overflow:auto;padding:14px;border-radius:20px;background:#fff;border:1px solid #d6dde6;box-shadow:0 26px 60px -20px rgba(10,24,40,.55)}
#ht-sk-pop .ht-sk-h{display:flex;align-items:center;justify-content:space-between}#ht-sk-pop .ht-sk-h b{font-size:16px}
#ht-sk-pop .ht-sk-x{border:0;background:#f1f3f5;width:28px;height:28px;border-radius:50%;font-size:18px;line-height:1;cursor:pointer;color:#3f4853}
#ht-sk-pop p{margin:6px 0 10px;color:#6f7b6d;font-size:12.5px;line-height:1.45}
#ht-sk-pop .ht-sk-err{color:#b0314e;font-size:12.5px;margin-bottom:6px}#ht-sk-pop .ht-sk-err:empty{display:none}
#ht-sk-pop .ht-sk-note{padding:9px 11px;border-radius:12px;background:#fff7e8;color:#8a5a12;font-size:12.5px;margin-bottom:8px}
#ht-sk-pop .ht-sk-l{display:grid;gap:7px}
#ht-sk-pop .ht-sk-i{text-align:left;display:flex;flex-direction:column;gap:2px;padding:10px 12px;border-radius:14px;border:1px solid #dce3eb;background:#fff;cursor:pointer;transition:all .15s}
#ht-sk-pop .ht-sk-i b{font-size:13.5px;color:#0f1318}#ht-sk-pop .ht-sk-i span{font-size:12px;color:#6f7b6d;line-height:1.35;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
#ht-sk-pop .ht-sk-i:hover:not(:disabled){background:#e9eff6;border-color:#1e5a9e}#ht-sk-pop .ht-sk-i:disabled{opacity:.5;cursor:default}

/* v23: перетаскивание файлов в чат */
.ht-drop{position:relative}
.ht-drop::after{content:"Отпустите файл — он попадёт в материалы группы";position:absolute;inset:6px;z-index:60;display:grid;place-items:center;text-align:center;padding:20px;border:2.5px dashed #1e5a9e;border-radius:22px;background:rgba(233,239,246,.93);color:#143d6b;font-weight:700;font-size:16px;line-height:1.4;pointer-events:none;animation:htdz .18s ease}
@keyframes htdz{from{opacity:0;transform:scale(.98)}}
#ht-dz-toast{position:fixed;z-index:300;left:50%;bottom:90px;transform:translate(-50%,14px);max-width:min(92vw,520px);padding:11px 18px;border-radius:14px;background:#0f1318;color:#fff;font-size:13.5px;line-height:1.4;text-align:center;opacity:0;pointer-events:none;transition:.25s}
#ht-dz-toast.on{opacity:1;transform:translate(-50%,0)}#ht-dz-toast.bad{background:#a52a45}
