/* Agentic Platform page. Product-faithful mocks use the platform's own tokens: Inter, blue
   #2A6FC9, green #0B6F56, ink #0F1D2A, 10 to 14px radii. Illustrative data throughout. */
.ag-ui { --a-blue: #2A6FC9; --a-blue-soft: #EDF4FD; --a-blue-line: #C9DBF2; --a-green: #0B6F56; --a-green-soft: #E9F6F1; --a-green-line: #B5DCCB;
  --a-amber: #8A5E07; --a-amber-soft: #FFF8EA; --a-amber-line: #EBD6A6; --a-ink: #0F1D2A; --a-muted: #56606B; --a-line: #DFE4EA; --a-bg: #F7F9FB;
  color: var(--a-ink); font: 13px/1.5 Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; text-align: left; }
.ag-ui svg { flex: none; width: 15px; height: 15px; }
.ag-ui p { color: inherit; }
.ag-chip { display: inline-flex; align-items: center; padding: 1px 8px; border: 1px solid var(--a-line); border-radius: 6px; background: #fff; font-size: 11.5px; font-style: normal; font-weight: 500; line-height: 1.6; color: var(--a-muted); white-space: nowrap; }
.ag-chip.is-green { border-color: var(--a-green-line); background: var(--a-green-soft); color: var(--a-green); }
.ag-chip.is-amber { border-color: var(--a-amber-line); background: var(--a-amber-soft); color: var(--a-amber); }
.ag-chip.is-blue { border-color: var(--a-blue-line); background: var(--a-blue-soft); color: #1D5BAA; }
.ag-btn { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border: 1px solid var(--a-line); border-radius: 10px; background: #fff; font-size: 12.5px; font-weight: 500; color: var(--a-ink); white-space: nowrap; transition: box-shadow .3s ease; }
.ag-btn--primary { border-color: var(--a-blue); background: var(--a-blue); color: #fff; }
.ag-btn--primary svg { width: 13px; height: 13px; }
.ag-tabs { display: flex; gap: 18px; overflow: hidden; white-space: nowrap; border-bottom: 1px solid var(--a-line); font-size: 12.5px; color: var(--a-muted); }
.ag-tabs span { padding: 0 0 8px; border-bottom: 2px solid transparent; margin-bottom: -1px; }
.ag-tabs .is-current { border-bottom-color: var(--a-blue); font-weight: 500; color: var(--a-ink); }
.ag-block { padding: 11px 13px; border: 1px solid var(--a-line); border-radius: 12px; background: #fff; }
.ag-block > p:not(.ag-block-head) { font-size: 12.5px; line-height: 1.55; color: var(--a-muted); }
.ag-block-head { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.ag-block-head strong { font-size: 13px; font-weight: 600; }
.ag-block-head .ag-chip:first-of-type { margin-left: auto; }
.ag-toggle { position: relative; flex: none; width: 28px; height: 16px; border-radius: 999px; background: #CBD3DC; }
.ag-toggle i { position: absolute; top: 2px; left: 2px; width: 12px; height: 12px; border-radius: 50%; background: #fff; transition: transform .3s ease; }
.ag-toggle.is-on { background: var(--a-blue); }
.ag-toggle.is-on i { transform: translateX(12px); }

/* Hero: Architect builds the agent */
.ag-hero .hero-lead { max-width: 780px; }
.ag-builder { position: relative; z-index: 2; max-width: 1180px; margin-top: 44px; padding-bottom: 56px; }
.ag-app { overflow: hidden; border: 1px solid var(--a-line); border-radius: 14px; background: var(--a-bg); box-shadow: 0 30px 80px #13233124; }
.ag-top { display: flex; align-items: center; gap: 10px; height: 52px; padding: 0 16px; border-bottom: 1px solid var(--a-line); background: #fff; }
.ag-top strong { font: 600 15px/1 "Space Grotesk", Inter, sans-serif; letter-spacing: -.01em; }
.ag-top em { padding-left: 10px; border-left: 1px solid var(--a-line); font-style: normal; font-weight: 500; color: var(--a-muted); }
.ag-top-search { display: flex; align-items: center; gap: 8px; width: min(320px, 34%); margin-left: auto; padding: 6px 10px; border: 1px solid var(--a-line); border-radius: 10px; color: var(--a-muted); }
.ag-avatar { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: linear-gradient(120deg, #2A6FC9, #1D9BB8, #2FB39A); font-size: 11px; font-weight: 600; color: #fff; }
.ag-shell { display: grid; grid-template-columns: 180px minmax(0, 1fr); }
.ag-side { display: grid; align-content: start; gap: 2px; padding: 14px 10px; border-right: 1px solid var(--a-line); background: #fff; }
.ag-side small { margin: 10px 8px 4px; font-size: 10.5px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: #8A949E; }
.ag-side small:first-child { margin-top: 0; }
.ag-side span { padding: 6px 8px; border-radius: 8px; font-size: 12.5px; color: var(--a-muted); }
.ag-side .is-current { background: var(--a-blue-soft); font-weight: 500; color: #1D5BAA; }
.ag-screens { display: grid; grid-template-columns: minmax(0, 1fr); min-height: 520px; }
.ag-scene { grid-area: 1 / 1; display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.25fr); gap: 16px; padding: 18px; }
.is-ready .ag-scene { transition: opacity .45s ease, visibility .45s; }
.is-ready .ag-scene:not(.is-active) { opacity: 0; visibility: hidden; }
.ag-architect { display: flex; flex-direction: column; gap: 10px; padding: 16px; border: 1px solid var(--a-line); border-radius: 14px; background: #fff; }
.ag-kicker { display: flex; align-items: center; gap: 7px; font-size: 11.5px; font-weight: 600; letter-spacing: .04em; color: var(--a-blue); }
.ag-architect h3 { font: 600 19px/1.3 Inter, sans-serif; letter-spacing: -.02em; color: var(--a-ink); }
.ag-hint { margin-top: -4px; font-size: 12.5px; color: var(--a-muted) !important; }
.ag-brief { min-height: 118px; padding: 11px 13px; border: 1px solid var(--a-blue-line); border-radius: 10px; background: #FBFDFF; box-shadow: 0 0 0 3px #2A6FC914; font-size: 13px; line-height: 1.6; }
.ag-brief [data-ds-type] { display: block; min-height: 3em; }
.ag-steps { display: grid; gap: 6px; margin: 2px 0 0; padding: 0; list-style: none; }
.ag-steps li { display: flex; align-items: flex-start; gap: 8px; font-size: 12.5px; font-weight: 500; }
.ag-steps svg { margin-top: 2px; color: var(--a-green); }
.ag-steps small { display: block; font-weight: 400; color: var(--a-muted); }
.ag-architect .ag-btn--primary { align-self: flex-start; margin-top: 4px; }
.ag-agent { display: grid; align-content: start; gap: 9px; }
.ag-agent-head { display: flex; align-items: center; gap: 10px; }
.ag-agent-mark { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 10px; background: linear-gradient(120deg, #EDF4FD, #E9F6F1); color: var(--a-blue); }
.ag-agent-head strong { display: block; font-size: 15px; font-weight: 600; letter-spacing: -.01em; }
.ag-agent-head small { display: block; font-size: 12px; color: var(--a-muted); }
.ag-agent-head .ag-chip { margin-left: auto; }
.ag-goals { display: grid; gap: 4px; margin: 0; padding: 0; list-style: none; }
.ag-goals li { display: flex; align-items: center; gap: 7px; font-size: 12.5px; }
.ag-goals svg { width: 14px; height: 14px; color: var(--a-blue); }
.ag-goals--row { display: flex; flex-wrap: wrap; gap: 6px 14px; }
.ag-tools { display: grid; gap: 5px; margin: 0; padding: 0; list-style: none; }
.ag-tools li { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: 12.5px; }
.ag-tools li span { margin-right: auto; font-weight: 500; }
.ag-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.ag-cap-name { font-weight: 600; color: var(--a-ink) !important; }
.ag-journey { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 6px; }
.ag-journey span { padding: 1px 7px; border: 1px solid var(--a-blue-line); border-radius: 6px; background: var(--a-blue-soft); font-size: 11px; color: #1D5BAA; }
.ag-sources { display: grid; gap: 6px; margin: 0; padding: 0; list-style: none; }
.ag-sources li { display: flex; align-items: center; gap: 7px; font-size: 12.5px; font-weight: 500; }
.ag-sources svg { color: var(--a-muted); }
.ag-sources small { display: block; font-weight: 400; font-size: 11.5px; color: var(--a-muted); }

/* Section headings give the heading room before the side note. */
:is(.ag-domains, .ag-studio-section, .ag-govern, .ag-channels) .split-heading > div { flex: 1 1 auto; }
:is(.ag-domains, .ag-studio-section, .ag-govern, .ag-channels) .split-heading > p { flex: 0 1 420px; }

/* Any domain */
.ag-domains { border-top: 1px solid var(--line); }
.ag-gallery { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin: 0; padding: 0; list-style: none; }
.ag-gallery > li { display: flex; flex-direction: column; padding: 18px 18px 16px; border: 1px solid var(--a-line); border-radius: 14px; background: #fff; box-shadow: 0 18px 44px #13233110; }
.js-motion .ag-gallery > li:nth-child(3n + 2) { transition-delay: .1s; }
.js-motion .ag-gallery > li:nth-child(3n) { transition-delay: .2s; }
.ag-gallery-area { display: flex; align-items: center; gap: 7px; font-size: 11.5px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--a-blue) !important; }
.ag-gallery h3 { margin-top: 10px; font: 600 17px/1.3 Inter, sans-serif; letter-spacing: -.02em; color: var(--a-ink); }
.ag-spec { display: grid; gap: 0; margin: 14px 0 0; border-top: 1px solid var(--a-line); }
.ag-spec > div { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 10px; padding: 9px 0; border-bottom: 1px solid var(--a-line); }
.ag-spec > div:last-child { border-bottom: 0; padding-bottom: 0; }
.ag-spec dt { display: flex; align-items: center; gap: 6px; align-self: start; padding-top: 1px; font-size: 11px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; color: #7A848E; }
.ag-spec dt svg { width: 13px; height: 13px; color: var(--a-blue); }
.ag-spec dd { margin: 0; font-size: 12.5px; font-weight: 500; line-height: 1.5; }
.ag-spec-goals { display: flex; flex-wrap: wrap; gap: 4px; }
.ag-spec-goals span { padding: 0 7px; border: 1px solid var(--a-blue-line); border-radius: 6px; background: var(--a-blue-soft); font-size: 12px; color: #1D5BAA; }
.ag-gallery-tools { display: grid; gap: 5px; margin: 0; padding: 0; list-style: none; }
.ag-gallery-tools li { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 4px 8px; }
.ag-key { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin: 0 0 22px; padding: 14px 18px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); }
.ag-key > div { display: grid; gap: 2px; }
.ag-key dt { display: flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 500; color: var(--ink); }
.ag-key dt svg { width: 17px; height: 17px; color: var(--green); }
.ag-key dd { margin: 0 0 0 25px; font-size: 13px; line-height: 1.5; color: var(--muted); }
.ag-gallery-foot { margin-top: 22px; font-size: 14px; }

/* Studio tour */
.ag-studio-section { border-top: 1px solid var(--line); background: var(--surface); }
.ag-studio { display: grid; grid-template-columns: minmax(260px, .7fr) minmax(0, 1.5fr); gap: 24px; align-items: start; }
.ag-studio-tabs { display: grid; gap: 8px; }
.ag-studio-tabs button { display: grid; gap: 4px; padding: 14px 16px; border: 1px solid var(--line); border-left: 3px solid var(--line); border-radius: 10px; background: var(--paper); text-align: left; transition: border-color .25s ease, background .25s ease; }
.ag-studio-tabs strong { font-size: 16px; font-weight: 500; letter-spacing: -.02em; color: var(--ink); }
.ag-studio-tabs span { display: none; font-size: 13px; line-height: 1.65; color: var(--muted); }
.ag-studio-tabs button[aria-pressed="true"] { border-color: color-mix(in srgb, var(--green) 35%, var(--line)); border-left-color: var(--green); background: #fff; }
.ag-studio-tabs button[aria-pressed="true"] span { display: block; }
.ag-studio-screen { display: grid; grid-template-columns: minmax(0, 1fr); overflow: hidden; min-height: 500px; border: 1px solid var(--a-line); border-radius: 14px; background: var(--a-bg); box-shadow: 0 26px 70px #1323311c; }
.ag-sscene { grid-area: 1 / 1; display: grid; grid-template-columns: minmax(0, 1fr); min-width: 0; align-content: start; gap: 10px; padding: 18px; }
.is-ready .ag-sscene { transition: opacity .45s ease, visibility .45s; }
.is-ready .ag-sscene:not(.is-active) { opacity: 0; visibility: hidden; }
.ag-screen-head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.ag-screen-head > span:first-child { margin-right: auto; }
.ag-screen-head strong { display: block; font-size: 16px; font-weight: 600; letter-spacing: -.015em; }
.ag-screen-head small { display: block; font-size: 12px; color: var(--a-muted); }
.ag-tabs-right { display: flex; gap: 14px; margin-left: auto; }
.ag-tool { display: grid; gap: 8px; padding: 10px 11px; border: 1px solid var(--a-line); border-radius: 10px; background: var(--a-bg); }
.ag-tool-head { display: flex; flex-wrap: wrap; align-items: center; gap: 7px; }
.ag-tool-head strong { margin-right: auto; font-size: 12.5px; font-weight: 600; }
.ag-facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px 14px; margin: 0; }
.ag-facts dt { font-size: 11px; color: var(--a-muted); }
.ag-facts dd { margin: 0; font-size: 12.5px; font-weight: 500; }
.ag-limits { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-top: 6px; font-size: 12px; }
.ag-limits b { margin-left: 4px; color: var(--a-ink); }
.ag-canvas { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, .8fr); gap: 16px; padding: 16px; border: 1px solid var(--a-line); border-radius: 12px; background-color: #fff; background-image: radial-gradient(#DCE3EA 1px, transparent 1px); background-size: 16px 16px; }
.ag-flow { display: grid; gap: 10px; margin: 0; padding: 0; list-style: none; }
.ag-flow li { position: relative; padding: 8px 11px; border: 1px solid var(--a-line); border-left: 3px solid var(--a-blue); border-radius: 10px; background: #fff; }
.ag-flow li + li::before { content: ''; position: absolute; left: 22px; top: -11px; width: 1px; height: 10px; background: #B9C4CF; }
.ag-flow li.is-choice { border-left-color: var(--a-amber); }
.ag-flow li.is-end { border-left-color: var(--a-green); }
.ag-flow b, .ag-branch b { display: block; font-size: 12.5px; font-weight: 600; }
.ag-flow small, .ag-branch small { display: block; font-size: 11.5px; color: var(--a-muted); }
.ag-branch { align-self: center; display: grid; gap: 6px; }
.ag-branch > span { font-size: 11px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; color: var(--a-amber); }
.ag-branch p { padding: 8px 11px; border: 1px dashed var(--a-amber-line); border-left: 3px solid var(--a-amber); border-radius: 10px; background: var(--a-amber-soft); }
/* Knowledge: sources sync into the graph, the graph learns, an answer cites it. */
.ag-ksources { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 8px; margin: 0; padding: 0; list-style: none; }
.ag-ksources li { display: grid; align-content: start; gap: 3px; min-width: 0; padding: 9px 10px; border: 1px solid var(--a-line); border-radius: 12px; background: #fff; }
.ag-ksources li p { display: flex; align-items: center; gap: 6px; min-width: 0; }
.ag-ksources li p b { overflow: hidden; font-size: 12.5px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.ag-ksources svg { width: 14px; height: 14px; color: var(--a-blue); }
.ag-ksources small { overflow: hidden; font-size: 11px; color: var(--a-muted); text-overflow: ellipsis; white-space: nowrap; }
.ag-ksources i { display: block; height: 4px; margin: 5px 0 3px; border-radius: 999px; background: #E6EBF0; overflow: hidden; }
.ag-ksources i b { display: block; height: 100%; border-radius: 999px; background: linear-gradient(90deg, #2A6FC9, #1D9BB8, #2FB39A); transform: scaleX(0); transform-origin: left; transition: transform 1.9s cubic-bezier(.3, 0, .2, 1); }
.ag-ksources li:nth-child(2) i b { transition-delay: .15s; }
.ag-ksources li:nth-child(3) i b { transition-delay: .3s; }
.ag-ksources li:nth-child(4) i b { transition-delay: .45s; }
.ag-ksources li:nth-child(5) i b { transition-delay: .6s; }
.ag-kscene:not([data-ds-beat="0"]) .ag-ksources i b { transform: none; }
.ag-kscene[data-ds-beat="0"] .ag-ksources i b { transition: none; }
.ag-ksources .ag-chip { justify-self: start; max-width: 100%; overflow: hidden; text-overflow: ellipsis; }
.ag-ksources li.is-add { align-content: center; justify-items: center; gap: 4px; border-style: dashed; border-color: #B9C7D6; background: transparent; text-align: center; font-size: 12px; font-weight: 500; color: var(--a-blue); }
.ag-ui .ag-kfeed { display: block; width: 100%; height: 34px; margin: -10px 0 -10px; overflow: visible; }
.ag-kfeed path { fill: none; stroke: #C3CEDA; stroke-width: 2; stroke-dasharray: 4 6; vector-effect: non-scaling-stroke; transition: stroke .4s ease; }
.ag-kscene:is([data-ds-beat="1"], [data-ds-beat="2"]) .ag-kfeed path { stroke: var(--a-blue); animation: ag-feed .7s linear infinite; }
@keyframes ag-feed { to { stroke-dashoffset: -16; } }
.ag-kstatus { position: relative; min-height: 20px; margin-top: -2px; font-size: 12px; }
.ag-kstatus > span { position: absolute; inset: 0 0 auto; display: flex; align-items: center; gap: 7px; }
.ag-kstatus-2 { color: var(--a-green); font-weight: 500; }
.ag-kstatus-2 svg { width: 14px; height: 14px; }
.ag-kscene:not([data-ds-beat="0"]):not([data-ds-beat="1"]) .ag-kstatus-1 { opacity: 0 !important; }
.ag-studio:not(.is-ready) .ag-kstatus-1 { display: none; }
.ag-graph { margin: 0; padding: 10px 14px 8px; border: 1px solid var(--a-line); border-radius: 12px; background-color: #fff; background-image: radial-gradient(#E3E9EF 1px, transparent 1px); background-size: 14px 14px; }
.ag-graph figcaption b { display: block; font-size: 12.5px; font-weight: 600; }
.ag-graph figcaption small { display: block; font-size: 11px; color: var(--a-muted); }
.ag-graph svg { display: block; width: 100%; height: auto; margin-top: 4px; overflow: visible; font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; }
.kg-edges path { fill: none; stroke: #B9C4CF; stroke-width: 1.2; }
.kg-edges path.kg-learned { stroke: var(--a-green); stroke-width: 2; stroke-dasharray: 1; stroke-dashoffset: 1; transition: stroke-dashoffset 1.1s ease .2s; }
.kg-edges .is-on path.kg-learned { stroke-dashoffset: 0; }
.kg-edges text { font-size: 10px; fill: var(--a-muted); }
.kg-edges text.kg-tag { font-weight: 600; fill: var(--a-green); }
.kg-node rect { fill: #fff; stroke: var(--a-line); stroke-width: 1; }
.kg-node text { font-size: 12px; font-weight: 500; fill: var(--a-ink); }
.kg-node text.kg-type { font-size: 8.5px; font-weight: 600; letter-spacing: .08em; fill: #8A949E; }
.kg-product rect { fill: var(--a-blue-soft); stroke: var(--a-blue-line); }
.kg-issue rect { stroke: var(--a-amber-line); }
.kg-node--learned rect { fill: var(--a-green-soft); stroke: var(--a-green); stroke-width: 1.5; }
.kg-node--learned rect.kg-pulse { fill: none; stroke: var(--a-green); stroke-width: 2; opacity: 0; transform-box: fill-box; transform-origin: center; }
.is-playing .kg-node--learned.is-on rect.kg-pulse { animation: ag-ring 1.6s ease-out 2; }
@keyframes ag-ring { 0% { opacity: .7; transform: scale(1); } 100% { opacity: 0; transform: scale(1.25, 1.6); } }
.kg-node--learned text.kg-type { fill: var(--a-green); }
.kg-strike { stroke: #9AA4AE; stroke-width: 1.2; }
.kg-old { transition: fill .4s ease; }
.ag-kscene:is([data-ds-beat="4"], [data-ds-beat="5"], [data-ds-beat="6"]) .kg-old { fill: #9AA4AE; }
.kg-node text.kg-new { font-weight: 600; fill: var(--a-green); }
.ag-graph svg text.kg-note { font-size: 10px; font-style: italic; fill: var(--a-muted); }
.ag-reply { padding: 10px 12px; border: 1px solid var(--a-line); border-radius: 12px; background: #fff; }
.ag-reply > p:first-child { font-size: 12.5px; }
.ag-reply-ask { display: block; margin-bottom: 4px; font-size: 12px; color: var(--a-muted); }
.ag-reply-ask::before { content: '“'; }
.ag-reply-ask::after { content: '”'; }
.ag-reply small { display: block; margin-top: 8px; font-size: 11px; font-weight: 600; color: var(--a-muted); }
.ag-cites { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 4px; }
.ag-cites span { padding: 1px 8px; border: 1px solid var(--a-line); border-radius: 999px; background: var(--a-bg); font-size: 11px; color: var(--a-muted); }
.ag-how { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin: 0; padding: 0; list-style: none; counter-reset: how; }
.ag-how li { padding: 9px 11px; border: 1px solid var(--a-line); border-radius: 10px; background: #fff; counter-increment: how; }
.ag-how b::before { content: counter(how) '  '; color: var(--a-blue); }
.ag-how b { display: block; font-size: 12.5px; font-weight: 600; }
.ag-how small { display: block; font-size: 11.5px; color: var(--a-muted); }
.ag-conns { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin: 0; padding: 0; list-style: none; }
.ag-conns li { display: flex; align-items: center; gap: 9px; padding: 9px 11px; border: 1px solid var(--a-line); border-radius: 12px; background: #fff; }
.ag-conns svg { width: 17px; height: 17px; color: var(--a-blue); }
.ag-conns li > span { min-width: 0; margin-right: auto; }
.ag-conns b { display: block; font-size: 12.5px; font-weight: 600; }
.ag-conns small { display: block; font-size: 11.5px; color: var(--a-muted); }
.ag-mcp { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 5px; }
.ag-mcp code, .ag-map code, .ag-facts code, .ag-endpoint code { font: 11.5px/1.5 "JetBrains Mono", ui-monospace, SFMono-Regular, Consolas, monospace; }
.ag-mcp code { padding: 0 6px; border: 1px solid var(--a-line); border-radius: 5px; background: var(--a-bg); color: #1D5BAA; }
.ag-endpoint { display: flex; align-items: center; gap: 8px; padding: 8px 10px; border: 1px solid var(--a-line); border-radius: 10px; background: #0F1D2A; color: #E7EEF5 !important; }
.ag-endpoint b, .ag-method { padding: 1px 7px; border-radius: 5px; background: #2A6FC9; font: 600 11px/1.5 "JetBrains Mono", ui-monospace, monospace; color: #fff; }
.ag-method { background: #0B6F56; }
.ag-endpoint code { overflow: hidden; font-size: 12.5px; text-overflow: ellipsis; white-space: nowrap; }
.ag-endpoint i { font-style: normal; color: #8FD3C1; }
.ag-map { width: 100%; border-collapse: collapse; font-size: 12px; }
.ag-map th { padding: 0 0 4px; font-size: 11px; font-weight: 600; text-align: left; color: var(--a-muted); }
.ag-map td { padding: 5px 0; border-top: 1px solid var(--a-line); vertical-align: top; }
.ag-map td:first-child { width: 36%; padding-right: 10px; }
.ag-map td code { color: #1D5BAA; }
.ag-checks-note { margin-left: auto; font-weight: 400; color: var(--a-muted); }
.ag-action { display: grid; grid-template-columns: minmax(0, 1fr); min-width: 0; gap: 10px; padding: 12px 13px; border: 1px solid var(--a-line); border-radius: 12px; background: #fff; }
.ag-action .ag-block-head { flex-wrap: wrap; margin: 0; }
.ag-action .ag-block-head small { font-size: 11.5px; color: var(--a-muted); }
.ag-action .ag-block-head .ag-chip { margin-left: auto; }
.ag-steps-row { display: flex; flex-wrap: wrap; gap: 6px; font-size: 12px; color: var(--a-muted); }
.ag-steps-row span { padding: 3px 9px; border: 1px solid var(--a-line); border-radius: 8px; }
.ag-steps-row .is-current { border-color: var(--a-blue-line); background: var(--a-blue-soft); color: #1D5BAA; font-weight: 500; }
.ag-outcomes { display: grid; gap: 5px; margin: 0; padding: 10px 0 0; border-top: 1px solid var(--a-line); list-style: none; }
.ag-outcomes li { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px; font-size: 12.5px; font-weight: 500; }
.ag-checks { display: flex; flex-wrap: wrap; gap: 14px; font-size: 12.5px; font-weight: 500; }
.ag-checks span { display: inline-flex; align-items: center; gap: 6px; }
.ag-checks svg { color: var(--a-green); }

/* The decision layer */
.ag-decides { border-top: 1px solid var(--line); }
.ag-center-head { max-width: 860px; margin-inline: auto; text-align: center; }
.ag-center-head > p:not(.eyebrow) { margin-inline: auto; }
.ag-decide { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.45fr) minmax(0, 1fr); gap: 22px; align-items: center; }
.ag-layer { padding: 4px 0; }
.ag-layer-kicker { display: flex; align-items: center; gap: 8px; font-size: 11px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--green); }
.ag-layer-kicker svg { width: 17px; height: 17px; }
.ag-layer h3 { margin-top: 10px; font-size: 26px; letter-spacing: -.04em; }
.ag-layer ul { margin: 16px 0 0; padding: 0; list-style: none; }
.ag-layer li { position: relative; padding: 11px 12px 11px 30px; border-top: 1px solid var(--line); font-size: 13.5px; line-height: 1.6; color: var(--ink); transition: background .4s ease, color .4s ease; }
.ag-layer li::before { content: ''; position: absolute; left: 10px; top: 1.2em; width: 8px; height: 8px; border-radius: 50%; border: 1.5px solid color-mix(in srgb, var(--green) 55%, transparent); transition: background .4s ease, box-shadow .4s ease; }
.ag-layer--platform li::before { border-radius: 2px; }
.ag-decide[data-ds-beat="1"] [data-lit~="1"], .ag-decide[data-ds-beat="2"] [data-lit~="2"], .ag-decide[data-ds-beat="3"] [data-lit~="3"], .ag-decide[data-ds-beat="4"] [data-lit~="4"], .ag-decide[data-ds-beat="5"] [data-lit~="5"], .ag-decide[data-ds-beat="6"] [data-lit~="6"], .ag-decide[data-ds-beat="7"] [data-lit~="7"] { border-radius: 8px; background: var(--st-tint-strong); }
.ag-decide[data-ds-beat="1"] [data-lit~="1"]::before, .ag-decide[data-ds-beat="2"] [data-lit~="2"]::before, .ag-decide[data-ds-beat="3"] [data-lit~="3"]::before, .ag-decide[data-ds-beat="4"] [data-lit~="4"]::before, .ag-decide[data-ds-beat="5"] [data-lit~="5"]::before, .ag-decide[data-ds-beat="6"] [data-lit~="6"]::before, .ag-decide[data-ds-beat="7"] [data-lit~="7"]::before { background: var(--green); box-shadow: 0 0 0 4px color-mix(in srgb, var(--green) 18%, transparent); }
.ag-run { overflow: hidden; border: 1px solid var(--a-line); border-radius: 14px; background: #fff; box-shadow: 0 26px 70px #1323311c; }
.ag-run-top { display: flex; align-items: center; gap: 10px; padding: 11px 14px; border-bottom: 1px solid var(--a-line); }
.ag-run-top strong { font-size: 13px; font-weight: 600; }
.ag-run-top span { margin-right: auto; color: var(--a-muted); }
.ag-run-thread { display: grid; align-content: start; gap: 9px; height: 470px; padding: 14px; overflow: hidden; background: var(--a-bg); }
.ag-msg { justify-self: start; max-width: 88%; padding: 9px 12px; border: 1px solid var(--a-line); border-radius: 12px 12px 12px 3px; background: #fff; font-size: 13px; line-height: 1.55; }
.ag-msg small { display: block; margin-bottom: 2px; font-size: 11px; font-weight: 500; color: var(--a-muted); }
.ag-msg--user { justify-self: end; border-color: transparent; border-radius: 12px 12px 3px 12px; background: #E2EAF4; }
.ag-msg [data-ds-type] { display: block; min-height: 1.55em; }
.ag-activity { display: inline-flex; align-items: center; gap: 8px; justify-self: start; font-size: 12px; color: var(--a-muted); }
.ag-activity i { width: 7px; height: 7px; border-radius: 50%; background: var(--a-blue); }
.is-playing .ag-activity.is-on i { animation: ag-pulse 1.2s ease-in-out infinite; }
@keyframes ag-pulse { 0%, 100% { opacity: .3; } 50% { opacity: 1; } }
.ag-review { display: grid; gap: 6px; padding: 12px 13px; border: 1px solid var(--a-amber-line); border-radius: 12px; background: var(--a-amber-soft); }
.ag-review-kicker { display: flex; align-items: center; gap: 7px; font-size: 11.5px; font-weight: 600; color: var(--a-amber) !important; }
.ag-review > strong { font-size: 14px; font-weight: 600; }
.ag-review dl { display: grid; grid-template-columns: 76px minmax(0, 1fr); gap: 3px 10px; margin: 2px 0 0; font-size: 12.5px; }
.ag-review dt { color: var(--a-muted); }
.ag-review dd { margin: 0; font-weight: 500; }
.ag-review-actions { display: flex; gap: 8px; margin-top: 6px; }
.ag-review .ag-btn--primary.is-on { box-shadow: 0 0 0 3px #2A6FC933; }
.is-ready .ag-review .ag-btn--primary[data-beat] { opacity: .55; transform: none; }
.is-ready .ag-review .ag-btn--primary[data-beat].is-on { opacity: 1; }
.ag-verified { display: inline-flex; align-items: center; gap: 7px; justify-self: start; padding: 4px 10px; border: 1px solid var(--a-green-line); border-radius: 999px; background: var(--a-green-soft); font-size: 12px; font-weight: 500; color: var(--a-green) !important; }
.ag-taskreview { padding: 11px 12px; border: 1px solid var(--a-line); border-radius: 12px; background: #fff; }
.ag-taskreview > p b { display: block; font-size: 12.5px; font-weight: 600; }
.ag-taskreview > p small { display: block; font-size: 11px; color: var(--a-muted); }
.ag-taskreview ul { display: grid; gap: 5px; margin: 8px 0 0; padding: 0; list-style: none; }
.ag-taskreview li { display: flex; align-items: center; gap: 7px; font-size: 12px; font-weight: 500; }
.ag-taskreview li svg { color: var(--a-green); }
.ag-taskreview em { margin-left: auto; font-style: normal; font-weight: 400; color: var(--a-muted); }
.ag-decide-foot { max-width: 860px; margin: 30px auto 0; font-size: 14px; line-height: 1.8; text-align: center; }
.ag-decide-foot strong { font-weight: 500; color: var(--ink); }

/* Console */
.ag-console-section { border-top: 1px solid var(--line); background: var(--surface); }
.ag-console-grid { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, .9fr); gap: 48px; align-items: center; }
.ag-console { overflow: hidden; border: 1px solid var(--a-line); border-radius: 14px; background: #fff; box-shadow: 0 26px 70px #1323311c; }
.ag-console-top { display: flex; align-items: center; gap: 16px; padding: 12px 16px; border-bottom: 1px solid var(--a-line); font-size: 12.5px; color: var(--a-muted); }
.ag-console-top strong { font-size: 14px; font-weight: 600; color: var(--a-ink); }
.ag-console-top .is-current { font-weight: 500; color: var(--a-ink); }
.ag-live { display: inline-flex; align-items: center; gap: 6px; margin-left: auto; font-style: normal; font-weight: 500; color: var(--a-green); }
.ag-live i { width: 7px; height: 7px; border-radius: 50%; background: var(--a-green); box-shadow: 0 0 0 3px #0B6F5622; }
.ag-console-body { display: grid; grid-template-columns: minmax(0, .95fr) minmax(0, 1.2fr); min-height: 430px; }
.ag-queue { display: grid; align-content: start; gap: 10px; padding: 14px; border-right: 1px solid var(--a-line); background: var(--a-bg); }
.ag-filters { display: flex; flex-wrap: wrap; gap: 5px; }
.ag-filters span { padding: 2px 9px; border: 1px solid var(--a-line); border-radius: 999px; background: #fff; font-size: 11.5px; color: var(--a-muted); }
.ag-filters .is-current { border-color: var(--a-blue-line); background: var(--a-blue-soft); color: #1D5BAA; }
.ag-queue ul { display: grid; gap: 7px; margin: 0; padding: 0; list-style: none; }
.ag-queue li { display: grid; gap: 4px; padding: 9px 11px; border: 1px solid var(--a-line); border-radius: 10px; background: #fff; }
.ag-queue li.is-current { border-color: var(--a-blue-line); box-shadow: inset 3px 0 0 var(--a-blue); }
.ag-queue small { font-size: 11px; color: var(--a-muted); }
.ag-queue b { font-size: 12.5px; font-weight: 500; line-height: 1.45; }
.ag-queue .ag-chip { justify-self: start; }
.ag-handoff { display: grid; align-content: start; gap: 10px; padding: 14px; }
.ag-brief-card { padding: 10px 12px; border: 1px solid var(--a-line); border-radius: 12px; }
.ag-brief-card ul { display: grid; gap: 4px; margin: 0; padding: 0; list-style: none; }
.ag-brief-card li { display: flex; align-items: center; gap: 7px; font-size: 12.5px; }
.ag-brief-card svg { color: var(--a-green); }
.ag-why { padding: 10px 12px; border: 1px solid var(--a-amber-line); border-radius: 12px; background: var(--a-amber-soft); }
.ag-why b { font-size: 12.5px; font-weight: 600; color: var(--a-amber); }
.ag-why p { margin-top: 2px; font-size: 12.5px; }
.ag-handoff > .ag-btn--primary { justify-self: start; }
.ag-joined { display: flex; align-items: center; gap: 10px; font-size: 11px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; color: var(--a-muted) !important; }
.ag-joined::before, .ag-joined::after { content: ''; flex: 1; height: 1px; background: var(--a-line); }
.ag-msg--agent-human { border-color: var(--a-green-line); background: var(--a-green-soft); }
.ag-state { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 7px; font-size: 12.5px; font-weight: 600; color: var(--a-blue) !important; }
.ag-state small { flex-basis: 100%; font-weight: 400; color: var(--a-muted); }
.ag-console-copy .section-heading { margin-bottom: 26px; }
.ag-points { display: grid; margin: 0; padding: 0; list-style: none; }
.ag-points li { display: flex; gap: 14px; padding: 15px 0; border-top: 1px solid var(--line); font-size: 13.5px; line-height: 1.7; color: var(--muted); }
.ag-points svg { flex: none; width: 20px; height: 20px; margin-top: 2px; color: var(--green); }
.ag-points b { display: block; margin-bottom: 2px; font-size: 15px; font-weight: 500; color: var(--ink); }

/* Governance */
.ag-govern { border-top: 1px solid var(--line); }
.ag-controls { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin: 0; padding: 0; list-style: none; }
.ag-controls > li { padding: 14px 14px 20px; border: 1px solid var(--line); border-radius: 16px; background: var(--surface); }
.js-motion .ag-controls > li:nth-child(3n + 2) { transition-delay: .1s; }
.js-motion .ag-controls > li:nth-child(3n) { transition-delay: .2s; }
.ag-controls h3 { display: flex; align-items: center; gap: 9px; margin: 18px 6px 0; font: 500 19px/1.3 var(--sans); letter-spacing: -.03em; color: var(--ink); }
.ag-controls h3 svg { width: 18px; height: 18px; color: var(--green); }
.ag-controls > li > p { margin: 8px 6px 0; font: 14px/1.75 var(--sans); color: var(--muted); }
.ag-glimpse { display: grid; align-content: center; gap: 8px; min-height: 132px; padding: 14px; border: 1px solid var(--a-line); border-radius: 12px; background: #fff; }
.ag-roles { display: flex; flex-wrap: wrap; gap: 6px; }
.ag-roles span { padding: 3px 10px; border: 1px solid var(--a-blue-line); border-radius: 999px; background: var(--a-blue-soft); font-size: 12px; font-weight: 500; color: #1D5BAA; }
.ag-glimpse-line { display: flex; align-items: center; gap: 7px; font-size: 12px; color: var(--a-muted) !important; }
.ag-glimpse-row { display: flex; align-items: center; gap: 8px; font-size: 12.5px; font-weight: 500; }
.ag-glimpse-row .ag-chip { margin-left: auto; }
.ag-glimpse-row.is-off { color: var(--a-muted) !important; }
.ag-limit-list { display: grid; gap: 5px; margin: 0; }
.ag-limit-list div { display: flex; justify-content: space-between; gap: 12px; padding-bottom: 5px; border-bottom: 1px solid var(--a-line); font-size: 12.5px; }
.ag-limit-list div:last-child { padding-bottom: 0; border-bottom: 0; }
.ag-limit-list dt { color: var(--a-muted); }
.ag-limit-list dd { margin: 0; font-weight: 600; font-variant-numeric: tabular-nums; }
.ag-glimpse-label { font-size: 11px; font-weight: 600; color: var(--a-muted) !important; }
.ag-fields { display: flex; flex-wrap: wrap; gap: 5px; }
.ag-fields span { padding: 1px 8px; border: 1px solid var(--a-line); border-radius: 6px; background: var(--a-bg); font-size: 12px; }
.ag-fields.is-redacted span { color: var(--a-muted); text-decoration: line-through; text-decoration-color: #9AA4AE; }
.ag-trace { display: flex; flex-wrap: wrap; gap: 5px; }
.ag-trace span { padding: 3px 9px; border: 1px solid var(--a-line); border-left: 3px solid var(--a-blue); border-radius: 6px; font-size: 12px; font-weight: 500; }
.ag-spend { display: grid; gap: 5px; margin-top: 2px; font-size: 12px; color: var(--a-muted) !important; }
.ag-spend i { display: block; height: 8px; border-radius: 999px; background: #E3E9F0; overflow: hidden; }
.ag-spend b { display: block; width: 42%; height: 100%; border-radius: 999px; background: linear-gradient(120deg, #2A6FC9, #1D9BB8, #2FB39A); }

/* Channels */
.ag-channels { border-top: 1px solid var(--line); background: var(--surface); }
.ag-channel-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 48px; margin: 0; padding: 0; list-style: none; }
.ag-channel-list li { display: flex; gap: 16px; padding: 20px 0; border-top: 1px solid var(--line); }
.ag-channel-list svg { flex: none; width: 36px; height: 36px; padding: 8px; border: 1px solid var(--line); border-radius: 10px; background: var(--paper); color: var(--green); }
.ag-channel-list h3 { font-size: 18px; letter-spacing: -.03em; }
.ag-channel-list p { margin-top: 4px; font-size: 13.5px; line-height: 1.7; }
.ag-channel-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.ag-channel-tags span { padding: 1px 9px; border: 1px solid var(--line); border-radius: 999px; font-size: 11.5px; color: var(--muted); }

@media (prefers-reduced-motion: reduce) {
  .ag-kfeed path, .kg-node--learned rect.kg-pulse { animation: none !important; }
}
@media (max-width: 1100px) {
  .ag-shell { grid-template-columns: minmax(0, 1fr); }
  .ag-side { display: none; }
  .ag-gallery, .ag-controls { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ag-key { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ag-studio { grid-template-columns: minmax(0, 1fr); }
  .ag-studio-tabs { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .ag-studio-tabs button[aria-pressed="true"] span { display: none; }
  .ag-decide { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .ag-decide .ag-run { grid-column: 1 / -1; grid-row: 1; }
  .ag-console-grid { grid-template-columns: minmax(0, 1fr); }
  .ag-console-copy { order: -1; }
}
@media (max-width: 760px) {
  .ag-builder { padding-bottom: 40px; }
  .ag-top-search { display: none; }
  .ag-avatar { margin-left: auto; }
  .ag-scene { grid-template-columns: minmax(0, 1fr); padding: 12px; }
  .ag-screens { min-height: 0; }
  .ag-pair { grid-template-columns: minmax(0, 1fr); }
  .ag-brief { min-height: 0; }
  .ag-gallery, .ag-controls, .ag-channel-list { grid-template-columns: minmax(0, 1fr); }
  .ag-studio-tabs { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ag-studio-tabs button { padding: 10px 12px; }
  .ag-studio-tabs strong { font-size: 14px; }
  .ag-studio-screen { min-height: 0; }
  .ag-sscene { padding: 12px; }
  .ag-canvas { grid-template-columns: minmax(0, 1fr); }
  .ag-ksources { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ag-ui .ag-kfeed { display: none; }
  .ag-kstatus { min-height: 38px; }
  .ag-graph { overflow-x: auto; }
  .ag-graph svg { min-width: 560px; }
  .ag-facts { grid-template-columns: minmax(0, 1fr); }
  .ag-how, .ag-conns { grid-template-columns: minmax(0, 1fr); }
  .ag-tabs-right { display: none; }
  .ag-decide { grid-template-columns: minmax(0, 1fr); }
  .ag-run-thread { height: 440px; }
  .ag-console-body { grid-template-columns: minmax(0, 1fr); }
  .ag-queue { border-right: 0; border-bottom: 1px solid var(--a-line); }
  .ag-queue li:not(.is-current) { display: none; }
}
