/* Сделки фондов: то, чего нет в общем наборе раздела. */

/* Покупки и продажи: два столбца по десять акций. Полоса - величина сделки,
   цвет - только её знак (докупили зелёный, сократили красный). */
.ft-move { display: grid; grid-template-columns: 1fr 1fr; gap: var(--cf-space-16) var(--cf-space-24); flex: 1 1 auto; }
.ft-move__col h3, .ft-new__grp h3 { margin: 0 0 var(--cf-space-8); font-size: 14px; font-weight: 600; color: var(--cf-ink-2); }
.ft-move__col ol, .ft-new__grp ul { margin: 0; padding: 0; list-style: none; }
.ft-move__row, .ft-new__row { display: grid; width: calc(100% + var(--cf-space-8) * 2); margin: 0 calc(var(--cf-space-8) * -1); padding: var(--cf-space-6) var(--cf-space-8);
  border: 0; border-radius: var(--cf-radius-md); background: none; color: var(--cf-ink); font: inherit; text-align: left; cursor: pointer; }
.ft-move__row { grid-template-columns: minmax(0, 1fr) auto; gap: var(--cf-space-4) var(--cf-space-10); align-items: center; }
.ft-move__row:hover, .ft-new__row:hover { background: var(--cf-surface-2); }
.ft-move__row:focus-visible, .ft-new__row:focus-visible { outline: 2px solid var(--cf-accent); outline-offset: 0; }
.ft-move__name { display: flex; align-items: center; gap: var(--cf-space-10); min-width: 0; }
.ft-move__name > span:last-child { min-width: 0; }
.ft-move__name b, .ft-new__t b { display: block; font-size: 14px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ft-move__name small, .ft-new__t small { display: block; font-size: 12.5px; color: var(--cf-ink-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ft-move .an-mono, .ft-new .an-mono { width: 26px; height: 26px; font-size: 10.5px; flex: none; }
.ft-move__v { font-size: 14px; font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; }
.ft-move__v.is-up { color: var(--cf-up); }
.ft-move__v.is-down { color: var(--cf-down); }
.ft-move__bar { grid-column: 1 / -1; display: block; height: 4px; margin-left: 36px; border-radius: var(--cf-radius-bar); background: var(--cf-surface-2); overflow: hidden; }
.ft-move__bar i { display: block; height: 100%; border-radius: var(--cf-radius-bar); }
.ft-move__bar i.is-up { background: var(--cf-up); }
.ft-move__bar i.is-down { background: var(--cf-down); }

/* Новые и закрытые позиции. */
.ft-new { display: grid; gap: var(--cf-space-20); align-content: start; }
.ft-new__grp h3 span { margin-left: var(--cf-space-4); color: var(--cf-ink-3); font-weight: 500; font-variant-numeric: tabular-nums; }
.ft-new__row { grid-template-columns: auto minmax(0, 1fr); gap: var(--cf-space-10); align-items: center; }
.ft-new__t { min-width: 0; }
.ft-new__more { margin: var(--cf-space-4) 0 0 calc(var(--cf-space-10) * -1); }

/* Поиск над таблицей акций. */
.ft-find { margin-bottom: var(--cf-space-14); }
.ft-find .cf-search { width: min(320px, 100%); }

/* Строки таблиц: монограмма или логотип УК, название, подпись. */
.ft-cls { display: flex; align-items: center; gap: var(--cf-space-10); }
.ft-cls .an-mono { width: 26px; height: 26px; font-size: 10.5px; flex: none; }
.ft-cls small, .an-table td.num small { display: block; color: var(--cf-ink-3); font-size: 12.5px; }
.ft-logo { flex: none; width: 26px; height: 26px; border-radius: 50%; object-fit: contain; background: var(--cf-surface); box-shadow: inset 0 0 0 1px var(--cf-line); }
.an-table tr[data-s], .an-table tr[data-f] { cursor: pointer; }
/* Ячейки таблицы каркаса залиты фоном (первая закреплена), поэтому
   подсветка строки - на ячейках, а не на tr. */
.an-table tr[data-s]:hover > td, .an-table tr[data-f]:hover > td { background: var(--cf-surface-2); }
.an-table tr.is-sel > td, .an-table tr.is-sel:hover > td { background: var(--cf-accent-soft); }
.an-table tr:focus-visible { outline: 2px solid var(--cf-accent); outline-offset: -2px; }
.an-table td { white-space: nowrap; }
.an-table td:first-child { white-space: normal; min-width: 220px; }
#ftFunds td:first-child { min-width: 300px; }
.an-table th[aria-sort] button::after { content: ""; display: inline-block; margin-left: 6px; border: 4px solid transparent; vertical-align: 1px; }
.an-table th[aria-sort="descending"] button::after { border-top-color: currentColor; border-bottom: 0; }
.an-table th[aria-sort="ascending"] button::after { border-bottom-color: currentColor; border-top: 0; }
.an-table th[aria-sort] button { color: var(--cf-accent); }

/* Подробности акции или фонда под таблицей. */
.ft-detail { margin-top: var(--cf-space-16); }
.ft-detail .cf-panel__head { position: relative; padding-right: var(--cf-space-40); }
.ft-detail__x { position: absolute; top: 0; right: 0; }
.ft-detail__bars { margin-bottom: var(--cf-space-8); }
.ft-detail__h { margin: var(--cf-space-16) 0 var(--cf-space-10); font-size: 15px; font-weight: 600; }
.ft-detail .cf-callout { margin-bottom: var(--cf-space-14); }
.an-kpis .cf-keystrip__v small { font-size: 0.6em; font-weight: 500; color: var(--cf-ink-3); }

@media (max-width: 900px) {
  .ft-move { grid-template-columns: 1fr; }
}
@media (max-width: 767px) {
  #ftKpis .cf-keystrip__v { font-size: 20px; }
  .an-table td:first-child { min-width: 170px; }
  #ftFunds td:first-child { min-width: 220px; }
}

/* Знак акции: логотип поверх монограммы. Файл не загрузился - img убирает
   себя, остаётся буква. Кружок и обводка - как у логотипов УК. */
.ft-ava { position: relative; display: inline-grid; flex: none; width: 26px; height: 26px; }
.ft-ava .an-mono { width: 26px; height: 26px; font-size: 10.5px; }
.ft-ava img { position: absolute; inset: 0; width: 100%; height: 100%; border-radius: 50%; object-fit: contain;
  background: var(--cf-surface); box-shadow: inset 0 0 0 1px var(--cf-line); }
