/* Acclaro site guide widget.
   Set the brand tokens below to acclaroinc.com's palette and type (VERIFY with the theme). */
.ag-root {
  --ag-ink: #1c2230;
  --ag-muted: #5b6475;
  --ag-paper: #ffffff;
  --ag-wash: #f3f4f7;
  --ag-accent: #1f5fbf;
  --ag-accent-ink: #ffffff;
  --ag-line: #dde1e8;
  --ag-font: inherit;
  --ag-radius-panel: 18px;
  font-family: var(--ag-font);
  color: var(--ag-ink);
  position: fixed;
  right: max(20px, env(safe-area-inset-right));
  bottom: max(20px, env(safe-area-inset-bottom));
  z-index: 99999;
  line-height: 1.45;
}
.ag-root *, .ag-root *::before, .ag-root *::after { box-sizing: border-box; }
.ag-root button { font: inherit; cursor: pointer; }
.ag-root :focus-visible { outline: 3px solid var(--ag-accent); outline-offset: 2px; }

/* Launcher: the mascot, looping silently. The character is the one bold element. */
.ag-launcher {
  display: flex; align-items: flex-end; gap: 10px;
  background: none; border: 0; padding: 0; color: inherit;
}
.ag-launcher-face {
  width: 88px; height: 88px; border-radius: 50%; overflow: hidden;
  background: var(--ag-wash); border: 3px solid var(--ag-paper);
  box-shadow: 0 6px 24px rgba(28, 34, 48, 0.22); flex: none;
}
.ag-launcher-face video, .ag-launcher-face img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ag-bubble {
  background: var(--ag-paper); border: 1px solid var(--ag-line);
  border-radius: 14px 14px 4px 14px; padding: 10px 14px; max-width: 220px;
  font-size: 15px; text-align: left; box-shadow: 0 4px 16px rgba(28, 34, 48, 0.12);
  margin-bottom: 18px; opacity: 0; transform: translateY(6px);
  transition: opacity .3s ease, transform .3s ease; pointer-events: none;
}
.ag-bubble.is-shown { opacity: 1; transform: none; }

/* Panel */
.ag-panel {
  position: absolute; right: 0; bottom: 0;
  width: 380px; height: min(640px, calc(100vh - 40px));
  background: var(--ag-paper); border-radius: var(--ag-radius-panel);
  box-shadow: 0 18px 60px rgba(28, 34, 48, 0.28);
  display: none; flex-direction: column; overflow: hidden;
}
.ag-root.is-open .ag-panel { display: flex; }
.ag-root.is-open .ag-launcher { visibility: hidden; }

.ag-head { display: flex; align-items: center; justify-content: space-between; padding: 12px 14px 10px; }
.ag-title { font-weight: 700; font-size: 16px; margin: 0; }
.ag-sub { font-size: 13px; color: var(--ag-muted); margin: 0; }
.ag-close { background: none; border: 0; width: 36px; height: 36px; border-radius: 50%; font-size: 22px; color: var(--ag-muted); }
.ag-close:hover { background: var(--ag-wash); }

.ag-stage { position: relative; background: var(--ag-wash); aspect-ratio: 1088 / 704; flex: none; }
.ag-stage video, .ag-stage img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
/* Live: the still shows at once; the video fades in over it when the avatar's track plays. */
.ag-stage video { opacity: 0; transition: opacity 0.25s ease; }
.ag-root.is-live.has-video .ag-stage video { opacity: 1; }
.ag-root:not(.is-live) .ag-stage { aspect-ratio: auto; height: 96px; }
.ag-root:not(.is-live) .ag-stage video { display: none; }
.ag-status {
  position: absolute; left: 10px; bottom: 10px; font-size: 12px;
  background: rgba(255, 255, 255, 0.92); color: var(--ag-ink); padding: 3px 9px; border-radius: 999px;
}
.ag-status:empty { display: none; }

.ag-log { flex: 1; overflow-y: auto; padding: 14px; display: flex; flex-direction: column; gap: 8px; }
.ag-msg { max-width: 85%; padding: 9px 12px; border-radius: 14px; font-size: 15px; white-space: pre-wrap; overflow-wrap: anywhere; }
.ag-msg.is-assistant { background: var(--ag-wash); align-self: flex-start; border-bottom-left-radius: 4px; }
.ag-msg.is-user { background: var(--ag-accent); color: var(--ag-accent-ink); align-self: flex-end; border-bottom-right-radius: 4px; }
.ag-note { font-size: 13px; color: var(--ag-muted); text-align: center; }
.ag-card { border: 1px solid var(--ag-line); border-radius: 12px; padding: 12px; font-size: 14px; }
.ag-card a { color: var(--ag-accent); font-weight: 600; }

.ag-controls { border-top: 1px solid var(--ag-line); padding: 10px; display: flex; flex-direction: column; gap: 8px; }
.ag-input-row { display: flex; gap: 8px; }
.ag-input {
  flex: 1; border: 1px solid var(--ag-line); border-radius: 10px; padding: 10px 12px;
  font: inherit; font-size: 16px; color: var(--ag-ink); background: var(--ag-paper); min-width: 0;
}
.ag-send { border: 0; border-radius: 10px; padding: 0 14px; background: var(--ag-accent); color: var(--ag-accent-ink); font-weight: 600; }
.ag-mode-row { display: flex; gap: 8px; align-items: center; justify-content: space-between; }
.ag-mode {
  border: 1px solid var(--ag-line); background: var(--ag-paper); color: var(--ag-ink);
  border-radius: 999px; padding: 7px 14px; font-size: 14px; font-weight: 600;
}
.ag-mode:hover { border-color: var(--ag-ink); }
.ag-mic[aria-pressed="false"] { color: var(--ag-muted); }
.ag-disclosure { font-size: 12px; color: var(--ag-muted); margin: 0; }
.ag-disclosure a { color: inherit; }

@media (max-width: 600px) {
  .ag-panel { position: fixed; inset: 0; width: auto; height: 100%; border-radius: 0;
    padding-bottom: env(safe-area-inset-bottom); padding-top: env(safe-area-inset-top); }
  .ag-launcher-face { width: 72px; height: 72px; }
}
@media (prefers-reduced-motion: reduce) {
  .ag-bubble { transition: none; }
}
