/* Valtu support chat (support.js): same ink-and-white palette as the site, square, light and dark. */
.vs-root {
  --vs-bg: #ffffff; --vs-bg-2: #f6f6f5; --vs-bg-3: #eeeeec; --vs-ink: #121212; --vs-ink-2: #5c5c5c; --vs-ink-3: #8a8a8a; --vs-line: #e4e4e2;
  --vs-accent: #121212; --vs-on-accent: #ffffff; --vs-ok: #0b8a4f;
  --vs-shadow: 0 24px 64px rgba(0, 0, 0, 0.16), 0 4px 14px rgba(0, 0, 0, 0.08); --vs-ease: cubic-bezier(0.2, 0.8, 0.2, 1);
  position: fixed; right: 20px; bottom: 20px; z-index: 2147483000;
  font: 14px/1.5 "Hedvig Letters Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; color: var(--vs-ink);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .vs-root { --vs-bg: #121212; --vs-bg-2: #1a1a1a; --vs-bg-3: #222; --vs-ink: #f4f4f4; --vs-ink-2: #a3a3a3; --vs-ink-3: #6f6f6f; --vs-line: #2a2a2a; --vs-accent: #f4f4f4; --vs-on-accent: #0d0d0d; --vs-ok: #3ccf87; --vs-shadow: 0 24px 64px rgba(0, 0, 0, 0.6); }
}
:root[data-theme="dark"] .vs-root { --vs-bg: #121212; --vs-bg-2: #1a1a1a; --vs-bg-3: #222; --vs-ink: #f4f4f4; --vs-ink-2: #a3a3a3; --vs-ink-3: #6f6f6f; --vs-line: #2a2a2a; --vs-accent: #f4f4f4; --vs-on-accent: #0d0d0d; --vs-ok: #3ccf87; --vs-shadow: 0 24px 64px rgba(0, 0, 0, 0.6); }

.vs-root *, .vs-root *::before, .vs-root *::after { box-sizing: border-box; }
.vs-root svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.vs-root :where(button) { font: inherit; color: inherit; }
.vs-root :where(a) { color: inherit; }
.vs-root :focus-visible { outline: 2px solid var(--vs-accent); outline-offset: 2px; }

/* launcher */
.vs-fab {
  width: 56px; height: 56px; border: 0; cursor: pointer; display: grid; place-items: center; margin-left: auto;
  background: var(--vs-accent); color: var(--vs-on-accent); box-shadow: var(--vs-shadow); transition: transform 0.25s var(--vs-ease);
}
.vs-fab:hover { transform: translateY(-2px); }
.vs-fab svg { width: 24px; height: 24px; }

/* panel */
.vs-panel {
  position: absolute; right: 0; bottom: 72px; width: min(400px, calc(100vw - 32px)); height: min(640px, calc(100vh - 110px));
  display: flex; flex-direction: column; background: var(--vs-bg); border: 1px solid var(--vs-line); overflow: hidden;
  box-shadow: var(--vs-shadow); transform-origin: bottom right; animation: vs-in 0.28s var(--vs-ease);
}
.vs-panel[hidden] { display: none; }
@keyframes vs-in { from { opacity: 0; transform: translateY(10px) scale(0.97); } to { opacity: 1; transform: none; } }

/* header */
.vs-head { position: relative; display: flex; align-items: center; gap: 10px; padding: 12px 10px 12px 14px; border-bottom: 1px solid var(--vs-line); }
.vs-mark { width: 34px; height: 34px; background: var(--vs-accent); color: var(--vs-on-accent); display: grid; place-items: center; flex: none; }
.vs-mark svg { width: 20px; height: 20px; fill: currentColor; stroke: none; }
.vs-title { display: grid; line-height: 1.25; flex: 1; min-width: 0; }
.vs-title b { font-weight: 600; }
.vs-sub { color: var(--vs-ink-2); font-size: 12.5px; }
.vs-title .vs-sub { display: flex; align-items: center; gap: 6px; white-space: nowrap; overflow: hidden; }
.vs-title .vs-sub span:last-child { overflow: hidden; text-overflow: ellipsis; }
.vs-dot { width: 7px; height: 7px; background: var(--vs-ink-3); flex: none; }
.vs-dot.on { background: var(--vs-ok); }
.vs-icon { border: 0; background: transparent; color: var(--vs-ink-2); cursor: pointer; width: 34px; height: 34px; display: grid; place-items: center; flex: none; }
.vs-icon:hover, .vs-icon[aria-expanded="true"] { background: var(--vs-bg-2); color: var(--vs-ink); }
.vs-back[hidden] { display: none; }
.vs-icon[aria-haspopup] svg { stroke-width: 3.2; }
.vs-back { margin-right: -4px; }
.vs-menu { position: absolute; top: calc(100% - 4px); right: 10px; z-index: 3; min-width: 210px; padding: 6px; background: var(--vs-bg); border: 1px solid var(--vs-line); box-shadow: var(--vs-shadow); display: grid; animation: vs-msg 0.16s ease-out; }
.vs-menu[hidden] { display: none; }
.vs-menu-item { display: flex; align-items: center; gap: 10px; padding: 9px 10px; border: 0; background: transparent; cursor: pointer; text-align: left; }
.vs-menu-item:hover, .vs-menu-item:focus-visible { background: var(--vs-bg-2); outline: none; }
.vs-menu-item svg { color: var(--vs-ink-2); }

/* body */
.vs-body { flex: 1; overflow-y: auto; padding: 16px; display: flex; flex-direction: column; gap: 12px; overscroll-behavior: contain; }
.vs-label { margin: 0; font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--vs-ink-3); }
@keyframes vs-msg { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }

/* home */
.vs-hero { padding: 4px 2px 2px; animation: vs-msg 0.3s ease-out; }
.vs-h { margin: 0 0 6px; font: 400 26px/1.15 "Hedvig Letters Serif", Georgia, serif; letter-spacing: -0.015em; }
.vs-lede { margin: 0; color: var(--vs-ink-2); font-size: 13.5px; }
.vs-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.vs-card {
  display: grid; gap: 2px; align-content: start; text-align: left; text-decoration: none; padding: 12px; min-height: 104px;
  background: var(--vs-bg); border: 1px solid var(--vs-line); cursor: pointer; transition: border-color 0.15s, background 0.15s, transform 0.2s var(--vs-ease);
  animation: vs-msg 0.3s ease-out both;
}
.vs-card:nth-child(2) { animation-delay: 30ms; } .vs-card:nth-child(3) { animation-delay: 60ms; } .vs-card:nth-child(4) { animation-delay: 90ms; }
.vs-card:nth-child(5) { animation-delay: 120ms; } .vs-card:nth-child(6) { animation-delay: 150ms; }
.vs-card:hover { border-color: var(--vs-ink); transform: translateY(-1px); }
.vs-card b { font-weight: 600; font-size: 13.5px; line-height: 1.3; margin-top: 8px; }
.vs-card > span:last-child { color: var(--vs-ink-2); font-size: 12px; line-height: 1.35; }
.vs-card-ic { width: 30px; height: 30px; display: grid; place-items: center; background: var(--vs-bg-2); border: 1px solid var(--vs-line); flex: none; }
.vs-card-ic svg { width: 16px; height: 16px; }
.vs-card:hover .vs-card-ic { background: var(--vs-accent); color: var(--vs-on-accent); border-color: var(--vs-accent); }
.vs-popular { display: grid; gap: 0; border-top: 1px solid var(--vs-line); padding-top: 12px; }
.vs-popular .vs-label { margin-bottom: 4px; }
.vs-q { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 2px; border: 0; border-bottom: 1px solid var(--vs-line); background: transparent; cursor: pointer; text-align: left; }
.vs-q:last-child { border-bottom: 0; }
.vs-q svg { width: 15px; height: 15px; color: var(--vs-ink-3); transition: transform 0.2s var(--vs-ease); }
.vs-q:hover svg { transform: translateX(3px); color: var(--vs-ink); }
.vs-resume { display: flex; align-items: center; gap: 10px; padding: 11px 12px; border: 1px solid var(--vs-ink); background: var(--vs-bg-2); cursor: pointer; text-align: left; }
.vs-resume span { flex: 1; font-weight: 600; }
.vs-links { display: flex; gap: 6px; flex-wrap: wrap; margin-top: auto; padding-top: 4px; }
.vs-chiplink { display: inline-flex; align-items: center; gap: 6px; padding: 6px 10px; border: 1px solid var(--vs-line); font-size: 12.5px; text-decoration: none; color: var(--vs-ink-2); }
.vs-chiplink:hover { color: var(--vs-ink); border-color: var(--vs-ink); }
.vs-chiplink svg { width: 14px; height: 14px; }

/* conversation */
.vs-turn { display: grid; gap: 6px; max-width: 90%; animation: vs-msg 0.24s ease-out; }
.vs-me { align-self: flex-end; justify-items: end; }
.vs-bot { align-self: flex-start; }
.vs-msg { padding: 10px 13px; overflow-wrap: anywhere; }
.vs-bot .vs-msg { background: var(--vs-bg-2); }
.vs-me .vs-msg { background: var(--vs-accent); color: var(--vs-on-accent); white-space: pre-wrap; }
.vs-msg p, .vs-msg ul, .vs-msg ol { margin: 0; }
.vs-msg p + p, .vs-msg p + ul, .vs-msg p + ol, .vs-msg ul + p, .vs-msg ol + p { margin-top: 8px; }
.vs-msg ul, .vs-msg ol { padding-left: 18px; }
.vs-msg li + li { margin-top: 3px; }
.vs-msg a { text-decoration: underline; text-underline-offset: 2px; }
.vs-msg code { font: 12.5px ui-monospace, SFMono-Regular, Menlo, monospace; padding: 1px 4px; background: var(--vs-bg-3); }
.vs-msg strong { font-weight: 600; }
.vs-error .vs-msg { border: 1px dashed var(--vs-line); background: transparent; }
.vs-typing .vs-msg { display: flex; gap: 4px; padding: 14px 14px; }
.vs-typing i { width: 6px; height: 6px; background: var(--vs-ink-3); animation: vs-bounce 1s ease-in-out infinite; }
.vs-typing i:nth-child(2) { animation-delay: 0.15s; } .vs-typing i:nth-child(3) { animation-delay: 0.3s; }
@keyframes vs-bounce { 0%, 60%, 100% { transform: none; opacity: 0.45; } 30% { transform: translateY(-4px); opacity: 1; } }

.vs-sources { display: grid; gap: 4px; }
.vs-sources .vs-label { margin: 2px 0 0; }
.vs-source { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border: 1px solid var(--vs-line); text-decoration: none; background: var(--vs-bg); transition: border-color 0.15s; }
.vs-source:hover { border-color: var(--vs-ink); }
.vs-source svg { width: 15px; height: 15px; color: var(--vs-ink-2); }
.vs-source svg:last-child { color: var(--vs-ink-3); transition: transform 0.2s var(--vs-ease); }
.vs-source:hover svg:last-child { transform: translateX(3px); color: var(--vs-ink); }
.vs-source-t { display: grid; min-width: 0; flex: 1; line-height: 1.3; }
.vs-source-t b { font-weight: 600; font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.vs-source-t span { color: var(--vs-ink-3); font-size: 11.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.vs-tools { display: flex; align-items: center; gap: 2px; }
.vs-tool { width: 28px; height: 28px; display: grid; place-items: center; border: 0; background: transparent; color: var(--vs-ink-3); cursor: pointer; }
.vs-tool svg { width: 15px; height: 15px; }
.vs-tool:hover { color: var(--vs-ink); background: var(--vs-bg-2); }
.vs-tool[aria-pressed="true"] { color: var(--vs-on-accent); background: var(--vs-accent); }
.vs-thanks { font-size: 11.5px; color: var(--vs-ink-3); margin-left: 6px; }

.vs-chips { display: flex; flex-wrap: wrap; gap: 6px; animation: vs-msg 0.3s ease-out 0.1s both; }
.vs-chip { display: inline-flex; align-items: center; gap: 6px; padding: 7px 11px; border: 1px solid var(--vs-line); background: var(--vs-bg); cursor: pointer; font-size: 12.5px; text-align: left; transition: border-color 0.15s, background 0.15s; }
.vs-chip:hover { border-color: var(--vs-ink); }
.vs-chip-person { border-color: var(--vs-ink); font-weight: 600; }
.vs-chip-person svg { width: 14px; height: 14px; }
.vs-chip-person:hover { background: var(--vs-accent); color: var(--vs-on-accent); }
.vs-offer { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 12px; border: 1px dashed var(--vs-line); font-size: 13px; color: var(--vs-ink-2); animation: vs-msg 0.24s ease-out; }
.vs-note { align-self: center; display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; font-size: 12px; color: var(--vs-ink-2); background: var(--vs-bg-2); }
.vs-note svg { width: 14px; height: 14px; color: var(--vs-ok); }

/* talk to a person */
.vs-form { border: 1px solid var(--vs-line); padding: 14px; display: grid; gap: 10px; animation: vs-msg 0.24s ease-out; background: var(--vs-bg); }
.vs-form-h { display: flex; gap: 10px; align-items: flex-start; }
.vs-form-h b { font-weight: 600; }
.vs-form-h p { margin: 2px 0 0; }
.vs-form .vs-label { margin-top: 2px; }
.vs-topics { display: flex; flex-wrap: wrap; gap: 6px; }
.vs-topic { padding: 6px 10px; border: 1px solid var(--vs-line); background: var(--vs-bg); cursor: pointer; font-size: 12.5px; }
.vs-topic:hover { border-color: var(--vs-ink); }
.vs-topic[aria-checked="true"] { background: var(--vs-accent); color: var(--vs-on-accent); border-color: var(--vs-accent); }
.vs-two { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.vs-form input, .vs-form textarea, .vs-input {
  width: 100%; font: inherit; color: var(--vs-ink); background: var(--vs-bg); border: 1px solid var(--vs-line); padding: 9px 11px; resize: none; border-radius: 0;
}
.vs-form input:focus, .vs-form textarea:focus, .vs-input:focus { outline: none; border-color: var(--vs-ink); }
.vs-hint { margin: -4px 0 0; font-size: 11.5px; color: var(--vs-ink-3); }
.vs-done { background: var(--vs-bg-2); border-color: var(--vs-ink); }
.vs-ok { background: var(--vs-accent); color: var(--vs-on-accent); border-color: var(--vs-accent); }
.vs-steps { margin: 0; padding: 0 0 0 40px; display: grid; gap: 6px; font-size: 13px; color: var(--vs-ink-2); }
.vs-actions { display: flex; justify-content: flex-end; gap: 8px; align-items: center; }
.vs-btn { border: 0; background: var(--vs-accent); color: var(--vs-on-accent); font-weight: 600; padding: 9px 14px; cursor: pointer; white-space: nowrap; }
.vs-btn.sm { padding: 6px 10px; font-size: 12.5px; }
.vs-btn:disabled { opacity: 0.6; cursor: default; }
.vs-link { border: 0; background: transparent; color: var(--vs-ink-2); cursor: pointer; padding: 8px 4px; }
.vs-err { color: #b42318; font-size: 12.5px; }
.vs-err:empty { display: none; }

/* composer */
.vs-foot { border-top: 1px solid var(--vs-line); padding: 12px 12px 10px; display: grid; gap: 8px; margin: 0; }
.vs-row { display: flex; gap: 8px; align-items: flex-end; }
.vs-input { max-height: 120px; }
.vs-send { flex: none; width: 40px; height: 40px; border: 0; background: var(--vs-accent); color: var(--vs-on-accent); cursor: pointer; display: grid; place-items: center; }
.vs-send:disabled { opacity: 0.5; }
.vs-fine { display: flex; justify-content: space-between; align-items: center; font-size: 12px; color: var(--vs-ink-2); padding: 0 2px; }
.vs-human { border: 0; background: transparent; padding: 0; font-weight: 600; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }

@media (max-width: 480px) {
  .vs-root { right: 12px; bottom: 12px; }
  .vs-panel { position: fixed; inset: auto 8px 80px 8px; width: auto; height: calc(100dvh - 100px); }
  .vs-two { grid-template-columns: 1fr; }
}
/* Dashboard on phones: sit above its bottom tab bar (64px + the safe area). */
@media (max-width: 767px) {
  .vs-root.vs-app { bottom: calc(76px + env(safe-area-inset-bottom, 0px)); }
  .vs-app .vs-fab { width: 48px; height: 48px; }
  .vs-app .vs-panel { bottom: 60px; height: min(640px, calc(100dvh - 180px)); }
}
@media (max-width: 480px) {
  .vs-app .vs-panel { inset: auto 8px calc(132px + env(safe-area-inset-bottom, 0px)) 8px; height: calc(100dvh - 150px - env(safe-area-inset-bottom, 0px)); }
}
@media (prefers-reduced-motion: reduce) {
  .vs-root *, .vs-panel { animation: none !important; transition: none !important; }
}
@media print { .vs-root { display: none; } }
