/* A persistent call, with a separate text conversation mode. */
[hidden] { display: none !important; }
.avatar-stage, .chat-panel { height: 690px; min-height: 690px; }
.stage-top { align-items: center; gap: 14px; left: 24px; right: 24px; }
.interaction-switch { display: flex; gap: 3px; padding: 4px; border: 1px solid #ddd5ed; border-radius: 12px; background: #ffffff80; }
.interaction-switch button { min-height: 36px; padding: 6px 12px; border: 0; border-radius: 8px; background: transparent; color: #736682; font-size: 13px; white-space: nowrap; }
.interaction-switch button[aria-pressed=true] { color: #5e468a; background: #fff; box-shadow: 0 2px 6px #513a7510; font-weight: 600; }
.avatar-figure { top: 72px; width: 292px; }
.avatar-ground { top: 366px; }
.stage-caption { bottom: 239px; }
.stage-caption h2 { margin: 8px 0; }
.stage-caption p { margin: 0; line-height: 1.6; }
.label-voice { top: 164px; left: 30px; }
.label-companion { top: 290px; right: 25px; }
.voice-panel { position: absolute; bottom: 22px; left: 24px; right: 24px; z-index: 2; }
.voice-panel .recording-notice { text-align: center; margin: 0 0 10px; color: #74677f; font-size: 11px; }
.voice-panel .notice { position: absolute; bottom: 100%; left: 0; right: 0; z-index: 3; box-shadow: 0 3px 20px #47324e10; }
.avatar-stage:has(#notice:not([hidden])) .stage-caption { visibility: hidden; }
.call-status-row { display: flex; align-items: center; justify-content: center; gap: 7px; color: #756780; font-size: 12px; min-height: 22px; }
.call-status-dot { width: 6px; height: 6px; border-radius: 50%; background: #a89ab6; }
[data-state=listening] .call-status-dot, [data-state=speaking] .call-status-dot, [data-state=thinking][data-interaction=voice] .call-status-dot { background: #2d9a7c; box-shadow: 0 0 0 3px #2d9a7c15; }
.call-duration { font-variant-numeric: tabular-nums; border-left: 1px solid #d6cede; padding-left: 10px; margin-left: 3px; }
.call-actions { display: grid; grid-template-columns: 1fr 1.4fr 1fr; align-items: center; max-width: 340px; margin: 12px auto 0; gap: 12px; }
.call-button, .call-secondary { display: flex; align-items: center; flex-direction: column; justify-content: center; gap: 9px; padding: 0; width: 100%; height: auto; border: 0; background: transparent; color: #5a4b69; font-size: 12px; line-height: 1.5; }
.call-button { color: #315f52; font-size: 14px; font-weight: 600; }
.call-icon { display: grid; place-items: center; width: 64px; height: 64px; border-radius: 50%; color: #fff; background: #32977b; box-shadow: 0 5px 18px #32977b28; transition: background .2s, transform .2s; }
.call-icon svg { width: 25px; height: 25px; transition: transform .2s; }
.call-button:not(:disabled):hover .call-icon { transform: translateY(-2px); background: #26866c; }
.call-button.listening { color: #a74656; }
.call-button.listening .call-icon { background: #cb596c; box-shadow: 0 5px 18px #cb596c25; }
.call-button.listening:not(:disabled):hover .call-icon { background: #b84659; }
.call-button.listening .call-icon svg { transform: rotate(135deg); }
.call-button:disabled { opacity: .55; cursor: wait; }
.call-secondary .control-icon { display: grid; place-items: center; width: 44px; height: 44px; border: 1px solid #d9d0e6; background: #ffffff90; border-radius: 50%; }
.control-icon svg { width: 19px; height: 19px; }
.sound-button .sound-off { display: none; }
.sound-button[aria-pressed=true] .sound-off { display: block; }
.sound-button[aria-pressed=true] .sound-on { display: none; }
.call-secondary:not(:disabled):hover .control-icon { background: #fff; border-color: #ab98c4; }
.call-secondary:disabled { opacity: .4; cursor: default; }
.voice-note { margin-top: 12px; color: #73647e; }
.text-mode-hint { display: none; position: absolute; bottom: 70px; left: 20px; right: 20px; text-align: center; color: #6f5c84; font-size: 16px; line-height: 2; }
.text-mode-hint span { color: #8a7a99; font-size: 13px; }
[data-interaction=text] .text-mode-hint { display: block; }
.call-empty { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 32px 22px; }
.call-empty h3 { margin: 23px 0 10px; font-size: 19px; font-weight: 500; color: #625274; }
.call-empty p { margin: 0; font-size: 14px; line-height: 1.9; color: #877990; }
.call-empty>span { margin-top: 26px; font-size: 12px; color: #9989a8; }
.empty-wave { display: flex; align-items: center; justify-content: center; gap: 5px; width: 76px; height: 76px; background: #f5f1fa; border: 1px solid #eee7f5; border-radius: 24px; }
.empty-wave i { width: 4px; height: 15px; border-radius: 3px; background: #b2a0cc; }
.empty-wave i:nth-child(2n) { height: 28px; }.empty-wave i:nth-child(3) { height: 40px; background: #9277b6; }
.text-panel { flex-shrink: 0; }
.text-form { margin-top: 0; }
.text-stop-button { display: block; margin: 10px auto 0; padding: 8px 12px; background: #f6f1fb; color: #71578c; border: 1px solid #e3d9ee; border-radius: 8px; }
.recording-info { flex-shrink: 0; padding: 10px 16px; margin: 0; border-top: 1px solid #f1edf5; }
.icon-button { width: 44px; height: 44px; flex-shrink: 0; }
button:focus-visible { outline: 3px solid #a28ac4; outline-offset: 4px; }
@media(max-width:1050px) and (min-width:761px) {
  .stage-top { flex-direction: column; align-items: flex-start; gap: 10px; top: 20px; }
  .avatar-figure { width: 280px; top: 112px; }.avatar-ground { top: 365px; }
  .stage-caption { left: 15px; right: 15px; }
  .stage-caption p { font-size: 13px; }
}
@media(max-width:760px) {
  .intro { padding: 22px 0; }.intro-copy { font-size: 14px; }
  .avatar-stage { height: 490px; min-height: 490px; }.chat-panel { height: 520px; min-height: 520px; }
  .stage-top { top: 14px; left: 16px; right: 16px; gap: 6px; }
  .persona-tag { font-size: 12px; gap: 6px; }.persona-role { display: none; }.tag-divider { display: none; }
  .interaction-switch { padding: 3px; }.interaction-switch button { min-height: 38px; padding: 6px 9px; font-size: 12px; }
  .avatar-figure { top: 58px; width: 165px; }.avatar-ground { top: 217px; width: 110px; }
  .floating-label { display: none; }.orbit-one { top: 15px; }.orbit-two { top: -30px; }
  .stage-caption { bottom: 207px; left: 12px; right: 12px; }.stage-caption h2 { font-size: 19px; margin: 4px 0; }.stage-caption p { font-size: 12px; }.stage-caption .waveform { display: none; }
  .voice-panel { bottom: 16px; left: 16px; right: 16px; }.voice-panel .recording-notice { font-size: 10px; margin-bottom: 8px; }
  .call-actions { margin-top: 9px; max-width: 280px; gap: 8px; }.call-icon { width: 58px; height: 58px; }.call-button,.call-secondary { gap: 6px; }
  .voice-note { font-size: 11px; margin-top: 10px; }.call-status-row { font-size: 11px; gap: 5px; }
  .text-mode-hint { bottom: 65px; }.chat-header { padding: 18px 20px 14px; }.chat-header p { font-size: 12px; }
  .call-empty p { font-size: 13px; }.call-empty h3 { font-size: 18px; }
}
@media(max-width:350px) {
  .stage-top { left: 12px; right: 12px; }.persona-tag { gap: 4px; }.persona-tag .live-dot { display: none; }
  .interaction-switch button { padding: 6px 7px; }.voice-panel { left: 10px; right: 10px; }
  .call-status-row { gap: 4px; font-size: 10px; }.call-duration { margin-left: 0; padding-left: 6px; }
  .call-empty { padding-left: 15px; padding-right: 15px; }.call-empty p { font-size: 12px; }
}
