/* IA para pymes: the conversation is the figure; the assistant's reply carries the concrete result and its source */
  #fig-bot { display: flex; flex-direction: column; overflow: hidden; }
  #fig-bot .counter { font-variant-numeric: tabular-nums; color: var(--ink); }
  #fig-bot .flow-foot { flex-wrap: wrap; }
  #fig-bot .flow-foot .counter { flex: 1 1 15em; }
  #fig-bot .flow-foot .btn { flex: none; white-space: nowrap; }
  .pi-bar { display: inline-flex; align-items: center; gap: 12px; min-width: 0; }
  .pi-status { display: inline-flex; align-items: center; gap: 8px; color: #3E6B4A; white-space: nowrap; }
  .pi-status i { width: 8px; height: 8px; border-radius: 50%; background: #5E8C6A; box-shadow: 0 0 0 3px color-mix(in srgb, #5E8C6A 22%, transparent); }
  .pi-br { flex: 1; display: flex; flex-direction: column; justify-content: center; }
  .pi-chat { display: flex; flex-direction: column; gap: 12px; min-height: 292px; font: 500 14px/1.4 var(--sans); }
  .pi-msg { position: relative; margin: 0; padding: 8px 12px; border-radius: 12px; animation: pi-pop .35s var(--ease) both; }
  .pi-who { display: block; margin-bottom: 4px; font: 600 12px/1.2 var(--mono); letter-spacing: .02em; }
  .pi-in { align-self: flex-start; max-width: 88%; background: var(--surface); color: var(--ink); border: 1px solid var(--line); border-bottom-left-radius: 4px; }
  .pi-in .pi-who { color: var(--ink-2); }
  .pi-turn { display: flex; align-items: flex-end; gap: 8px; align-self: flex-end; max-width: 100%; }
  .pi-turn .pi-out { min-width: 0; flex: 0 1 340px; }
  .pi-out { background: var(--river-tint); color: var(--ink); border: 1px solid color-mix(in srgb, var(--river-ink) 28%, transparent); border-bottom-right-radius: 4px; }
  .pi-out .pi-who { color: var(--river-ink); }
  .pi-reply { display: block; }
  .pi-card { margin-top: 8px; padding: 8px 12px; border-radius: 8px; background: var(--surface); border: 1px solid var(--line); }
  .pi-card-title { display: block; font: 600 15px/1.3 var(--sans); color: var(--ink); }
  .pi-rows { margin: 4px 0 0; }
  .pi-rows div { display: flex; justify-content: space-between; gap: 12px; padding: 4px 0; border-top: 1px solid var(--line); font-size: 14px; }
  .pi-rows div:first-child { border-top: 0; }
  .pi-rows dt { color: var(--ink-2); }
  .pi-rows dd { margin: 0; font-weight: 600; text-align: right; }
  .pi-src { display: inline-block; margin-top: 8px; padding: 4px 8px; border-radius: 8px; background: var(--terra-tint); color: var(--terra-ink); font: 600 12px/1.4 var(--mono); }
  .pi-avatar { flex: none; width: 40px; height: 40px; padding: 0; border: 0; border-radius: 50%; background: none; cursor: pointer; }
  .pi-avatar svg { display: block; width: 100%; height: 100%; }
  .pi-avatar:focus-visible { outline: 2px solid var(--terra-ink); outline-offset: 2px; }
  .pi-av-bg { fill: var(--paper); stroke: var(--line); }
  .pi-av-head { fill: var(--surface); stroke: var(--ink-2); stroke-width: 1.2px; }
  .pi-av-visor { fill: var(--petrol); }
  .pi-av-eye { fill: var(--river); }
  .pi-av-ant { stroke: var(--ink-2); stroke-width: 1.2px; }
  .pi-av-bulb { fill: var(--terra); }
  .pi-typing { display: none; position: absolute; left: 12px; top: 32px; gap: 4px; }
  .pi-typing i { width: 8px; height: 8px; border-radius: 50%; background: var(--river-ink); animation: pi-dot 1s ease-in-out infinite; }
  .pi-typing i:nth-child(2) { animation-delay: .15s; } .pi-typing i:nth-child(3) { animation-delay: .3s; }
  @keyframes pi-dot { 0%, 100% { opacity: .35; transform: translateY(0); } 50% { opacity: 1; transform: translateY(-3px); } }
  @keyframes pi-pop { from { opacity: 0; transform: translateY(8px); } }
  .pi-br[data-phase="look"] .pi-typing { display: flex; }
  .pi-br[data-phase="look"] .pi-body { visibility: hidden; }
  .pi-br[data-phase="ask"] .pi-turn { visibility: hidden; }
  .pi-br[data-off] *, .pi-br[data-off] *::before { animation-play-state: paused !important; }
  /* Message chips (footer). */
  .pi-kinds { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
  .pi-kind { min-height: 40px; padding: 8px 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--cream); color: var(--ink); font: 600 14px/1 var(--sans); cursor: pointer; }
  .pi-kind:hover { border-color: var(--ink-2); }
  .pi-kind:focus-visible { outline: 2px solid var(--terra-ink); outline-offset: 2px; }
  .pi-kind[aria-pressed="true"] { background: var(--petrol); border-color: var(--petrol); color: var(--cream); }
  @media (max-width: 560px) { .pi-chat { min-height: 336px; } }
  @media (prefers-reduced-motion: reduce) { .pi-br *, .pi-br *::before { transition: none !important; animation: none !important; } .pi-typing i { opacity: .7; } }
