/* Scoped guide components; all colours come from the shared Vula theme. */
.vc-chat { position: fixed; right: calc(max(1rem, env(safe-area-inset-right)) + var(--vc-chat-right, 0px)); bottom: calc(1rem + env(safe-area-inset-bottom) + var(--vc-chat-keyboard, 0px)); z-index: 90; color: var(--ink); font-size: .875rem; line-height: 1.5; }
.vc-chat :where(button, input) { font: inherit; }
.vc-chat button { cursor: pointer; }
.vc-chat :focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.vc-chat-launcher { display: block; margin-left: auto; min-height: 52px; padding: .75rem 1.125rem; border: 1px solid var(--ink); border-radius: var(--radius); background: var(--ink); color: var(--white); font-weight: 600; box-shadow: 0 3px 12px #243b331a; }
.vc-chat-launcher:hover, .vc-chat-send:hover { background: var(--sage-deep); }
.vc-chat-panel { display: flex; flex-direction: column; width: min(390px, calc(100vw - 32px - env(safe-area-inset-right))); height: 620px; max-height: calc(var(--vc-chat-height, 100dvh) - 100px - env(safe-area-inset-bottom)); margin-bottom: .75rem; border: 1px solid var(--line); border-radius: var(--radius); background: var(--white); box-shadow: 0 8px 32px #243b3326; overflow: auto; overscroll-behavior: contain; }
.vc-chat-panel[hidden] { display: none; }
.vc-chat-header { display: flex; align-items: center; justify-content: space-between; gap: .75rem; padding: .875rem 1rem .5rem; flex-shrink: 0; background: var(--white); position: sticky; top: 0; z-index: 1; }
.vc-chat-title { margin: 0; font-size: 1.3rem; line-height: 1.3; letter-spacing: -.025em; }
.vc-chat-subtitle { margin: .25rem 0 0; color: var(--muted); font-size: .75rem; }
.vc-chat-close { width: 44px; height: 44px; flex-shrink: 0; padding: 0; border: 1px solid var(--line); border-radius: 4px; background: var(--paper); color: var(--ink); font-size: 1.5rem; }
.vc-chat-disclosure { flex-shrink: 0; margin: 0; padding: 0 1rem .875rem; border-bottom: 1px solid var(--line); color: var(--muted); font-size: .75rem; }
.vc-chat-log { flex: 1 1 200px; min-height: 48px; padding: 1rem; overflow-y: auto; overscroll-behavior: contain; background: var(--paper); }
.vc-chat-log:focus-visible { outline-offset: -3px; }
.vc-chat-message { margin-bottom: .875rem; padding: .75rem; border: 1px solid var(--line); border-radius: var(--radius); background: var(--white); overflow-wrap: anywhere; }
.vc-chat-message:last-child { margin-bottom: 0; }
.vc-chat-message-user { margin-left: 1.5rem; background: var(--surface); }
.vc-chat-message-entering { animation: vc-chat-reply-in 240ms ease-out; }
@keyframes vc-chat-reply-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: translateY(0); } }
@media (prefers-reduced-motion: reduce) { .vc-chat-message-entering { animation: none; } }
.vc-chat-speaker { display: block; margin-bottom: .375rem; font-size: .7rem; font-weight: 700; letter-spacing: .04em; }
.vc-chat-message p { margin: 0; }
.vc-chat-service { margin-top: .75rem; padding-top: .5rem; border-top: 1px solid var(--line); }
.vc-chat-service p { font-size: .8125rem; }
.vc-chat-links { margin-top: .5rem; display: grid; gap: .25rem; }
.vc-chat-link { display: flex; align-items: center; min-height: 44px; padding: .25rem 0; font-weight: 600; line-height: 1.4; }
.vc-chat-topics { display: flex; gap: .5rem; flex-shrink: 0; padding: .625rem .875rem; overflow-x: auto; border-top: 1px solid var(--line); }
.vc-chat-topic { flex-shrink: 0; min-height: 44px; padding: .5rem .75rem; border: 1px solid var(--line); border-radius: 4px; color: var(--ink); background: var(--surface); white-space: nowrap; }
.vc-chat-topic:hover, .vc-chat-close:hover { background: var(--sage); }
.vc-chat-form { flex-shrink: 0; padding: .5rem 1rem .875rem; }
.vc-chat-label { display: block; font-size: .8125rem; font-weight: 600; margin-bottom: .375rem; }
.vc-chat-input-row { display: flex; gap: .5rem; }
.vc-chat-input { min-width: 0; width: 100%; min-height: 44px; padding: .625rem; border: 1px solid var(--muted); border-radius: 4px; color: var(--ink); background: var(--white); font-size: 1rem; }
.vc-chat-input::placeholder { color: var(--muted); opacity: 1; }
.vc-chat-send { min-height: 44px; padding: .5rem .875rem; border: 1px solid var(--ink); border-radius: 4px; color: var(--white); background: var(--ink); }
.vc-chat-clear { flex-shrink: 0; min-width: 44px; min-height: 44px; padding: .375rem .25rem; border: 0; color: var(--muted); background: none; text-decoration: underline; text-underline-offset: .2em; font-size: .75rem; }
.vc-chat-sr { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
/* Use the visible screen for phones, landscape and keyboard-constrained windows. */
.vc-chat-open.vc-chat-compact { right: calc(var(--vc-chat-right, 0px) + 1rem + env(safe-area-inset-right)); width: min(600px, calc(var(--vc-chat-width, 100vw) - 2rem - env(safe-area-inset-left) - env(safe-area-inset-right))); }
.vc-chat-compact .vc-chat-panel { width: 100%; height: calc(var(--vc-chat-height, 100dvh) - 2rem - env(safe-area-inset-top) - env(safe-area-inset-bottom)); max-height: none; margin-bottom: 0; }
.vc-chat-open.vc-chat-compact .vc-chat-launcher { display: none; }
.vc-chat-compact .vc-chat-header { gap: .5rem; padding: .5rem .75rem .25rem; }
.vc-chat-compact .vc-chat-subtitle { display: none; }
.vc-chat-compact .vc-chat-disclosure { padding: 0 .75rem .5rem; }
.vc-chat-compact .vc-chat-topics { padding: .25rem .75rem; }
.vc-chat-compact .vc-chat-form { padding: .25rem .75rem .5rem; }
@media print { .vc-chat { display: none; } }
