/* ── Capital decision journey (landing) ──────────────────────────────────────
   Eight-stage interactive walkthrough. Built on the capvium.css tokens only;
   the canvas palette in capvium-journey.js mirrors the same values. */
.cvj { border-top: 1px solid var(--rule); }
.cvj-head { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 24px; align-items: end; }
.cvj-head .cv-lead { margin-top: 18px; max-width: 34em; }

.cvj-player {
  margin-top: clamp(32px, 4vw, 56px);
  display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(0, 1fr);
  background: var(--white); border: 1px solid var(--rule); outline: none;
}
.cvj-player:focus-visible { box-shadow: 0 0 0 3px rgba(13, 137, 135, .35); }
.cvj-stage { position: relative; aspect-ratio: 720 / 440; border-right: 1px solid var(--rule); cursor: ew-resize; touch-action: pan-y; }
.cvj-canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.cvj-progress { position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: var(--rule); }
.cvj-progress i { display: block; height: 100%; width: 0; background: var(--accent); }

.cvj-caption { padding: clamp(24px, 2.6vw, 40px); display: flex; flex-direction: column; min-width: 0; }
.cvj-cap-num { font-family: var(--mono); font-size: 13px; color: var(--muted); margin: 14px 0 8px; }
.cvj-cap-title { font-family: var(--display); font-weight: 500; font-size: clamp(26px, 2.5vw, 36px); line-height: 1.06; letter-spacing: -0.02em; color: var(--ink); margin: 0; }
.cvj-cap .cv-body { margin-top: 16px; max-width: 34ch; }
.cvj-cap .cv-kicker { color: var(--accent); }
.cvj-cap-anim { animation: cvjIn .5s ease both; }
@keyframes cvjIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

.cvj-controls { margin-top: auto; padding-top: 28px; display: flex; align-items: center; gap: 12px; }
.cvj-btn {
  appearance: none; width: 42px; height: 42px; border-radius: 50%;
  border: 1px solid var(--rule); background: var(--surface-alt); color: var(--ink);
  display: grid; place-items: center; cursor: pointer;
}
.cvj-btn:hover { border-color: var(--accent); color: var(--accent); }
.cvj-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.cvj-btn svg { width: 16px; height: 16px; }
.cvj-time { font-family: var(--mono); font-size: 12px; color: var(--muted); white-space: nowrap; }

/* Rail: phases, icons, track, dots — doubles as the chapter picker */
.cvj-rail { margin-top: clamp(32px, 4vw, 52px); }
.cvj-phases { display: grid; grid-template-columns: repeat(4, 1fr); gap: 28px; margin-bottom: 22px; }
.cvj-phase {
  position: relative; text-align: center; padding-bottom: 14px;
  font-family: var(--body); font-size: 12px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase;
  color: var(--gunmetal-blue); transition: color .3s;
}
.cvj-phase::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 10px;
  border: 1px solid #B8BCC2; border-bottom: 0; transition: border-color .3s;
}
.cvj-phase.is-on { color: var(--accent); }
.cvj-phase.is-on::after { border-color: var(--accent); }

.cvj-steps-wrap { position: relative; }
.cvj-steps { position: relative; display: grid; grid-template-columns: repeat(8, 1fr); list-style: none; margin: 0; padding: 0; }
.cvj-track, .cvj-fill { position: absolute; top: 81px; left: 6.25%; height: 2px; }
.cvj-track { right: 6.25%; background: #C4C8CD; }
.cvj-fill { width: 0; background: var(--accent); }
.cvj-step { position: relative; z-index: 1; }
.cvj-step button {
  appearance: none; background: none; border: 0; padding: 0 4px 6px; width: 100%; cursor: pointer;
  font: inherit; color: inherit; display: flex; flex-direction: column; align-items: center; text-align: center;
}
.cvj-step button:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
.cvj-icon { width: 56px; height: 56px; color: var(--gunmetal-blue); transition: color .3s, transform .3s; }
.cvj-icon svg { width: 100%; height: 100%; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.cvj-dot {
  width: 18px; height: 18px; margin-top: 16px; border-radius: 50%;
  background: var(--white); border: 1.5px solid #9AA0A8;
  transition: background .3s, border-color .3s, transform .3s;
}
.cvj-num { font-family: var(--mono); font-size: 13px; letter-spacing: .08em; color: var(--gunmetal-blue); margin-top: 14px; }
.cvj-label { font-size: 15px; line-height: 1.3; margin-top: 8px; color: var(--gunmetal-blue); max-width: 12ch; transition: color .3s; }
.cvj-step.is-done .cvj-dot { background: var(--accent); border-color: var(--accent); }
.cvj-step.is-done .cvj-icon { color: var(--ink); }
.cvj-step.is-active .cvj-icon { color: var(--accent); transform: translateY(-3px); }
.cvj-step.is-active .cvj-dot { background: var(--white); border: 5px solid var(--accent); transform: scale(1.2); }
.cvj-step.is-active .cvj-num { color: var(--accent); }
.cvj-step.is-active .cvj-label,
.cvj-step button:hover .cvj-label { color: var(--ink); }

@media (max-width: 900px) {
  .cvj-head { grid-template-columns: 1fr; }
  .cvj-player { grid-template-columns: 1fr; }
  .cvj-stage { border-right: 0; border-bottom: 1px solid var(--rule); }
  .cvj-cap .cv-body { max-width: none; }
  .cvj-phases, .cvj-track, .cvj-fill { display: none; }
  .cvj-steps { grid-template-columns: repeat(4, 1fr); row-gap: 22px; }
  .cvj-icon { width: 36px; height: 36px; }
  .cvj-dot { width: 14px; height: 14px; margin-top: 10px; }
  .cvj-num { font-size: 12px; margin-top: 8px; }
  .cvj-label { font-size: 13px; }
}
@media (prefers-reduced-motion: reduce) {
  .cvj-cap-anim { animation: none; }
  .cvj-icon, .cvj-dot, .cvj-label, .cvj-phase { transition: none; }
}

.pgn-insp {
  position: absolute; top: 12px; right: 12px; bottom: 12px; z-index: 2; width: min(310px, 54%);
  background: var(--white); border: 1px solid var(--rule); box-shadow: 0 14px 36px rgba(11, 18, 32, .16);
  padding: 16px 16px 14px; overflow: auto; font-size: 13px; line-height: 1.5; color: var(--ink);
  animation: cvjIn .25s ease both;
}
.pgn-insp[hidden] { display: none; }
.pgn-x { position: absolute; top: 8px; right: 8px; width: 28px; height: 28px; border: 0; background: none; cursor: pointer;
  font-size: 20px; line-height: 1; color: var(--muted); }
.pgn-x:hover { color: var(--ink); }
.pgn-x:focus-visible { outline: 2px solid var(--accent); }
.pgn-type { display: flex; align-items: center; gap: 7px; margin: 0; font-size: 11px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.pgn-type i { width: 9px; height: 9px; border-radius: 50%; display: inline-block; }
.pgn-insp h4 { font-family: var(--display); font-size: 20px; font-weight: 500; letter-spacing: -.01em; margin: 6px 28px 10px 0; line-height: 1.15; }
.pgn-pill { display: inline-block; padding: 3px 10px; border-radius: 999px; font-size: 12px; font-weight: 600; }
.pgn-pill--bad { background: #F6D9D7; color: var(--sig-bad); }
.pgn-pill--warn { background: #F5E3CC; color: #9A5B10; }
.pgn-pill--good { background: #D6EEEC; color: var(--viridian); }
.pgn-h { margin: 14px 0 4px; font-size: 11px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.pgn-insp p { margin: 0; }
.pgn-insp dl { display: grid; grid-template-columns: 1fr auto; gap: 4px 12px; margin: 12px 0 0; padding: 10px 0 0; border-top: 1px solid var(--rule); }
.pgn-insp dt { color: var(--muted); }
.pgn-insp dd { margin: 0; font-family: var(--mono); font-size: 12px; text-align: right; }
.pgn-insp ul { list-style: none; margin: 0; padding: 0; }
.pgn-insp li { padding: 3px 0; color: var(--muted); }
.pgn-insp li b { color: var(--accent); font-weight: 500; }
.pgn-note { margin-top: 12px !important; font-size: 11px; color: var(--muted); }
@media (max-width: 900px) {
  .pgn-insp { left: 8px; right: 8px; top: 8px; bottom: 8px; width: auto; }
}

/* ── Prognode: dark "control room" — chapters as a tiny network, film subtitles ── */
.pgn { border-top: 1px solid var(--rule-on-dark); }
.pgn-player { margin-top: clamp(28px, 3.5vw, 48px); outline: none; }
.pgn-player:focus-visible { box-shadow: 0 0 0 3px rgba(79, 211, 196, .4); }
.pgn-chapters-wrap { position: relative; max-width: 860px; margin: 0 auto 22px; }
.pgn-chapters { position: relative; display: grid; grid-template-columns: repeat(7, 1fr); list-style: none; margin: 0; padding: 0; }
.pgn-chapters-line, .pgn-chapters-fill { position: absolute; top: 9px; left: 7.143%; height: 2px; }
.pgn-chapters-line { right: 7.143%; background: var(--rule-on-dark); }
.pgn-chapters-fill { width: 0; background: #4FD3C4; box-shadow: 0 0 10px rgba(79, 211, 196, .6); }
.pgn-ch { appearance: none; background: none; border: 0; padding: 0; cursor: pointer; color: var(--muted-on-dark);
  display: flex; flex-direction: column; align-items: center; gap: 10px; font: inherit; position: relative; z-index: 1; }
.pgn-ch:focus-visible { outline: 2px solid #4FD3C4; outline-offset: 4px; }
.pgn-ch-dot { width: 20px; height: 20px; border-radius: 50%; background: var(--surface-dark); border: 2px solid #4A5566; transition: all .3s; }
.pgn-ch-k { font-family: var(--mono); font-size: 12px; letter-spacing: .12em; text-transform: uppercase; transition: color .3s; }
.pgn-ch.is-done .pgn-ch-dot { background: #4FD3C4; border-color: #4FD3C4; }
.pgn-ch.is-on .pgn-ch-dot { border-color: #4FD3C4; box-shadow: 0 0 0 6px rgba(79, 211, 196, .18); background: var(--surface-dark); }
.pgn-ch.is-on .pgn-ch-k, .pgn-ch:hover .pgn-ch-k { color: var(--white); }
.pgn-screen { position: relative; aspect-ratio: 720 / 440; border: 1px solid var(--rule-on-dark); border-radius: 14px; overflow: hidden; background: var(--surface-dark); }
.pgn-screen canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.pgn-subbar { position: absolute; left: 0; right: 0; bottom: 0; padding: 38px 20px 16px; display: flex; align-items: flex-end; gap: 14px;
  background: linear-gradient(180deg, rgba(11, 18, 32, 0), rgba(11, 18, 32, .92) 55%); pointer-events: none; }
.pgn-sub { flex: 1; margin: 0; font-family: var(--display); font-weight: 500; font-size: clamp(17px, 1.9vw, 26px); letter-spacing: -.01em; color: var(--white); min-height: 1.2em; }
.pgn-sub.is-typing::after { content: ""; display: inline-block; width: .08em; height: .9em; margin-left: 3px; background: #4FD3C4; vertical-align: -.1em; animation: pgnBlink .8s steps(1) infinite; }
@keyframes pgnBlink { 50% { opacity: 0; } }
.pgn-play { pointer-events: auto; appearance: none; width: 38px; height: 38px; border-radius: 50%; border: 1px solid rgba(255, 255, 255, .25);
  background: rgba(255, 255, 255, .06); color: var(--white); display: grid; place-items: center; cursor: pointer; flex: none; }
.pgn-play svg { width: 14px; height: 14px; }
.pgn-play:focus-visible { outline: 2px solid #4FD3C4; outline-offset: 2px; }
.pgn-progress { position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: rgba(255, 255, 255, .08); }
.pgn-progress i { display: block; height: 100%; width: 0; background: #4FD3C4; }
.pgn .pgn-insp { background: #161C29; border-color: rgba(255, 255, 255, .12); color: #E9EDF2; box-shadow: 0 18px 40px rgba(0, 0, 0, .45); }
.pgn .pgn-insp dd, .pgn .pgn-insp h4 { color: #E9EDF2; }
.pgn .pgn-insp dl { border-color: rgba(255, 255, 255, .12); }
.pgn .pgn-x { color: #9AA3AF; }
.pgn .pgn-pill--bad { background: rgba(232, 132, 140, .18); color: #F2A6AC; }
.pgn .pgn-pill--warn { background: rgba(224, 160, 74, .18); color: #F0C07F; }
.pgn .pgn-pill--good { background: rgba(79, 211, 196, .16); color: #7FE3D7; }

/* ── Atelier: editorial studio — big beat index, one margin note ── */
.atl-grid { display: grid; grid-template-columns: minmax(0, .75fr) minmax(0, 2.4fr); gap: clamp(24px, 3vw, 48px); align-items: center; margin-top: clamp(32px, 4vw, 56px); }
.atl-beats { list-style: none; margin: 0; padding: 0; }
.atl-beat { appearance: none; background: none; border: 0; padding: 6px 0; width: 100%; cursor: pointer; text-align: left;
  display: grid; grid-template-columns: 40px 1fr; align-items: baseline; column-gap: 8px; font: inherit; color: inherit; }
.atl-beat:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
.atl-beat-n { font-family: var(--mono); font-size: 12px; color: var(--muted); }
.atl-beat-w { font-family: var(--display); font-weight: 500; font-size: clamp(30px, 3.4vw, 52px); line-height: 1.05; letter-spacing: -.03em;
  color: var(--kawaii-silver); transition: color .35s, transform .35s; transform-origin: left center; }
.atl-beat-bar { grid-column: 2; height: 2px; margin-top: 6px; background: transparent; }
.atl-beat-bar i { display: block; height: 100%; width: 0; background: var(--accent); }
.atl-beat.is-done .atl-beat-w { color: var(--funky-gray); }
.atl-beat.is-on .atl-beat-w { color: var(--ink); transform: translateX(6px); }
.atl-beat.is-on .atl-beat-n { color: var(--accent); }
.atl-beat:hover .atl-beat-w { color: var(--ink); }
.atl-stage { outline: none; }
.atl-stage:focus-visible .atl-screen { box-shadow: 0 0 0 3px rgba(13, 137, 135, .35); }
.atl-screen { position: relative; aspect-ratio: 720 / 440; background: var(--white); border: 1px solid var(--rule); border-radius: 4px 24px 4px 24px; overflow: hidden; }
.atl-screen canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.atl-play { position: absolute; right: 12px; bottom: 12px; z-index: 1; appearance: none; cursor: pointer; padding: 6px 14px; border-radius: 999px;
  border: 1px solid var(--rule); background: rgba(255, 255, 255, .92); font-family: var(--mono); font-size: 11px; letter-spacing: .1em;
  text-transform: uppercase; color: var(--muted); }
.atl-play:hover { color: var(--ink); border-color: var(--ink); }
.atl-play:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.pgn-note a { color: var(--accent); }

@media (max-width: 900px) {
  .pgn-ch-k { font-size: 10px; letter-spacing: .06em; }
  .pgn-subbar { padding: 24px 12px 10px; }
  .atl-grid { grid-template-columns: 1fr; }
  .atl-beats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin: 20px 0; }
  .atl-beat { grid-template-columns: 1fr; }
  .atl-beat-w { font-size: 22px; }
  .atl-beat-bar { grid-column: 1; }
}
@media (prefers-reduced-motion: reduce) { .pgn-sub.is-typing::after { animation: none; } }
