/* Подвал сообщения ИИ */

.mfoot {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 6px;
  font-family: var(--font-ui-plain);
  font-size: 11.5px;
  letter-spacing: .02em;
  color: var(--ink-faint);
  opacity: .12;
  transition: opacity .3s ease;
}

.msg:hover .mfoot,
.msg:focus-within .mfoot,
.mfoot.shown {
  opacity: 1;
}

/* Без наведения (touch) подвал виден сразу, иначе кнопка копирования недоступна */
@media (hover: none) {
  .mfoot {
    opacity: 1;
  }
}

.mfoot-left {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  white-space: nowrap;
}

.mfoot-time,
.mfoot-cost {
  font-variant-numeric: tabular-nums;
}

.mfoot-model {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
}

.mfoot-sep {
  display: inline-block;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: currentColor;
  opacity: .5;
  flex: none;
}

/* Стоимость и подсказка */

.mfoot-cost {
  position: relative;
  cursor: default;
}

.cost-tip {
  position: absolute;
  left: 0;
  bottom: calc(100% + 8px);
  z-index: 5;
  min-width: 216px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface);
  box-shadow: 0 8px 24px rgba(var(--shadow-rgb), .10);
  opacity: 0;
  visibility: hidden;
  transform: translateY(4px);
  transition: opacity .18s ease, transform .18s ease, visibility .18s ease;
}

.mfoot-cost:hover .cost-tip,
.mfoot-cost:focus-within .cost-tip,
.mfoot-cost.shown .cost-tip {
  opacity: 1;
  visibility: visible;
  transform: none;
}

.cost-cap {
  display: block;
  margin-bottom: 6px;
  font-size: 10.5px;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--ink-soft);
}

.cost-line {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  font-size: 11.5px;
  color: var(--ink);
}

.cost-who {
  overflow: hidden;
  text-overflow: ellipsis;
  color: var(--ink-soft);
}

.cost-val {
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}

/* Кнопка копирования */

.mfoot-copy {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  margin-left: auto;
  padding: 0;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--ink-soft);
  cursor: pointer;
  transition: color .25s ease, background .25s ease, box-shadow .25s ease;
}

.mfoot-copy:hover {
  background: rgba(var(--warm-rgb), .08);
  color: var(--amber);
}

.mfoot-copy:focus-visible {
  box-shadow: var(--glow-ring);
  outline: none;
}

.mfoot-copy svg {
  width: 13px;
  height: 13px;
  display: block;
}

.mfoot-copy .ico-check {
  display: none;
}

.mfoot-copy.done .ico-copy {
  display: none;
}

.mfoot-copy.done .ico-check {
  display: block;
}

.mfoot-copy.done {
  color: var(--amber);
}
