/* The Bot Analytics designs (2026-12-03): widget/bot-analytics-demo (the sample dashboard) and
   statement/bot-analytics-detail (text beside a product illustration). They sit on the Cowork V2 dark band (cowork-v2.css
   loads with them: BOT_ANALYTICS_LAYOUTS in components/PageView.astro) and are linked only on pages that use them. The app
   window and illustrations are light, like the product, so they read the same at any hour. Bot type colours follow the
   product: answering people #3B82F6, AI search #14B8A6, AI training #FBBF24, AI agent #A855F7, search engines #94A3B8. */

/* ---------- the app window ---------- */
.ba-demo-section .cw2-wrap { padding-top: 5rem; }
.ba-app {
  --ba-ink: #16161e; --ba-muted: #6b6b76; --ba-line: #e7e7ec; --ba-soft: #f5f5f7; --ba-orange: #f66719;
  position: relative; max-width: 72rem; margin: 0 auto; color: var(--ba-ink); background: #fff; border-radius: 1rem;
  /* one screen tall, like the app: the header, tabs and filters stay put and the view scrolls inside the window */
  display: flex; flex-direction: column; height: clamp(34rem, calc(100vh - 9rem), 54rem); height: clamp(34rem, calc(100svh - 9rem), 54rem);
  box-shadow: 0 0 0 1px #ffffff1f, 0 2rem 6rem #00000099; font-family: 'Forma DJR Text', Arial, sans-serif; font-size: .875rem; line-height: 1.4; text-align: left;
}
.ba-app button, .ba-app input { font: inherit; color: inherit; }
.ba-bar { display: flex; align-items: center; gap: .4rem; padding: .7rem 1rem; border-bottom: 1px solid var(--ba-line); background: #fafafa; border-radius: 1rem 1rem 0 0; }
.ba-bar i { width: .65rem; height: .65rem; border-radius: 50%; background: #e2e2e7; }
.ba-bar span { margin-left: .75rem; color: var(--ba-muted); font-size: .8rem; }
.ba-bar em { margin-left: auto; font-style: normal; font-size: .72rem; font-weight: 600; color: #9a3412; background: #ffedd5; padding: .2rem .55rem; border-radius: 1rem; }
.ba-body { flex: 1; min-height: 0; display: flex; flex-direction: column; padding: 1.25rem 0 0; }
.ba-top, .ba-tabs, .ba-controls { margin-left: 1.5rem; margin-right: 1.5rem; }
.ba-tabs { align-self: flex-start; max-width: calc(100% - 3rem); }
.ba-top { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.ba-title { margin: 0; font-size: 1.4rem; font-weight: 600; letter-spacing: -.01em; color: var(--ba-ink); }
.ba-source { position: relative; display: inline-flex; align-items: center; gap: .45rem; padding: .4rem .8rem; border: 1px solid var(--ba-line); border-radius: 2rem; font-weight: 500; cursor: default; }
.ba-cloud { width: .9rem; height: .55rem; border-radius: .5rem .5rem .2rem .2rem; background: #f48120; }
.ba-live, .bav-live { width: .45rem; height: .45rem; border-radius: 50%; background: #16a34a; box-shadow: 0 0 0 3px #16a34a26; }
.ba-source-pop { right: 0; left: auto; top: calc(100% + .4rem); width: 15rem; }
.ba-source-pop div { display: flex; justify-content: space-between; gap: .75rem; padding: .2rem 0; }
.ba-source-pop span { color: #ffffffb3; }
.ba-source:hover .ba-pop, .ba-source:focus .ba-pop { opacity: 1; visibility: visible; }
.ba-tabs { display: inline-flex; flex-wrap: nowrap; gap: .15rem; margin-top: 1rem; padding: .25rem; border-radius: .7rem; background: var(--ba-soft); max-width: 100%; overflow-x: auto; scrollbar-width: none; }
.ba-tab { border: 0; background: none; padding: .45rem .85rem; border-radius: .5rem; color: var(--ba-muted); cursor: pointer; white-space: nowrap; transition: background .15s, color .15s; }
.ba-tab:hover { color: var(--ba-ink); background: #ececf0; }
.ba-tab.is-on { background: #fff; color: var(--ba-ink); font-weight: 600; box-shadow: 0 1px 2px #0000001f; }
.ba-controls { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; margin-top: .9rem; }
.ba-btn { display: inline-flex; align-items: center; gap: .45rem; padding: .45rem .8rem; border: 1px solid var(--ba-line); border-radius: .6rem; background: #fff; cursor: pointer; white-space: nowrap; transition: border-color .15s, background .15s; }
.ba-btn:hover { border-color: #c9c9d2; background: #fafafa; }
.ba-btn.is-set { border-color: #fdba74; background: #fff7ed; }
.ba-btn.is-dark { background: var(--ba-ink); border-color: var(--ba-ink); color: #fff; }
.ba-btn.is-dark:hover { background: #2a2a35; }
.ba-btn[aria-expanded="true"] { border-color: var(--ba-ink); }
.ba-caret { width: .4rem; height: .4rem; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: translateY(-2px) rotate(45deg); opacity: .6; }
.ba-link { border: 0; background: none; padding: .2rem .3rem; color: #c2410c; cursor: pointer; font-weight: 500; }
.ba-link:hover { text-decoration: underline; }
.ba-view { flex: 1; min-height: 0; margin-top: 1rem; padding: 0 1.5rem 1.5rem; border-top: 1px solid var(--ba-line); padding-top: 1rem; overflow-y: auto; overscroll-behavior-y: auto; scrollbar-width: thin; scrollbar-color: #cfcfd6 transparent; }
.ba-view::-webkit-scrollbar { width: 8px; }
.ba-view::-webkit-scrollbar-thumb { background: #cfcfd6; border-radius: 4px; }
.ba-app :focus-visible { outline: 2px solid var(--ba-orange); outline-offset: 2px; }

/* menus and tooltips */
.ba-menu { position: absolute; z-index: 20; min-width: 15rem; max-width: 21rem; max-height: 24rem; overflow-y: auto; padding: .35rem; background: #fff; border: 1px solid var(--ba-line); border-radius: .75rem; box-shadow: 0 .75rem 2rem #0000002e; }
.ba-menu-h { padding: .55rem .6rem .25rem; font-size: .7rem; text-transform: uppercase; letter-spacing: .05em; color: var(--ba-muted); }
.ba-opt { display: flex; align-items: center; gap: .55rem; width: 100%; padding: .5rem .6rem; border: 0; border-radius: .5rem; background: none; text-align: left; cursor: pointer; }
.ba-opt:hover { background: var(--ba-soft); }
.ba-opt.is-on { background: #fff7ed; font-weight: 600; }
.ba-opt.is-dim { color: var(--ba-muted); }
.ba-opt span { flex: 1; }
.ba-opt small { display: block; font-weight: 400; color: var(--ba-muted); font-size: .75rem; }
.ba-opt em { font-style: normal; color: var(--ba-muted); font-size: .78rem; }
.ba-opt input { accent-color: var(--ba-orange); margin: 0; }
.ba-opt.is-all { border-bottom: 1px solid var(--ba-line); border-radius: .5rem .5rem 0 0; margin-bottom: .2rem; }
.ba-dot { display: inline-block; width: .55rem; height: .55rem; border-radius: 50%; flex: none; margin-right: .35rem; vertical-align: 1px; }
.ba-pop { position: absolute; z-index: 30; left: 50%; top: calc(100% + .35rem); transform: translateX(-50%); width: 14rem; padding: .55rem .7rem; border-radius: .5rem; background: var(--ba-ink); color: #fff; font-size: .75rem; line-height: 1.4; font-weight: 400; text-transform: none; letter-spacing: 0; opacity: 0; visibility: hidden; transition: opacity .15s; pointer-events: none; }
.ba-i { position: relative; display: inline-grid; place-items: center; width: .85rem; height: .85rem; margin-left: .3rem; border: 1px solid #c4c4cc; border-radius: 50%; font-size: .55rem; font-style: normal; color: var(--ba-muted); cursor: help; vertical-align: 1px; }
.ba-i:hover .ba-pop, .ba-i:focus .ba-pop { opacity: 1; visibility: visible; }
.ba-toast { position: absolute; left: 50%; bottom: 1.25rem; z-index: 40; transform: translate(-50%, .5rem); max-width: calc(100% - 2rem); padding: .65rem 1rem; border-radius: .6rem; background: var(--ba-ink); color: #fff; font-size: .82rem; opacity: 0; visibility: hidden; transition: opacity .2s, transform .2s; }
.ba-toast.is-on { opacity: 1; visibility: visible; transform: translate(-50%, 0); }

/* overview */
.ba-insight { display: flex; align-items: center; gap: .65rem; padding: .7rem .9rem; border: 1px solid var(--ba-line); border-radius: .7rem; }
.ba-spark { flex: none; width: 1.15rem; height: 1.15rem; border-radius: 50%; background: var(--ba-orange); box-shadow: inset 0 0 0 4px #fff3; }
.ba-kpis { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); margin-top: .75rem; border: 1px solid var(--ba-line); border-radius: .7rem; }
.ba-kpi { padding: .85rem 1rem; min-width: 0; transition: background .15s; }
.ba-kpi + .ba-kpi { border-left: 1px solid var(--ba-line); }
.ba-kpi:hover { background: #fafafa; }
.ba-kpi-l { color: var(--ba-muted); font-size: .8rem; white-space: nowrap; }
.ba-kpi-v { display: flex; align-items: baseline; flex-wrap: wrap; gap: .4rem; margin-top: .35rem; font-size: 1.6rem; font-weight: 600; letter-spacing: -.02em; }
.ba-kpi-s { margin-top: .2rem; color: var(--ba-muted); font-size: .75rem; }
.ba-delta { font-size: .72rem; font-weight: 600; letter-spacing: 0; padding: .1rem .35rem; border-radius: .3rem; background: var(--ba-soft); color: var(--ba-muted); }
.ba-delta.is-up, .ba-delta.is-good { color: #15803d; background: #dcfce7; }
.ba-delta.is-down, .ba-delta.is-bad { color: #b91c1c; background: #fee2e2; }
.ba-card { margin-top: .75rem; padding: .9rem 1rem; border: 1px solid var(--ba-line); border-radius: .7rem; min-width: 0; }
.ba-card.ba-flush { padding: 0; overflow: hidden; }
.ba-card-h { display: flex; align-items: center; justify-content: space-between; gap: .75rem; flex-wrap: wrap; margin-bottom: .6rem; }
.ba-card-h.ba-pad { padding: .85rem 1rem 0; }
.ba-muted { color: var(--ba-muted); font-size: .78rem; }
.ba-foot { margin: .6rem 0 0; color: var(--ba-muted); font-size: .75rem; }
.ba-grid2 { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: .75rem; }

/* chart */
.ba-chart-t { display: inline-flex; align-items: center; gap: .35rem; }
.ba-sel { display: inline-flex; align-items: center; gap: .35rem; padding: .3rem .55rem; border: 0; border-radius: .45rem; background: var(--ba-soft); font-weight: 600; cursor: pointer; }
.ba-sel:hover { background: #ececf0; }
.ba-chart-r { display: inline-flex; align-items: center; gap: .9rem; }
.ba-seg { display: inline-flex; padding: .2rem; border-radius: .5rem; background: var(--ba-soft); gap: .1rem; }
.ba-seg button { border: 0; background: none; padding: .25rem .6rem; border-radius: .35rem; color: var(--ba-muted); cursor: pointer; }
.ba-seg button.is-on { background: #fff; color: var(--ba-ink); font-weight: 600; box-shadow: 0 1px 2px #0000001f; }
.ba-seg button:disabled { opacity: .35; cursor: default; }
.ba-switch { display: inline-flex; align-items: center; gap: .45rem; color: var(--ba-muted); cursor: pointer; white-space: nowrap; }
.ba-switch input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.ba-switch span { position: relative; width: 1.9rem; height: 1.1rem; border-radius: 1rem; background: #d4d4da; transition: background .15s; }
.ba-switch span::after { content: ''; position: absolute; top: .15rem; left: .15rem; width: .8rem; height: .8rem; border-radius: 50%; background: #fff; transition: transform .15s; box-shadow: 0 1px 2px #0003; }
.ba-switch input:checked + span { background: var(--ba-orange); }
.ba-switch input:checked + span::after { transform: translateX(.8rem); }
.ba-switch input:focus-visible + span { outline: 2px solid var(--ba-orange); outline-offset: 2px; }
.ba-switch.is-off { opacity: .45; cursor: default; }
.ba-legend { display: flex; flex-wrap: wrap; gap: .4rem 1rem; color: var(--ba-muted); font-size: .78rem; }
.ba-legend span { display: inline-flex; align-items: center; gap: .35rem; }
.ba-legend i { width: .6rem; height: .6rem; border-radius: .15rem; }
.ba-legend .is-dim { opacity: .5; }
i.is-eng { background: repeating-linear-gradient(135deg, #cbd5e1 0 3px, #f1f5f9 3px 6px) !important; outline: 1px dashed #94a3b8; outline-offset: -1px; }
.ba-plot { position: relative; height: 15rem; margin: 1rem 0 0 2.75rem; padding-bottom: 1.5rem; }
.ba-y { position: absolute; inset: 0 0 1.5rem -2.75rem; pointer-events: none; }
.ba-y span { position: absolute; left: 0; width: calc(100% + 2.75rem); transform: translateY(50%); font-size: .68rem; color: #9a9aa5; border-bottom: 1px solid #f0f0f3; line-height: 0; height: 0; }
.ba-bars { position: absolute; inset: 0 0 1.5rem 0; display: grid; grid-template-columns: repeat(var(--n), minmax(0, 1fr)); align-items: end; }
.ba-col { position: relative; height: 100%; display: flex; align-items: flex-end; justify-content: center; padding: 0 12%; cursor: crosshair; }
.ba-col:hover, .ba-col.is-hover { background: #f4f4f7; }
.ba-stack { width: 100%; max-width: 2.2rem; height: 100%; display: flex; flex-direction: column-reverse; }
.ba-stack i { display: block; width: 100%; min-height: 0; transition: filter .15s; }
.ba-stack i:last-child { border-radius: .2rem .2rem 0 0; }
.ba-col.is-hover .ba-stack i { filter: saturate(1.15) brightness(.95); }
.ba-mark { position: absolute; top: -.35rem; left: 50%; width: .45rem; height: .45rem; background: #555560; transform: translateX(-50%) rotate(45deg); z-index: 1; }
.ba-col.has-mark::before { content: ''; position: absolute; left: 50%; top: 0; bottom: 0; width: 1px; background: repeating-linear-gradient(#55556059 0 3px, transparent 3px 6px); z-index: 1; pointer-events: none; }
.ba-x { position: absolute; left: 0; right: 0; bottom: 0; height: 1.2rem; }
.ba-x span { position: absolute; transform: translateX(-50%); font-size: .7rem; color: #9a9aa5; white-space: nowrap; }
.ba-tip { position: absolute; top: -.5rem; z-index: 5; min-width: 11rem; padding: .6rem .7rem; border-radius: .55rem; background: var(--ba-ink); color: #fff; font-size: .75rem; opacity: 0; visibility: hidden; pointer-events: none; transition: opacity .12s; }
.ba-tip.is-on { opacity: 1; visibility: visible; }
.ba-tip div { display: flex; align-items: center; gap: .4rem; padding: .1rem 0; }
.ba-tip div b { margin-left: auto; padding-left: .75rem; }
.ba-tip i { width: .5rem; height: .5rem; border-radius: .1rem; }
.ba-tip-h { padding-bottom: .3rem !important; margin-bottom: .2rem; border-bottom: 1px solid #ffffff26; font-weight: 600; }
.ba-tip-m { color: #fdba74; }

/* tables */
.ba-scroll { overflow-x: auto; }
.ba-table { width: 100%; margin: 0; border-collapse: collapse; font-size: .82rem; }
/* the site's global table styles (Webflow: td borders, 18px text, a bold first row) stop here */
.ba-app .ba-table td, .ba-app .ba-table th, .ba-app .ba-table tr:first-child td { font-family: inherit; font-size: .82rem; line-height: 1.35; font-weight: 400; border: 0; vertical-align: middle; }
.ba-app .ba-table th { padding: .5rem .75rem; text-align: right; font-weight: 500; color: var(--ba-muted); font-size: .75rem; border-bottom: 1px solid var(--ba-line); white-space: nowrap; }
.ba-app .ba-table td { padding: .55rem .75rem; text-align: right; border-bottom: 1px solid #f1f1f4; white-space: nowrap; font-variant-numeric: tabular-nums; }
.ba-app .ba-table th:first-child, .ba-app .ba-table td:first-child { text-align: left; }
.ba-app .ba-card:not(.ba-flush) .ba-table th:first-child, .ba-app .ba-card:not(.ba-flush) .ba-table td:first-child { padding-left: 0; }
.ba-app .ba-card:not(.ba-flush) .ba-table th:last-child, .ba-app .ba-card:not(.ba-flush) .ba-table td:last-child { padding-right: 0; }
.ba-app .ba-table tbody tr:last-child td { border-bottom: 0; }
.ba-table tbody tr:hover td { background: #fafafb; }
.ba-table tr.is-click { cursor: pointer; }
.ba-table tr.is-sel td { background: #fff7ed; }
.ba-app .ba-table .is-warn { color: #c2410c; font-weight: 600; }
.ba-app .ba-table .is-good { color: #15803d; font-weight: 600; }
.ba-app .ba-table td.ba-empty, .ba-empty { padding: 2rem 1rem; text-align: center; color: var(--ba-muted); white-space: normal; }
.ba-name { display: inline-flex; align-items: center; gap: .55rem; }
.ba-name > span:last-child { display: flex; flex-direction: column; }
.ba-name small { display: flex; flex-wrap: wrap; gap: .3rem; margin-top: .15rem; color: var(--ba-muted); font-size: .72rem; }
.ba-indent { width: 1.25rem; }
.ba-co { display: inline-grid; place-items: center; flex: none; width: 1.3rem; height: 1.3rem; border-radius: .35rem; color: #fff; font-size: .68rem; font-weight: 700; }
.ba-by { display: inline-flex; align-items: center; gap: .2rem; }
.ba-by em { font-style: normal; color: var(--ba-muted); font-size: .72rem; margin-left: .15rem; }
.ba-path { font-family: ui-monospace, 'JetBrains Mono', Menlo, monospace; font-size: .78rem; }
.ba-sub { display: block; color: var(--ba-muted); font-size: .72rem; max-width: 20rem; overflow: hidden; text-overflow: ellipsis; }
.ba-cited, .ba-notcited { display: inline-block; margin-left: .5rem; padding: .05rem .4rem; border-radius: .3rem; font-size: .7rem; font-weight: 600; }
td > .ba-cited:first-child, td > .ba-notcited:first-child { margin-left: 0; }
.ba-cited { color: #15803d; background: #dcfce7; }
.ba-notcited { color: #6b6b76; background: var(--ba-soft); }
.ba-chip { display: inline-flex; align-items: center; gap: .3rem; }
.ba-chip i { width: .45rem; height: .45rem; border-radius: 50%; }
.ba-v { padding: 0 .35rem; border-radius: .3rem; font-weight: 600; font-size: .68rem; cursor: help; }
.ba-v.is-ok { color: #15803d; background: #dcfce7; }
.ba-v.is-grey { color: #55556a; background: #ececf2; }
.ba-v.is-bad { color: #b91c1c; background: #fee2e2; }
.ba-ok { display: inline-block; padding: .05rem .45rem; border-radius: .3rem; font-size: .72rem; font-weight: 600; color: #15803d; background: #dcfce7; }
.ba-warnchip { display: inline-block; padding: .05rem .45rem; border-radius: .3rem; font-size: .72rem; font-weight: 600; color: #b45309; background: #fef3c7; }
.ba-folder { display: inline-block; padding: .05rem .45rem; border-radius: .3rem; background: var(--ba-soft); font-size: .72rem; }
.ba-app .ba-table tr.ba-group td { background: #fbfbfc; font-weight: 600; }
.ba-app .ba-group.is-bad td { color: #b91c1c; background: #fef2f2; text-align: left; }
.ba-spoof td { color: #9a9aa5; text-decoration-color: #fca5a5; }
.ba-spoof s { text-decoration-color: #f87171; }
.ba-sparkline { display: block; margin-left: auto; }
.ba-app .ba-drawer td { background: #fafafb !important; white-space: normal; text-align: left !important; }
.ba-drawer-in { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.25rem; padding: .25rem 0; }
.ba-drawer-h { margin: 0 0 .35rem; font-size: .72rem; text-transform: uppercase; letter-spacing: .05em; color: var(--ba-muted); }
.ba-kv { display: flex; justify-content: space-between; align-items: center; gap: .75rem; padding: .2rem 0; }
.ba-kv > span:first-child { color: var(--ba-muted); }

/* tools rows, notes */
.ba-tools { display: flex; flex-wrap: wrap; align-items: center; gap: .6rem .9rem; }
.ba-search { min-width: 0; width: 12rem; padding: .45rem .7rem; border: 1px solid var(--ba-line); border-radius: .6rem; background: #fff; }
.ba-search:focus { outline: none; border-color: var(--ba-orange); box-shadow: 0 0 0 3px #f6671926; }
.ba-note { margin: .75rem 0 0; color: var(--ba-muted); font-size: .8rem; }

/* access & errors */
.ba-problem { margin-top: .75rem; border: 1px solid #fed7aa; border-radius: .7rem; background: #fffaf5; }
.ba-problem.is-mild { border-color: var(--ba-line); background: #fff; }
.ba-problem-h { display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; padding: .75rem 1rem; border-bottom: 1px solid #fde4cc; }
.ba-problem.is-mild .ba-problem-h { border-color: var(--ba-line); }
.ba-problem-h .ba-muted { margin-left: auto; }
.ba-bang { display: grid; place-items: center; width: 1.15rem; height: 1.15rem; border-radius: 50%; background: #ea580c; color: #fff; font-size: .7rem; font-weight: 700; }
.ba-problem.is-mild .ba-bang { background: #d97706; }
.ba-problem-b { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 1.5rem; padding: .75rem 1rem; }
.ba-problem-b p { margin: 0 0 .6rem; }
.ba-problem-f { display: flex; flex-wrap: wrap; gap: .5rem; padding: 0 1rem .9rem; }
.ba-hbar { display: grid; grid-template-columns: 8.5rem minmax(0, 1fr) 4rem; align-items: center; gap: .75rem; padding: .4rem 0; }
.ba-hbar div { height: .6rem; border-radius: .3rem; background: var(--ba-soft); overflow: hidden; }
.ba-hbar i { display: block; height: 100%; border-radius: .3rem; }
.ba-hbar b { text-align: right; font-variant-numeric: tabular-nums; }

@media (max-width: 991px) {
  .ba-kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .ba-kpi:nth-child(4) { border-left: 0; }
  .ba-kpi:nth-child(n+4) { border-top: 1px solid var(--ba-line); }
  .ba-grid2 { grid-template-columns: 1fr; }
}
@media (max-width: 767px) {
  .ba-demo-section .cw2-wrap { padding-top: 3.5rem; padding-left: .75rem; padding-right: .75rem; }
  .ba-demo-section .cw2-head { padding: 0 .5rem; }
  .ba-app { border-radius: .75rem; font-size: .82rem; }
  .ba-bar { border-radius: .75rem .75rem 0 0; }
  .ba-bar span { display: none; }
  .ba-app { height: clamp(30rem, calc(100svh - 10.5rem), 46rem); }
  .ba-body { padding: 1rem 0 0; }
  .ba-top, .ba-tabs, .ba-controls { margin-left: .85rem; margin-right: .85rem; }
  .ba-tabs { max-width: calc(100% - 1.7rem); }
  .ba-view { padding: .85rem .85rem 1.25rem; }
  .ba-title { font-size: 1.15rem; }
  .ba-tabs { display: flex; }
  .ba-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ba-kpi { padding: .7rem .75rem; }
  .ba-kpi + .ba-kpi { border-left: 0; }
  .ba-kpi:nth-child(even) { border-left: 1px solid var(--ba-line); }
  .ba-kpi:nth-child(n+3) { border-top: 1px solid var(--ba-line); }
  .ba-kpi:nth-child(4) { border-left: 1px solid var(--ba-line); }
  .ba-kpi-v { font-size: 1.3rem; }
  .ba-kpi-l { white-space: normal; }
  .ba-plot { height: 12rem; margin-left: 2.25rem; }
  .ba-y { left: -2.25rem; }
  .ba-chart-r { width: 100%; justify-content: space-between; }
  .ba-drawer-in, .ba-problem-b { grid-template-columns: 1fr; gap: .75rem; }
  .ba-search { flex: 1 1 10rem; }
  .ba-hbar { grid-template-columns: 6.5rem minmax(0, 1fr) 3rem; }
  /* long paths wrap on phones so the numbers stay on screen */
  .ba-app .ba-table td:first-child { white-space: normal; min-width: 9rem; }
  .ba-path { word-break: break-all; }
  .ba-app .ba-table td:first-child .ba-cited, .ba-app .ba-table td:first-child .ba-notcited { margin: .2rem 0 0; }
  .ba-app .ba-table td:first-child .ba-path { display: block; }
}
@media (prefers-reduced-motion: reduce) {
  .ba-app *, .ba-toast { transition: none !important; }
}

/* ---------- statement / bot-analytics-detail ---------- */
.bad .mx-o { color: var(--cw2-orange); }
.bad-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: 5rem; align-items: center; }
.bad-grid.is-left .bad-visual { order: -1; }
.bad .cw2-eyebrow + div .bad-h2 { margin-top: 1.5rem; }
.bad-h2 { font-size: 3rem; }
.bad-points { margin: 1.5rem 0 0; padding: 0; list-style: none; display: grid; gap: .7rem; max-width: 30rem; }
.bad-points li { position: relative; padding-left: 1.4rem; color: var(--cw2-text); font-size: 1rem; line-height: 1.5; }
.bad-points li::before { content: ''; position: absolute; left: 0; top: .55em; width: .5rem; height: .5rem; border-radius: 50%; background: var(--cw2-orange); }
.bad-btns { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 2rem; }

/* the illustrations (components/BotAnalyticsVisual.astro) */
.bav { position: relative; }
.bav::before { content: ''; position: absolute; inset: -12% -8%; background: radial-gradient(closest-side, #ec6b2d24, transparent); filter: blur(30px); z-index: 0; }
.bav-card { --bav-ink: #16161e; --bav-muted: #6b6b76; --bav-line: #e7e7ec; position: relative; z-index: 1; max-width: 32rem; margin: 0 auto; padding: 1.25rem; border-radius: 1rem; background: #fff; color: var(--bav-ink); font-size: .85rem; line-height: 1.4; box-shadow: 0 0 0 1px #ffffff1f, 0 1.5rem 4rem #00000080; }
.bav-h { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin-bottom: .9rem; }
.bav-h b { font-size: .95rem; }
.bav-h span, .bav-foot { color: var(--bav-muted); font-size: .75rem; }
.bav-h.is-sub { margin: 1.1rem 0 .4rem; }
.bav-foot { margin-top: .9rem; }
.bav-stackbar { display: flex; height: .7rem; border-radius: .35rem; overflow: hidden; margin-bottom: .6rem; }
.bav-job { display: grid; grid-template-columns: .65rem minmax(0, 1fr) auto; gap: .75rem; align-items: start; padding: .65rem 0; border-top: 1px solid #f1f1f4; }
.bav-job > i { width: .65rem; height: .65rem; margin-top: .3rem; border-radius: 50%; }
.bav-job b { display: block; }
.bav-job span { display: block; color: var(--bav-muted); font-size: .8rem; }
.bav-job small { display: block; margin-top: .2rem; font-family: ui-monospace, Menlo, monospace; font-size: .72rem; color: #4b4b57; }
.bav-job em { font-style: normal; font-weight: 600; font-variant-numeric: tabular-nums; }
.bav-req { padding: .75rem .85rem; border: 1px solid var(--bav-line); border-radius: .65rem; }
.bav-req + .bav-req { margin-top: .6rem; }
.bav-req.is-bad { border-color: #fecaca; background: #fffafa; }
.bav-req-top { display: flex; justify-content: space-between; gap: .75rem; font-weight: 600; }
.bav-req-top code, .bav-path { font-family: ui-monospace, 'JetBrains Mono', Menlo, monospace; font-size: .78rem; }
.bav-req-row { display: flex; justify-content: space-between; flex-wrap: wrap; gap: .25rem .75rem; margin-top: .3rem; color: var(--bav-muted); font-size: .78rem; }
.bav-tag { display: inline-block; margin-top: .5rem; padding: .1rem .5rem; border-radius: .3rem; font-size: .72rem; font-weight: 600; }
.bav-tag.is-ok, .bav-cited, .bav-ok { color: #15803d; background: #dcfce7; }
.bav-tag.is-grey, .bav-notcited { color: #55556a; background: #ececf2; }
.bav-tag.is-bad { color: #b91c1c; background: #fee2e2; }
.bav-cite { padding: .75rem 0; border-top: 1px solid #f1f1f4; }
.bav-cite:first-of-type { border-top: 0; padding-top: 0; }
.bav-cite-row { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: .75rem; align-items: center; }
.bav-cite-row .bav-path { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bav-cite-row > span:nth-child(2) { color: var(--bav-muted); font-size: .75rem; }
.bav-cited, .bav-notcited, .bav-ok, .bav-warn { display: inline-block; padding: .05rem .45rem; border-radius: .3rem; font-size: .72rem; font-weight: 600; white-space: nowrap; }
.bav-warn { color: #b45309; background: #fef3c7; }
.bav-cite p { margin: .35rem 0 0; color: var(--bav-muted); font-size: .8rem; }
.bav-cite p b { color: var(--bav-ink); }
.bav-time { list-style: none; margin: 0; padding: 0; position: relative; }
.bav-time::before { content: ''; position: absolute; left: .3rem; top: .6rem; bottom: .6rem; width: 1px; background: var(--bav-line); }
.bav-time li { position: relative; display: grid; grid-template-columns: .65rem minmax(0, 1fr) auto auto; gap: .75rem; align-items: center; padding: .5rem 0; }
.bav-time li i { width: .65rem; height: .65rem; border-radius: 50%; box-shadow: 0 0 0 3px #fff; }
.bav-time li em { font-style: normal; color: var(--bav-muted); font-size: .75rem; }
.bav-time li b { font-variant-numeric: tabular-nums; min-width: 3.5rem; text-align: right; }
.bav-time li.is-cite i { background: #16a34a; }
.bav-time li.is-cite b { color: #15803d; }
.bav-problem { border: 1px solid #fed7aa; border-radius: .65rem; background: #fffaf5; padding: .75rem .85rem; }
.bav-problem-h { display: flex; align-items: center; gap: .5rem; margin-bottom: .4rem; }
.bav-problem-h span { display: grid; place-items: center; width: 1.1rem; height: 1.1rem; border-radius: 50%; background: #ea580c; color: #fff; font-size: .7rem; font-weight: 700; }
.bav-kv { display: flex; justify-content: space-between; gap: 1rem; padding: .2rem 0; font-size: .8rem; }
.bav-kv > span:first-child { color: var(--bav-muted); }
.bav-kv > span:last-child { text-align: right; }
.bav-access { display: grid; grid-template-columns: minmax(0, 1fr) auto auto 3.5rem; gap: .5rem; align-items: center; padding: .45rem 0; border-top: 1px solid #f1f1f4; font-size: .8rem; }
.bav-access b { text-align: right; font-variant-numeric: tabular-nums; }
.bav-access b.is-warn { color: #c2410c; }
.bav-steps { list-style: none; margin: 0; padding: 0; display: grid; gap: .5rem; }
.bav-steps li { display: grid; grid-template-columns: 1.6rem minmax(0, 1fr) auto; gap: .75rem; align-items: center; padding: .7rem .8rem; border: 1px solid var(--bav-line); border-radius: .65rem; }
.bav-steps li > span { display: grid; place-items: center; width: 1.6rem; height: 1.6rem; border-radius: 50%; background: #f5f5f7; font-weight: 600; }
.bav-steps b { display: block; }
.bav-steps small { color: var(--bav-muted); font-size: .76rem; }
.bav-steps i { font-style: normal; color: #16a34a; font-weight: 700; }
.bav-ready { display: flex; align-items: center; gap: .55rem; margin-top: .9rem; padding: .6rem .8rem; border-radius: .6rem; background: #f0fdf4; color: #166534; font-weight: 500; font-size: .8rem; }

@media (max-width: 991px) {
  .bad-grid { grid-template-columns: 1fr; gap: 3rem; }
  .bad-grid.is-left .bad-visual { order: 0; }
  .bad-h2 { font-size: 2.75rem; }
}
@media (max-width: 767px) {
  .bad-h2 { font-size: 2.1rem; }
  .bav-card { padding: 1rem; font-size: .8rem; }
  .bav-access { grid-template-columns: minmax(0, 1fr) auto 3rem; }
  .bav-access > span:nth-child(2) { display: none; }
  .bav-cite-row { grid-template-columns: minmax(0, 1fr) auto; }
  .bav-cite-row > span:nth-child(2) { display: none; }
}

/* overview's two side-by-side tables: long paths wrap (with their "Cited" tag under them) so every column fits */
.ba-app .ba-grid2 .ba-table td:first-child { white-space: normal; }
.ba-grid2 .ba-path { word-break: break-all; }

/* the dashboard's intro is a short label above the window, not a full section heading */
.ba-demo-section .cw2-wrap { padding-top: 3.5rem; }
.ba-demo-section .cw2-head { margin-bottom: 1.75rem; }
.ba-demo-section .cw2-h2 { font-size: 2rem; line-height: 1.15; }
.ba-demo-section .cw2-head .cw2-eyebrow + .cw2-h2 { margin-top: .9rem; }
.ba-demo-section .cw2-lead { margin-top: .6rem; font-size: 1rem; }
@media (max-width: 767px) {
  .ba-demo-section .cw2-wrap { padding-top: 2.5rem; }
  .ba-demo-section .cw2-h2 { font-size: 1.6rem; }
  .ba-demo-section .cw2-head { margin-bottom: 1.25rem; }
}
