/*
 * "Connect your agent" in the marketing header. A connector button joins the agent's logo to the
 * Raq.com mark; it opens a two-pane panel (a bottom sheet on phones) with each agent's example,
 * steps and first action. bar.css restyles the button and panel for the Floating bar.
 */
[data-nvo-bar].nvo-af-raised { z-index: 90; }
.nvo-af-label-short { display: none; }

/* The connector button */
.nvo-af-button { display: inline-flex; align-items: center; gap: 11px; height: 42px; padding: 0 17px 0 6px; border-radius: 999px; border: 1px solid var(--nvo-edge); background: #fff; font-weight: 550; color: var(--nvo-ink); white-space: nowrap; box-shadow: 0 1px 1px #1c1f2a0a; transition: border-color .15s, box-shadow .2s var(--nvo-ease); }
.nvo-af-button:hover, .nvo-af-button[aria-expanded="true"] { border-color: #c3cad3; box-shadow: 0 6px 18px -10px #1c1f2a52; }
.nvo-af-link { display: flex; align-items: center; }
.nvo-af-end { position: relative; display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; }
.nvo-af-agent { border: 1px solid var(--nvo-edge); background: #fff; overflow: hidden; }
.nvo-af-agent img { position: absolute; inset: 0; width: 15px; height: 15px; margin: auto; opacity: 0; transform: translateY(7px) scale(.85); transition: opacity .3s, transform .5s var(--nvo-ease); }
.nvo-af-agent img.is-on { opacity: 1; transform: none; }
.nvo-af-raq { background: var(--nvo-ink); }
.nvo-af-raq img { width: 17px; height: auto; filter: invert(1); }
.nvo-af-wire { position: relative; width: 16px; height: 2px; background: repeating-linear-gradient(90deg, #b3bac4 0 3px, transparent 3px 5px); }
.nvo-af-wire i { position: absolute; top: -2px; left: -3px; width: 6px; height: 6px; border-radius: 50%; background: var(--nvo-ink); opacity: 0; }
.nvo-af-button:hover .nvo-af-wire i, .nvo-af-button[aria-expanded="true"] .nvo-af-wire i { animation: nvo-af-flow 1.2s var(--nvo-ease) infinite; }
.nvo-af-button.is-connected .nvo-af-wire { background: var(--nvo-green); }
.nvo-af-button.is-connected .nvo-af-wire i { left: 5px; opacity: 1; background: var(--nvo-green); box-shadow: 0 0 0 3px #286c4c26; animation: none; }
@keyframes nvo-af-flow {
    0% { transform: translateX(0); opacity: 0; }
    25%, 75% { opacity: 1; }
    100% { transform: translateX(16px); opacity: 0; }
}

/* The panel: a dropdown under the bar, aligned to its right edge */
.nvo-af-scrim { display: none; }
.nvo-af-panel { position: absolute; top: calc(100% + 10px); right: 24px; z-index: 80; width: min(816px, calc(100vw - 48px)); border-radius: 20px; border: 1px solid var(--nvo-edge); background: #fff; box-shadow: 0 1px 2px #1c1f2a0f, 0 44px 90px -40px #1c1f2a80; overflow: hidden; transform-origin: top right; }
.nvo-af-in { transition: opacity .18s, transform .3s var(--nvo-ease); }
.nvo-af-out { transition: opacity .12s, transform .12s; }
.nvo-af-from { opacity: 0; transform: translateY(-6px) scale(.985); }
.nvo-af-grip, .nvo-af-close { display: none; }

.nvo-af-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding: 22px 26px 20px; border-bottom: 1px solid var(--nvo-line); }
.nvo-af-head strong { display: block; font-size: 20px; font-weight: 650; letter-spacing: -.028em; }
.nvo-af-head p { margin: 5px 0 0; font-size: 14.5px; line-height: 1.5; color: var(--nvo-muted); }

.nvo-af-body { display: grid; grid-template-columns: 238px minmax(0, 1fr); }
.nvo-af-rail { display: grid; grid-template-rows: repeat(5, auto) 1fr; gap: 3px; padding: 14px 12px; background: var(--nvo-ground); border-right: 1px solid var(--nvo-line); }
.nvo-af-tab { display: flex; align-items: center; gap: 11px; width: 100%; padding: 9px 10px; border: 1px solid transparent; border-radius: 12px; text-align: left; transition: background-color .15s, border-color .15s, box-shadow .15s; }
.nvo-af-tab:hover { background: #ffffffb3; }
.nvo-af-tab[aria-selected="true"] { background: #fff; border-color: var(--nvo-edge); box-shadow: 0 1px 2px #1c1f2a0f, 0 8px 18px -12px #1c1f2a40; }
.nvo-af-tab .nvo-tile { width: 36px; height: 36px; border-radius: 10px; }
.nvo-af-tab-text { display: grid; gap: 1px; min-width: 0; }
.nvo-af-tab-text strong { font-size: 14.5px; font-weight: 600; }
.nvo-af-tab-text small { overflow: hidden; font-size: 12.5px; color: var(--nvo-muted); white-space: nowrap; text-overflow: ellipsis; }
.nvo-af-on { display: grid; place-items: center; margin-left: auto; padding-right: 2px; }
.nvo-af-glyph { width: 18px; height: 18px; color: var(--nvo-ink-2); }
.nvo-af-trust { display: flex; gap: 8px; margin: 0; padding: 14px 10px 4px; align-self: end; font-size: 12.5px; line-height: 1.45; color: var(--nvo-muted); }
.nvo-af-trust-icon { flex: none; width: 16px; height: 16px; margin-top: 1px; color: var(--nvo-green); }

/* Every pane sits in one cell, so the panel keeps the tallest pane's height when switching */
.nvo-af-panes { display: grid; min-width: 0; }
.nvo-af-pane { grid-area: 1 / 1; display: grid; align-content: start; gap: 20px; min-width: 0; padding: 22px 26px 24px; transition: opacity .2s; }
.nvo-af-pane.is-hidden { visibility: hidden; opacity: 0; pointer-events: none; transition: opacity .12s, visibility 0s .12s; }

/* The example: the agent using a Raq.com tool */
.nvo-af-demo { margin: 0; border: 1px solid var(--nvo-line); border-radius: 14px; background: #fafbfb; overflow: hidden; }
.nvo-af-demo-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 9px 14px; border-bottom: 1px solid var(--nvo-line); background: #fff; font-size: 12.5px; color: var(--nvo-muted); }
.nvo-af-demo-who { display: inline-flex; align-items: center; gap: 7px; font-weight: 600; color: var(--nvo-ink); }
.nvo-af-demo-who img, .nvo-af-demo-who .nvo-af-glyph { width: 14px; height: 14px; }
.nvo-af-demo-state { display: inline-flex; align-items: center; gap: 8px; }
.nvo-af-demo-state .nvo-dot { width: 6px; height: 6px; }
.nvo-af-demo-chat { display: grid; gap: 11px; min-height: 166px; align-content: start; padding: 16px 16px 18px; }
.nvo-af-ask { justify-self: end; max-width: 84%; margin: 0; padding: 9px 13px; border-radius: 14px 14px 4px 14px; background: #eceef1; font-size: 13.5px; line-height: 1.45; color: var(--nvo-ink); }
.nvo-af-used { display: flex; flex-wrap: wrap; gap: 6px; }
.nvo-af-tool { display: inline-flex; align-items: center; gap: 7px; padding: 3px 10px 3px 3px; border: 1px solid var(--nvo-line); border-radius: 999px; background: #fff; font-size: 12.5px; font-weight: 500; color: var(--nvo-ink-2); }
.nvo-tile-xs { width: 24px; height: 24px; border-radius: 999px; box-shadow: none; }
.nvo-tile-xs img { width: 12px; height: 12px; }
.nvo-af-tick { width: 13px; height: 13px; color: var(--nvo-green); }
.nvo-af-reply { max-width: 94%; margin: 0; font-size: 13.5px; line-height: 1.55; color: var(--nvo-ink); }

/* Stages: the request, then the tools, then the answer */
.nvo-af-ask, .nvo-af-tool, .nvo-af-reply, .nvo-af-tick { transition: opacity .28s, transform .45s var(--nvo-ease); }
.nvo-af-tool { transition-delay: calc(var(--i) * 170ms); }
[data-stage="0"] .nvo-af-ask,
[data-stage="0"] .nvo-af-tool, [data-stage="1"] .nvo-af-tool,
[data-stage="0"] .nvo-af-reply, [data-stage="1"] .nvo-af-reply, [data-stage="2"] .nvo-af-reply { opacity: 0; transform: translateY(6px); transition-delay: 0s; }
[data-stage="0"] .nvo-af-tick, [data-stage="1"] .nvo-af-tick, [data-stage="2"] .nvo-af-tick { opacity: 0; transform: scale(.4); }

/* Coding agents: a terminal */
.nvo-af-demo.is-term { border-color: #15171c; background: #15171c; }
.is-term .nvo-af-demo-bar { border-color: #2a2e37; background: #1d2027; color: #9aa1ad; }
.is-term .nvo-af-demo-who { color: #eceef1; }
.is-term .nvo-af-demo-who .nvo-af-glyph { color: #eceef1; }
.is-term .nvo-af-demo-chat { min-height: 0; gap: 10px; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: 0; }
.is-term .nvo-af-ask { justify-self: start; max-width: none; padding: 0; border-radius: 0; background: none; font-size: 12.5px; color: #eceef1; }
.is-term .nvo-af-ask::before { content: '> '; color: #8a909c; }
.is-term .nvo-af-tool { border-color: #2a2e37; background: #1d2027; font-family: Inter, ui-sans-serif, system-ui, sans-serif; color: #c9cdd5; }
.is-term .nvo-af-tool .nvo-tile { border-color: #2a2e37; }
.is-term .nvo-af-tick { color: #6fcf97; }
.is-term .nvo-af-reply { font-size: 12.5px; color: #c9cdd5; }

/* Steps and the first action */
.nvo-af-do { display: grid; gap: 16px; }
.nvo-af-cmd { display: block; overflow-x: auto; padding: 10px 12px; border: 1px solid var(--nvo-line); border-radius: 10px; background: var(--nvo-ground); font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12.5px; line-height: 1.5; letter-spacing: 0; overflow-wrap: anywhere; color: var(--nvo-ink-2); }
.nvo-af-steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin: 0; padding: 0; list-style: none; counter-reset: nvo-af-step; }
.nvo-af-steps li { position: relative; display: grid; align-content: start; gap: 8px; font-size: 13.5px; line-height: 1.4; color: var(--nvo-ink-2); counter-increment: nvo-af-step; }
.nvo-af-steps li::before { content: counter(nvo-af-step); position: relative; z-index: 1; display: grid; place-items: center; width: 24px; height: 24px; border: 1px solid var(--nvo-edge); border-radius: 50%; background: #fff; font-size: 12px; font-weight: 600; color: var(--nvo-ink); }
.nvo-af-steps li:not(:last-child)::after { content: ''; position: absolute; top: 12px; left: 32px; right: -8px; height: 1px; background: var(--nvo-line); }
.nvo-af-act { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 20px; }
.nvo-af-go { display: inline-flex; align-items: center; justify-content: center; gap: 9px; height: 44px; padding: 0 20px; border-radius: 11px; background: var(--nvo-ink); font-size: 15px; font-weight: 600; color: #fff; white-space: nowrap; transition: background-color .15s; }
.nvo-af-go:hover { background: #000; }
.nvo-af-go:has(.nvo-af-go-logo) { padding-left: 8px; }
.nvo-af-go-logo { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 8px; background: #fff; }
.nvo-af-go-icon { width: 17px; height: 17px; }
.nvo-af-guide { font-size: 14px; font-weight: 500; color: var(--nvo-muted); text-decoration: underline; text-decoration-color: #c3cad3; text-underline-offset: 3px; }
.nvo-af-guide:hover { color: var(--nvo-ink); }
.nvo-af-note { margin: -4px 0 0; font-size: 12.5px; line-height: 1.45; color: var(--nvo-faint); }

.nvo-af-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px 16px; padding: 14px 26px; border-top: 1px solid var(--nvo-line); font-size: 13.5px; color: var(--nvo-muted); }
.nvo-af-foot a { font-weight: 600; color: var(--nvo-ink); }
.nvo-af-foot a:hover { text-decoration: underline; text-underline-offset: 3px; }

/* The menu sheet's way into the panel */
.nvo-af-sheet-card { display: flex; align-items: center; gap: 14px; width: 100%; padding: 14px 14px 14px 16px; border: 1px solid var(--nvo-edge); border-radius: 16px; background: var(--nvo-ground); text-align: left; }
.nvo-af-sheet-logos { display: flex; flex: none; }
.nvo-af-sheet-logos .nvo-tile { margin-left: -8px; border-radius: 50%; }
.nvo-af-sheet-logos .nvo-tile:first-child { margin-left: 0; }
.nvo-af-sheet-text { display: grid; flex: 1; gap: 2px; min-width: 0; }
.nvo-af-sheet-text strong { font-size: 17px; font-weight: 650; letter-spacing: -.02em; }
.nvo-af-sheet-text small { font-size: 13.5px; line-height: 1.35; color: var(--nvo-muted); }
.nvo-af-sheet-chev { flex: none; width: 18px; height: 18px; color: var(--nvo-faint); transform: rotate(-90deg); }

/* Tablets and phones: a bottom sheet with the agents as a row of chips */
@media (max-width: 1023px) {
    .nvo-af-label { display: none; }
    .nvo-af-label-short { display: inline; }
    .nvo-af-button { gap: 9px; height: 40px; padding: 0 14px 0 5px; font-size: 14.5px; }
    .nvo-af-end { width: 28px; height: 28px; }
    .nvo-af-wire { width: 10px; }

    .nvo-af-scrim { display: block; position: fixed; inset: 0; z-index: 79; background: #191b2266; }
    .nvo-af-panel { position: fixed; top: auto; right: 0; bottom: 0; left: 0; width: auto; max-height: min(92dvh, 820px); overflow-y: auto; overscroll-behavior: contain; border-width: 1px 0 0; border-radius: 22px 22px 0 0; box-shadow: 0 -20px 50px -30px #1c1f2a66; }
    .nvo-af-from { transform: translateY(32px); }
    .nvo-af-grip { display: block; width: 40px; height: 5px; margin: 8px auto 0; border-radius: 3px; background: #d5dae0; }
    .nvo-af-head { padding: 12px 20px 16px; border-bottom: 0; }
    .nvo-af-close { display: grid; flex: none; place-items: center; width: 40px; height: 40px; margin: -2px -10px 0 0; border-radius: 10px; color: var(--nvo-ink); }
    .nvo-af-close svg { width: 22px; height: 22px; }

    .nvo-af-body { display: block; }
    .nvo-af-rail { display: flex; gap: 8px; overflow-x: auto; padding: 0 20px 4px; border: 0; background: none; scrollbar-width: none; }
    .nvo-af-rail::-webkit-scrollbar { display: none; }
    .nvo-af-tab { flex: none; width: auto; padding: 5px 14px 5px 5px; border-color: var(--nvo-edge); border-radius: 999px; background: #fff; }
    .nvo-af-tab .nvo-tile { width: 30px; height: 30px; border: 0; border-radius: 50%; background: var(--nvo-ground); box-shadow: none; }
    .nvo-af-tab .nvo-tile img, .nvo-af-tab .nvo-af-glyph { width: 16px; height: 16px; }
    .nvo-af-tab-text small, .nvo-af-on, .nvo-af-trust { display: none; }
    .nvo-af-tab[aria-selected="true"] { border-color: var(--nvo-ink); box-shadow: inset 0 0 0 1px var(--nvo-ink); }
    .nvo-af-pane { gap: 18px; padding: 16px 20px 22px; }
    .nvo-af-demo-chat { min-height: 0; }
    .nvo-af-steps { grid-template-columns: minmax(0, 1fr); gap: 12px; }
    .nvo-af-steps li { grid-template-columns: 24px minmax(0, 1fr); align-items: center; gap: 12px; font-size: 14.5px; }
    .nvo-af-steps li:not(:last-child)::after { top: 30px; bottom: -10px; left: 12px; right: auto; width: 1px; height: auto; }
    .nvo-af-act { flex-direction: column; align-items: stretch; gap: 14px; text-align: center; }
    .nvo-af-go { height: 50px; font-size: 16px; }
    .nvo-af-note { margin: 0; text-align: center; }
    .nvo-af-foot { justify-content: center; padding: 14px 20px max(16px, env(safe-area-inset-bottom)); text-align: center; background: var(--nvo-ground); }
}
/* Phones keep Connect in the bar; the free trial button moves to the foot of the menu */
@media (max-width: 519px) {
    .nvo-actions .nvo-cta { display: none; }
}
@media (prefers-reduced-motion: reduce) {
    .nvo-af-wire i { animation: none !important; }
}
