/* AI references extend the shared StackSprints theme. */
.ai-diagram { margin: 20px 0; }
.ai-diagram figcaption { color: var(--muted); font-size: .88rem; text-align: left; }
.diagram-toggle { background: #16233f; border: 1px solid var(--line); border-radius: 8px; color: var(--text); cursor: pointer; font: inherit; font-size: .82rem; padding: 8px 14px; }
.diagram-toggle[aria-pressed="true"] { border-color: var(--cyan); }
.ai-diagram.diagram-playing .flowchart-link { stroke-dasharray: 8 6; animation: ai-flow 1.4s linear infinite; }
@keyframes ai-flow { to { stroke-dashoffset: -28; } }
.ai-journey { background: #0d1422; border: 1px solid var(--line); border-radius: 14px; margin-block: 20px; padding: 20px; }
.journey-steps { display: grid; gap: 8px; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); list-style: none; padding: 0; }
.journey-steps button { background: #111827; border: 1px solid var(--line); border-radius: 8px; color: var(--text); cursor: pointer; font: inherit; padding: 12px 10px; text-align: left; width: 100%; }
.journey-steps button[aria-pressed="true"] { background: linear-gradient(110deg, #17335d, #2c2350); border-color: var(--cyan); }
.journey-detail { min-height: 5em; }
.ai-journey .actions, .reference-links { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 20px; }
.component-card { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 20px; min-width: 0; }
.component-card h3 { margin-top: 0; }
.component-card dt { color: #a8c6ff; font-weight: 700; margin-top: 12px; }
.component-card dd { color: #c7d0e0; margin: 4px 0 0; }
button:focus-visible, a:focus-visible { outline: 2px solid var(--cyan); outline-offset: 4px; }
@media (prefers-reduced-motion: reduce) {
  .ai-diagram.diagram-playing .flowchart-link { animation: none !important; stroke-dasharray: none; }
}
@media print {
  .diagram-toggle, .journey-play, .journey-reset { display: none; }
}
