/* ② 개념 폴더의 단계별 구조 모션. 도형은 개인 계산 결과가 아닌 설명용이다. */
.concept-motion { margin: 14px 0 20px; padding: 16px; min-width: 0; border: 1px solid var(--border-box-purple); border-radius: 14px; background: var(--bg-card-inner); color: var(--text-pure); }
.cm-head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 12px; }
.cm-head h4 { margin: 0; font-size: 12pt; }
.cm-example { color: var(--text-sub); font-size: 10pt; }
.cm-play { margin-left: auto; }
.cm-choices, .cm-steps { display: flex; flex-wrap: wrap; gap: 6px; }
.cm-choices { margin-bottom: 12px; max-height: 130px; overflow-y: auto; padding: 3px; }
.cm-button { max-width: 100%; min-height: 34px; padding: 6px 10px; border: 1px solid var(--border-box-purple); border-radius: 9px; background: transparent; color: var(--text-sub); font: 700 10pt/1.35 var(--font-main); overflow-wrap: anywhere; cursor: pointer; }
.cm-button:hover { border-color: var(--neon-cyan); color: var(--text-pure); }
.cm-button[aria-pressed="true"] { color: var(--text-pure); border-color: var(--neon-cyan); background: color-mix(in srgb, var(--neon-cyan) 12%, var(--bg-card)); }
.cm-button:focus-visible { outline: 3px solid var(--neon-cyan); outline-offset: 2px; }
.cm-steps { padding-bottom: 12px; border-bottom: 1px solid var(--border-box-purple); }
.cm-stage { display: grid; align-items: center; min-height: 270px; min-width: 0; padding: 14px 0; }
.cm-caption { margin: 0; color: var(--text-pure); font-size: 11pt; line-height: 1.6; }
.cm-meta, .cm-connections { display: flex; flex-wrap: wrap; gap: 6px 12px; margin-top: 10px; color: var(--text-sub); font-size: 10pt; line-height: 1.5; }
.cm-meta b { color: var(--text-pure); }
.cm-connections:empty { display: none; }
.cm-chart { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 9px; max-width: 530px; width: 100%; margin: auto; }
.cm-column { text-align: center; color: var(--text-sub); font-size: 10pt; }
.cm-cell { display: flex; flex-direction: column; justify-content: center; gap: 5px; min-height: 85px; text-align: center; padding: 8px 3px; border: 1px solid var(--border-box-purple); border-radius: 12px; opacity: .55; color: var(--text-sub); }
.cm-cell b { font-size: clamp(17px, 3vw, 26px); }
.cm-cell span, .cm-cell small { font-size: 10pt; }
.cm-cell.is-active { opacity: 1; border-color: var(--neon-cyan); background: color-mix(in srgb, var(--neon-cyan) 10%, var(--bg-card)); color: var(--text-pure); animation: cm-cell-enter .55s ease both; animation-delay: calc(var(--cm-order, 0) * 55ms); }
.cm-cell.is-day.is-active { border-color: var(--neon-pink); background: color-mix(in srgb, var(--neon-pink) 10%, var(--bg-card)); }
.cm-svg { display: block; width: 100%; max-width: 560px; margin: auto; overflow: visible; color: var(--text-pure); }
.cm-line { stroke: var(--border-box-purple); stroke-width: 2; }
.cm-line.is-active { stroke: var(--neon-cyan); stroke-dasharray: 7 5; animation: cm-link-enter .8s ease both; }
.cm-node circle { fill: var(--bg-card); stroke: var(--border-box-purple); stroke-width: 1.5; }
.cm-node text, .cm-label { fill: currentColor; font: 700 14px var(--font-main); }
.cm-node.is-small text { font-size: 20px; }
.cm-ring-key { list-style: none; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 7px; padding: 0; margin: 12px 0 0; color: var(--text-sub); font-size: 10pt; }
.cm-ring-key li { padding: 4px; text-align: center; border: 1px solid var(--border-box-purple); border-radius: 6px; }
.cm-node.is-active circle { stroke: var(--neon-cyan); stroke-width: 2; animation: cm-node-enter .5s ease both; }
.cm-node.cm-element-0 { color: var(--neon-green, #35b867); }
.cm-node.cm-element-1 { color: var(--neon-pink); }
.cm-node.cm-element-2 { color: var(--neon-yellow); }
.cm-node.cm-element-3 { color: var(--text-pure); }
.cm-node.cm-element-4 { color: var(--neon-cyan); }
.cm-flow { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; width: 100%; }
.cm-flow-node { position: relative; display: grid; place-content: center; min-height: 84px; border: 1px solid var(--border-box-purple); border-radius: 12px; padding: 10px; text-align: center; font-size: 11pt; line-height: 1.5; overflow-wrap: anywhere; color: var(--text-sub); }
.cm-flow-node + .cm-flow-node::before { content: ''; position: absolute; left: -13px; top: 50%; width: 12px; height: 2px; background: var(--neon-cyan); }
.cm-flow-node.is-active { color: var(--text-pure); border-color: var(--neon-cyan); background: color-mix(in srgb, var(--neon-cyan) 8%, var(--bg-card)); animation: cm-cell-enter .55s ease both; animation-delay: calc(var(--cm-order, 0) * 100ms); }
.cm-cycle, .cm-void, .cm-climate, .cm-timeline { width: 100%; min-width: 0; }
.cm-slices { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-top: 20px; }
.cm-slice { text-align: center; padding: 10px 2px; border: 1px solid var(--border-box-purple); border-radius: 8px; font-size: 10pt; }
.cm-slice.is-active { border-color: var(--neon-pink); animation: cm-cell-enter .6s ease both; }
.cm-void-slots { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 8px; margin-bottom: 20px; }
.cm-void-slot { display: grid; place-items: center; height: 40px; border: 1px solid var(--border-box-purple); border-radius: 8px; font-size: 10pt; }
.cm-void-slot.is-void { border: 2px dashed var(--neon-pink); color: var(--neon-pink); animation: cm-cell-enter .6s ease both; }
.cm-climate-season { display: block; text-align: center; margin-bottom: 24px; }
.cm-climate-rail { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 10px; margin: 20px 0; font-size: 10pt; color: var(--text-sub); }
.cm-climate-track { height: 12px; border: 1px solid var(--border-box-purple); border-radius: 20px; }
.cm-climate-rail.is-active .cm-climate-track { background: linear-gradient(90deg, var(--neon-cyan), var(--neon-pink)); animation: cm-bar-enter .7s ease both; }
.cm-time-direction { color: var(--text-sub); font-size: 10pt; margin-bottom: 10px; }
.cm-time-rail { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2px; margin-bottom: 20px; }
.cm-time-block { display: flex; position: relative; flex-direction: column; align-items: center; gap: 8px; border-top: 4px solid var(--border-box-purple); padding: 20px 2px; font-size: 10pt; }
.cm-time-block.is-active { border-top-color: var(--neon-cyan); animation: cm-cell-enter .5s ease both; }
.cm-boundary { font-size: 9pt; color: var(--neon-pink); }
@keyframes cm-cell-enter { from { transform: translateY(10px); opacity: .35; } to { transform: translateY(0); opacity: 1; } }
@keyframes cm-link-enter { from { stroke-dashoffset: 75; opacity: 0; } to { stroke-dashoffset: 0; opacity: 1; } }
@keyframes cm-node-enter { from { stroke-width: 5; opacity: .4; } to { stroke-width: 2; opacity: 1; } }
@keyframes cm-bar-enter { from { clip-path: inset(0 100% 0 0); } to { clip-path: inset(0); } }
@media (max-width: 600px) {
  .concept-motion { padding: 12px; }
  .cm-stage { min-height: 225px; }
  .cm-chart { gap: 5px; }
  .cm-cell { min-height: 72px; }
  .cm-flow { gap: 8px; }
  .cm-flow-node { padding: 6px; font-size: 10pt; }
  .cm-flow-node + .cm-flow-node::before { left: -9px; width: 8px; }
  .cm-button { min-height: 40px; }
  .cm-node text, .cm-label { font-size: 22px; }
  .cm-node.is-small text { font-size: 26px; }
  .cm-ring-key { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
/* 예시 명식 장면 — 사주풀이 결과표와 같은 8칸 표 위에서 단계마다 강조·번호표·계산 한 줄이 바뀐다. */
.cm-ex { display: grid; gap: 12px; width: 100%; min-width: 0; }
.cm-ex-table { display: grid; grid-template-columns: minmax(48px, .8fr) repeat(var(--cm-cols, 4), minmax(0, 1fr)); gap: 5px; align-items: stretch; }
.cm-ex-corner { min-height: 1px; }
.cm-ex-col { padding: 5px 2px; text-align: center; border-radius: 8px; background: color-mix(in srgb, var(--neon-pink) 10%, var(--bg-card)); color: var(--text-pure); font: 800 10pt/1.3 var(--font-main); }
.cm-ex-col.is-day { background: color-mix(in srgb, var(--neon-pink) 22%, var(--bg-card)); }
.cm-ex-row { align-self: center; color: var(--text-sub); font: 700 9pt/1.3 var(--font-main); text-align: right; padding-right: 2px; }
.cm-ex-cell { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; min-height: 44px; padding: 5px 2px; text-align: center; border: 1px solid var(--border-box-purple); border-radius: 9px; font: 700 10pt/1.3 var(--font-main); color: var(--text-pure); background: var(--bg-card); transition: opacity .25s, border-color .25s, background .25s; }
.cm-ex-cell b { font-size: clamp(18px, 3.4vw, 26px); line-height: 1.1; }
.cm-ex-cell small { font-size: 9pt; font-weight: 800; }
.cm-ex-table.is-dimming .cm-ex-cell:not(.is-marked) { opacity: .4; }
.cm-ex-cell.is-marked { animation: cm-cell-enter .5s ease both; animation-delay: calc(var(--cm-order, 0) * 110ms); }
.cm-ex-cell.is-focus, .cm-ex-hid.is-focus { border-color: var(--neon-cyan); background: color-mix(in srgb, var(--neon-cyan) 14%, var(--bg-card)); }
.cm-ex-cell.is-help, .cm-ex-hid.is-help { border-color: var(--neon-lime); background: color-mix(in srgb, var(--neon-lime) 13%, var(--bg-card)); }
.cm-ex-cell.is-hit, .cm-ex-hid.is-hit { border-color: var(--neon-yellow); background: color-mix(in srgb, var(--neon-yellow) 14%, var(--bg-card)); }
.cm-ex-cell.is-lone, .cm-ex-hid.is-lone { border-style: dashed; border-color: var(--neon-pink); background: color-mix(in srgb, var(--neon-pink) 8%, var(--bg-card)); }
.cm-ex-cell.is-same { border-color: var(--neon-cyan); background: color-mix(in srgb, var(--neon-cyan) 12%, var(--bg-card)); }
.cm-ex-cell.is-diff { border-color: var(--neon-pink); background: color-mix(in srgb, var(--neon-pink) 12%, var(--bg-card)); }
.cm-ex-cell.fam-peer, .cm-ex-callout.fam-peer { border-color: var(--neon-cyan); }
.cm-ex-cell.fam-output, .cm-ex-callout.fam-output { border-color: var(--neon-lime); }
.cm-ex-cell.fam-wealth, .cm-ex-callout.fam-wealth { border-color: var(--neon-yellow); }
.cm-ex-cell.fam-authority, .cm-ex-callout.fam-authority { border-color: var(--neon-pink); }
.cm-ex-cell.fam-resource, .cm-ex-callout.fam-resource { border-color: #8e7bff; }
.cm-ex-cell[class*="fam-"] { background: color-mix(in srgb, var(--bg-card) 86%, currentColor); }
.el-木 { color: var(--neon-lime); }
.el-火 { color: var(--neon-pink); }
.el-土 { color: var(--neon-yellow); }
.el-金 { color: var(--text-pure); }
.el-水 { color: var(--neon-cyan); }
.cm-ex-cell.cm-ex-hidden { flex-direction: row; flex-wrap: wrap; gap: 3px; padding: 3px; align-content: center; }
.cm-ex-hid { display: flex; flex-direction: column; align-items: center; min-width: 30px; padding: 2px 4px; border: 1px solid transparent; border-radius: 7px; }
.cm-ex-hid b { font-size: clamp(15px, 2.8vw, 20px); line-height: 1.1; }
.cm-ex-hid small { font-size: 8pt; color: var(--text-sub); font-weight: 700; }
.cm-ex-badge { position: absolute; top: -7px; right: -4px; min-width: 18px; padding: 0 3px; white-space: nowrap; border-radius: 9px; background: var(--neon-cyan); color: #04141a; font: 800 9pt/18px var(--font-main); font-style: normal; text-align: center; }
.cm-ex-callouts { display: grid; gap: 6px; margin: 0; padding: 0; list-style: none; }
.cm-ex-callout { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 8px; align-items: start; padding: 7px 10px; border: 1px solid var(--border-box-purple); border-left-width: 4px; border-radius: 9px; font-size: 10.5pt; line-height: 1.55; color: var(--text-pure); animation: cm-cell-enter .5s ease both; animation-delay: calc(var(--cm-order, 0) * 130ms); }
.cm-ex-callout .cm-ex-badge { position: static; align-self: start; margin-top: 3px; }
.cm-ex-callout.is-help { border-color: var(--neon-lime); }
.cm-ex-callout.is-lone { border-color: var(--neon-pink); }
.cm-ex-callout.is-hit { border-color: var(--neon-yellow); }
.cm-ex-callout.is-same { border-color: var(--neon-cyan); }
.cm-ex-callout.is-diff { border-color: var(--neon-pink); }
.cm-ex-verdict { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 10px; padding: 16px 6px; }
.cm-ex-chip { padding: 10px 14px; border: 1px solid var(--border-box-purple); border-radius: 12px; font: 800 12pt/1.3 var(--font-main); animation: cm-cell-enter .5s ease both; animation-delay: calc(var(--cm-order, 0) * 160ms); }
.cm-ex-chip.is-help { border-color: var(--neon-lime); background: color-mix(in srgb, var(--neon-lime) 13%, var(--bg-card)); }
.cm-ex-chip.is-lone { border-style: dashed; border-color: var(--neon-pink); background: color-mix(in srgb, var(--neon-pink) 9%, var(--bg-card)); }
.cm-ex-arrow { color: var(--neon-cyan); font-size: 18pt; }
.cm-ex-result { padding: 10px 16px; border-radius: 12px; background: color-mix(in srgb, var(--neon-yellow) 16%, var(--bg-card)); border: 1px solid var(--neon-yellow); font-size: 13pt; animation: cm-cell-enter .6s ease .5s both; }
.cm-ex-ring { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 6px; margin: 0; padding: 0; list-style: none; counter-reset: stage; }
.cm-ex-stage { position: relative; display: flex; flex-direction: column; align-items: center; gap: 1px; min-height: 66px; padding: 7px 2px 5px; border: 1px solid var(--border-box-purple); border-radius: 10px; font: 700 10pt/1.3 var(--font-main); color: var(--text-sub); animation: cm-cell-enter .45s ease both; animation-delay: calc(var(--cm-order, 0) * 70ms); }
.cm-ex-stage::before { counter-increment: stage; content: counter(stage); position: absolute; top: 2px; left: 5px; font-size: 8pt; color: var(--text-muted); }
.cm-ex-stage b { font-size: 18px; color: var(--text-pure); }
.cm-ex-stage small { font-size: 8pt; color: var(--neon-yellow); font-weight: 800; }
.cm-ex-stage.is-start { border-color: var(--neon-cyan); }
.cm-ex-stage.is-hit { border-color: var(--neon-yellow); background: color-mix(in srgb, var(--neon-yellow) 14%, var(--bg-card)); color: var(--text-pure); }
@media (max-width: 600px) {
  .cm-ex-table { grid-template-columns: 42px repeat(var(--cm-cols, 4), minmax(0, 1fr)); gap: 4px; }
  .cm-ex-row { font-size: 8pt; }
  .cm-ex-cell { font-size: 9.5pt; min-height: 42px; }
  .cm-ex-cell.cm-ex-hidden { gap: 1px; padding: 3px 1px; }
  .cm-ex-hid { min-width: 21px; padding: 1px; }
  .cm-ex-hid b { font-size: 14px; }
  .cm-ex-hid small { font-size: 7pt; }
  .cm-ex-callout { font-size: 10pt; padding: 6px 8px; }
  .cm-ex-ring { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
/* 2회차 장면 — 칩 줄·60갑자 표·월률분야 막대·온도계·대운 타임라인 */
.cm-ex-chips { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; align-items: stretch; }
.cm-ex-pill { display: flex; flex-direction: column; align-items: center; justify-content: center; min-width: 44px; padding: 7px 11px; border: 1px solid var(--border-box-purple); border-radius: 11px; background: var(--bg-card); color: var(--text-pure); animation: cm-cell-enter .45s ease both; animation-delay: calc(var(--cm-order, 0) * 90ms); }
.cm-ex-pill b { font: 800 13pt/1.25 var(--font-main); }
.cm-ex-pill small { font: 700 9pt/1.3 var(--font-main); color: var(--text-sub); }
.cm-ex-pill.is-hit { border-color: var(--neon-yellow); background: color-mix(in srgb, var(--neon-yellow) 14%, var(--bg-card)); }
.cm-ex-pill.is-help { border-color: var(--neon-lime); background: color-mix(in srgb, var(--neon-lime) 13%, var(--bg-card)); }
.cm-ex-pill.is-lone { border-style: dashed; border-color: var(--neon-pink); background: color-mix(in srgb, var(--neon-pink) 9%, var(--bg-card)); }
.cm-ex-pill.cm-ex-sym { min-width: 0; padding: 0 2px; border: 0; background: none; color: var(--neon-cyan); }
.cm-ex-chain { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 6px; }
.cm-ex-chain-arrow { color: var(--neon-cyan); font-style: normal; font-weight: 800; }
.cm-ex-cell.ele-木, .cm-ex-hid.ele-木 { border-color: var(--neon-lime); background: color-mix(in srgb, var(--neon-lime) 10%, var(--bg-card)); }
.cm-ex-cell.ele-火, .cm-ex-hid.ele-火 { border-color: var(--neon-pink); background: color-mix(in srgb, var(--neon-pink) 10%, var(--bg-card)); }
.cm-ex-cell.ele-土, .cm-ex-hid.ele-土 { border-color: var(--neon-yellow); background: color-mix(in srgb, var(--neon-yellow) 10%, var(--bg-card)); }
.cm-ex-cell.ele-金, .cm-ex-hid.ele-金 { border-color: var(--text-sub); background: color-mix(in srgb, var(--text-sub) 12%, var(--bg-card)); }
.cm-ex-cell.ele-水, .cm-ex-hid.ele-水 { border-color: var(--neon-cyan); background: color-mix(in srgb, var(--neon-cyan) 10%, var(--bg-card)); }
.cm-ex-grid60 { display: grid; grid-template-columns: repeat(10, minmax(0, 1fr)); gap: 3px; }
.cm-ex-grid60.has-sun { grid-template-columns: 44px repeat(10, minmax(0, 1fr)); }
.cm-ex-g { position: relative; display: grid; place-items: center; min-height: 30px; border: 1px solid var(--border-box-purple); border-radius: 6px; font: 700 10pt/1 var(--font-main); color: var(--text-sub); }
.cm-ex-g.is-marked { color: var(--text-pure); font-weight: 800; animation: cm-cell-enter .5s ease both; }
.cm-ex-g.is-focus { border-color: var(--neon-cyan); background: color-mix(in srgb, var(--neon-cyan) 16%, var(--bg-card)); }
.cm-ex-g.is-hit { border-color: var(--neon-yellow); background: color-mix(in srgb, var(--neon-yellow) 16%, var(--bg-card)); }
.cm-ex-g .cm-ex-badge { top: -8px; right: -5px; }
.cm-ex-sun { display: grid; place-items: center; font: 700 8pt/1.2 var(--font-main); color: var(--text-sub); }
.cm-ex-sun.is-hit { color: var(--neon-yellow); }
.cm-ex-barwrap { position: relative; padding-top: 26px; }
.cm-ex-bar { display: flex; gap: 3px; min-height: 52px; }
.cm-ex-seg { display: flex; flex-direction: column; align-items: center; justify-content: center; min-width: 40px; border: 1px solid var(--border-box-purple); border-radius: 9px; background: var(--bg-card); }
.cm-ex-seg b { font-size: 16pt; }
.cm-ex-seg small { color: var(--text-sub); font-weight: 700; }
.cm-ex-seg.is-hit { border-color: var(--neon-yellow); background: color-mix(in srgb, var(--neon-yellow) 14%, var(--bg-card)); }
.cm-ex-marker { position: absolute; top: 0; transform: translateX(-50%); padding: 2px 8px; border-radius: 10px; background: var(--neon-cyan); color: #04141a; font: 800 9pt/1.4 var(--font-main); font-style: normal; white-space: nowrap; }
.cm-ex-marker::after { content: ''; position: absolute; left: 50%; bottom: -5px; margin-left: -5px; border: 5px solid transparent; border-top-color: var(--neon-cyan); border-bottom: 0; }
.cm-ex-thermo { display: grid; grid-template-columns: repeat(9, minmax(0, 1fr)); gap: 3px; }
.cm-ex-tick { display: grid; place-items: center; min-height: 26px; border-radius: 6px; background: linear-gradient(90deg, color-mix(in srgb, var(--neon-cyan) 25%, var(--bg-card)), color-mix(in srgb, var(--neon-pink) 25%, var(--bg-card))); font: 800 10pt/1 var(--font-main); color: var(--text-pure); }
.cm-ex-tick.is-edge { opacity: .6; }
.cm-ex-tick.is-hit { outline: 2px solid var(--neon-yellow); opacity: 1; }
.cm-ex-timeline { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 6px; }
.cm-ex-time { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 9px 3px; border: 1px solid var(--border-box-purple); border-top: 4px solid var(--neon-cyan); border-radius: 10px; background: var(--bg-card); animation: cm-cell-enter .45s ease both; animation-delay: calc(var(--cm-order, 0) * 90ms); }
.cm-ex-time b { font-size: 16pt; }
.cm-ex-time span, .cm-ex-time small { font-size: 9pt; color: var(--text-sub); font-weight: 700; text-align: center; }
.cm-ex-time.is-edge { border-top-color: var(--neon-pink); }
@media (max-width: 600px) {
  .cm-ex-g { min-height: 26px; font-size: 9pt; }
  .cm-ex-grid60.has-sun { grid-template-columns: 30px repeat(10, minmax(0, 1fr)); }
  .cm-ex-timeline { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .cm-ex-pill { padding: 6px 8px; }
}
@media (prefers-reduced-motion: reduce) {
  .concept-motion *, .concept-motion *::before { animation: none !important; transition: none !important; }
}
