/* 모션 그래픽 카드(static/js/chat_motion.js) — 재생은 <hyperframes-player>(제 조작 막대를 갖는다), 여기는 틀·제목 줄·단추만. */

.cm {
  width: 100%;
  margin: 10px 0 4px;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--border-color, rgba(148, 163, 184, .28));
  background: var(--surface-color, #fff);
  box-sizing: border-box;
}
.cm__stage {
  position: relative;
  width: 100%;
  background: #0b0b0f;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}
.cm__stage:fullscreen { aspect-ratio: auto !important; background: #000; }
.cm__player { display: block; width: 100%; height: 100%; }

.cm__bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px 10px 14px;
}
.cm__meta { display: flex; align-items: baseline; gap: 8px; min-width: 0; }
.cm__title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-color);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.cm__len { flex: 0 0 auto; font-size: 12.5px; color: var(--text-secondary, #64748b); font-variant-numeric: tabular-nums; }
.cm__actions { display: flex; gap: 6px; flex: 0 0 auto; }
.cm__btn {
  height: 32px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid var(--border-color, rgba(148, 163, 184, .35));
  background: transparent;
  color: var(--text-color);
  font: inherit;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
}
.cm__btn:hover { background: color-mix(in srgb, var(--text-color, #111) 6%, transparent); }
.cm__btn--primary { background: #0082FF; border-color: #0082FF; color: #fff; }
.cm__btn--primary:hover { background: #006fe0; }
.cm__btn:disabled { opacity: .6; cursor: default; }
.cm__note { margin: 0; padding: 0 14px 12px; font-size: 13px; line-height: 1.5; color: var(--text-secondary, #64748b); }
.cm__note[hidden] { display: none; }

/* 쓰는 중 — 글 대신 고요한 자리 */
.cm--pending .cm__stage { color: rgba(255, 255, 255, .72); font-size: 14px; }
.cm__spin {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, .25);
  border-top-color: #fff;
  animation: cm-spin .8s linear infinite;
}
@keyframes cm-spin { to { transform: rotate(360deg); } }

/* 실제 그림·영상(media:)을 찾는 동안 — 재생기 위에 한 줄 */
.cm__loading {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #0b0b0f;
  color: rgba(255, 255, 255, .72);
  font-size: 14px;
  pointer-events: none;
}

/* 옛 엔진의 블록 */
.cm--legacy {
  padding: 12px 14px;
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--text-secondary, #64748b);
  background: color-mix(in srgb, var(--text-color, #111) 3%, transparent);
}

@media (max-width: 520px) {
  .cm__bar { flex-wrap: wrap; }
  .cm__actions { width: 100%; justify-content: flex-end; }
}
