.conversation-section { --conversation-padding: 72px 24px 120px; background: #fff; padding: var(--conversation-padding); }
/* The handoff pins the surface with CSS sticky positioning, which the browser keeps in
   step with its own scrolling. A JavaScript transform recomputed on each scroll event
   shakes on iOS Safari, where scrolling runs ahead of scripts. The section starts two
   viewports before the story ends: the surface reaches its natural place one viewport
   early, sticks there while the ::after spacer scrolls past, then flows normally.
   z-index keeps it above the closing section, which overlaps its last viewport. */
.conversation-section.has-scene-handoff { position: relative; z-index: 1; margin-top: -200svh; padding: 0; pointer-events: none; }
.has-scene-handoff .conversation-surface { pointer-events: auto; position: sticky; top: 0; min-height: 100svh; padding: var(--conversation-padding); background: #fff; transform-origin: 50% 0; }
.conversation-section.has-scene-handoff::after { content: ""; display: block; height: 100svh; }
.has-closing-handoff .conversation-intro, .has-closing-handoff .conversation-demo {
  --vapor: clamp(0, calc(var(--conversation-exit, 0) * 1.2 - var(--vapor-order, 0) * .15), 1);
  opacity: calc(1 - var(--vapor));
  filter: blur(calc(var(--vapor) * 12px));
  transform: translateY(calc(var(--vapor) * -42px)) scale(calc(1 + var(--vapor) * .035));
}
.has-closing-handoff .conversation-demo { --vapor-order: 1; }
.conversation-intro { max-width: 760px; margin: 0 auto 52px; text-align: center; }
.conversation-intro h2 { margin: 0; font: 400 clamp(2.5rem, 4.8vw, 4.4rem) / 1.06 Georgia, "Times New Roman", serif; letter-spacing: -.04em; }
.conversation-intro h2 em { font-weight: 400; color: var(--leaf); }
.conversation-intro p { margin: 22px 0 0; color: var(--muted); font-size: clamp(.95rem, 1.35vw, 1.1rem); line-height: 1.6; text-wrap: balance; }
.conversation-demo { max-width: 780px; margin: auto; }
.conversation-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 42px; margin-bottom: 16px; color: var(--muted); font-size: .75rem; letter-spacing: .025em; }
.conversation-playback { padding: 10px 0 10px 12px; background: none; border: 0; color: var(--leaf); text-decoration: underline; text-underline-offset: 4px; font-size: .8rem; }
.conversation-question { width: 85%; margin-left: auto; border-radius: 22px 22px 5px 22px; background: #f0f3e9; padding: 22px 26px; }
.conversation-speaker { display: block; margin-bottom: 8px; color: var(--leaf); font-size: .75rem; font-weight: 600; }
.conversation-question p { margin: 0; font-size: 1rem; line-height: 1.65; }
.conversation-response { position: relative; margin-top: 28px; }
.conversation-retrieval { position: absolute; top: 0; left: 0; right: 0; padding: 16px 14px; border-left: 1px solid var(--line); color: var(--muted); font-size: .8rem; }
.retrieval-label { display: block; margin-bottom: 14px; }
.retrieval-dots { display: inline-block; animation: memory-looking 1.2s ease-in-out infinite; }
.conversation-retrieval ol { display: flex; flex-wrap: wrap; gap: 12px 25px; padding: 0; margin: 0; list-style: none; }
.conversation-retrieval li { opacity: .3; transition: opacity .3s; }
.conversation-retrieval li.is-found { opacity: 1; }
.conversation-retrieval li > span:last-child { display: block; margin: 4px 0 0 17px; font-size: .7rem; }
.retrieval-check { opacity: 0; color: var(--leaf); margin-right: 3px; }
.is-found .retrieval-check { opacity: 1; }
.conversation-answer { padding: 27px 30px; border: 1px solid #e6e9df; border-radius: 5px 22px 22px; }
.conversation-assistant { display: flex; align-items: center; gap: 11px; margin-bottom: 19px; font-size: .85rem; font-weight: 600; }
.conversation-mark { width: 34px; height: 36px; overflow: hidden; flex: 0 0 auto; }
.conversation-mark .feature-brand { width: 144px; margin: 0; }
.conversation-answer-text { position: relative; }
.conversation-answer-source p, .conversation-answer-typed p { font-size: .975rem; line-height: 1.7; margin: 0 0 16px; }
.conversation-answer-source strong, .conversation-answer-typed strong { font-weight: 600; }
.conversation-task-summary { padding-top: 4px; }
.conversation-task-summary span { white-space: nowrap; }
.conversation-task-summary span:first-of-type { color: var(--leaf); }
.conversation-sources { color: var(--muted); font-size: .75rem; line-height: 1.5; margin: 22px 0 16px; }
.conversation-report summary { display: flex; justify-content: space-between; align-items: center; gap: 16px; list-style: none; cursor: pointer; padding: 14px 0 0; border-top: 1px solid var(--line); font-size: .85rem; font-weight: 500; }
.conversation-report summary::-webkit-details-marker { display: none; }
.conversation-report summary:focus-visible { outline: 2px solid var(--leaf); outline-offset: 5px; }
.conversation-report[open] summary > span { transform: rotate(90deg); }
.conversation-report-body { padding-top: 24px; }
.conversation-report h3 { margin: 0; font-size: 1rem; font-weight: 600; }
.conversation-report p { font-size: .85rem; line-height: 1.65; color: var(--muted); margin: 9px 0 20px; }
.conversation-report table { border-collapse: collapse; width: 100%; text-align: left; font-size: .85rem; }
.conversation-report caption { text-align: left; margin-bottom: 15px; color: var(--muted); font-size: .75rem; }
.conversation-report th, .conversation-report td { padding: 12px 8px; border-bottom: 1px solid #e6e9df; }
.conversation-report th { font-weight: 500; }
.conversation-report thead th { color: var(--muted); font-size: .75rem; }
.conversation-report td, .conversation-report thead th:not(:first-child) { text-align: right; }
.conversation-report tbody th span { display: block; margin-top: 4px; color: var(--muted); font-size: .75rem; }
.conversation-report tfoot th, .conversation-report tfoot td { font-weight: 600; border: 0; }
.conversation-status { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
.conversation-demo.is-playing .conversation-answer-source { opacity: 0; }
.conversation-answer-typed { position: absolute; inset: 0; pointer-events: none; }
.conversation-demo.is-waiting .conversation-answer { visibility: hidden; }
.conversation-demo.is-waiting .conversation-question { opacity: 0; transform: translateY(12px); }
.conversation-demo .conversation-question { transition: opacity .4s, transform .4s; }
.conversation-demo.is-question-sent .conversation-question { opacity: 1; transform: none; }
@keyframes memory-looking { 50% { opacity: .25; } }
@media (min-width: 601px) {
  .conversation-section { --conversation-padding: 24px 24px 28px; min-height: 100svh; }
  .conversation-intro { margin-bottom: 24px; }
  .conversation-intro p { margin-top: 16px; }
  .conversation-question { padding-top: 18px; padding-bottom: 18px; }
  .conversation-response { margin-top: 20px; }
  .conversation-answer { padding-top: 23px; padding-bottom: 23px; }
  .conversation-answer-source p, .conversation-answer-typed p { margin-bottom: 12px; }
}
@media (max-width: 600px) {
  .conversation-section { --conversation-padding: 48px 20px 80px; }
  .conversation-intro { margin-bottom: 35px; }
  .conversation-question { width: 94%; padding: 19px 20px; }
  .conversation-question p { font-size: .925rem; }
  .conversation-answer { padding: 23px 19px; }
  .conversation-answer-source p, .conversation-answer-typed p { font-size: .925rem; }
  .conversation-retrieval ol { gap: 12px 17px; }
  .conversation-report th, .conversation-report td { padding-left: 2px; padding-right: 2px; font-size: .8rem; }
}
