:root {
  color-scheme: light;
  --bg: #f4f6f8;
  --panel: #ffffff;
  --panel-2: #f8fafc;
  --line: rgba(31, 42, 61, .10);
  --line-strong: rgba(31, 42, 61, .18);
  --text: #172033;
  --muted: #667085;
  --muted-2: #8a94a6;
  --violet: #6256c7;
  --amber: #b7791f;
  --cyan: #0f7b87;
  --coral: #c8554b;
  --green: #237a57;
  --red: #c2414d;
  --sidebar: 244px;
  --radius: 18px;
  font-family: Inter, "SF Pro Display", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; background: var(--bg); color: var(--text); }
body { overflow-x: hidden; }
button, input, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration: none; }

.ambient { position: fixed; pointer-events: none; filter: blur(110px); opacity: .055; z-index: 0; }
.ambient-a { width: 420px; height: 420px; background: #7657dc; top: -180px; left: 35%; }
.ambient-b { width: 360px; height: 360px; background: #1aa8a2; right: -220px; bottom: 0; }

.app-shell { min-height: 100vh; position: relative; z-index: 1; }
.sidebar { position: fixed; inset: 0 auto 0 0; width: var(--sidebar); background: rgba(255, 255, 255, .96); border-right: 1px solid var(--line); padding: 22px 14px 18px; display: flex; flex-direction: column; backdrop-filter: blur(28px); z-index: 30; }
.brand { display: flex; align-items: center; gap: 11px; padding: 3px 9px 24px; }
.brand-mark { width: 37px; height: 37px; display: grid; place-items: center; border-radius: 11px; background: linear-gradient(135deg, #26364f, #445a78); color: #fff; font-weight: 900; letter-spacing: -.06em; box-shadow: 0 8px 24px rgba(38, 54, 79, .18); }
.brand strong, .brand small, .sidebar-foot strong, .sidebar-foot small { display: block; }
.brand strong { letter-spacing: -.02em; font-size: 15px; }
.brand small { color: var(--muted); font-size: 11px; margin-top: 2px; letter-spacing: .08em; }
.nav { overflow-y: auto; scrollbar-width: none; }
.nav-label { margin: 21px 10px 8px; color: #98a2b3; font-size: 10px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; }
.nav-item { height: 42px; padding: 0 10px; margin: 3px 0; border-radius: 10px; display: flex; align-items: center; gap: 11px; color: #566176; font-size: 13px; font-weight: 570; transition: .18s ease; }
.nav-item:hover { color: var(--text); background: #f4f6f9; }
.nav-item.active { color: #26364f; background: #edf1f6; box-shadow: inset 3px 0 0 #3f5879; }
.nav-item em { margin-left: auto; font-style: normal; color: #98a2b3; font-size: 10px; }
.nav-icon { width: 19px; height: 19px; display: grid; place-items: center; color: #7b8798; }
.nav-icon svg { width: 17px; height: 17px; }
.accent-violet { color: var(--violet); }.accent-amber { color: var(--amber); }.accent-cyan { color: var(--cyan); }.accent-coral { color: var(--coral); }.accent-green { color: var(--green); }
.sidebar-foot { margin-top: auto; padding: 16px 10px 3px; border-top: 1px solid var(--line); display: flex; align-items: center; gap: 10px; }
.sidebar-foot strong { font-size: 10px; color: #475467; letter-spacing: .1em; }
.sidebar-foot small { color: var(--muted-2); font-size: 10px; margin-top: 3px; }
.pulse-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 5px rgba(120,214,159,.09); }

.main-shell { margin-left: var(--sidebar); min-height: 100vh; }
.topbar { height: 67px; border-bottom: 1px solid var(--line); padding: 0 31px; display: flex; align-items: center; justify-content: space-between; position: sticky; top: 0; background: rgba(255,255,255,.88); backdrop-filter: blur(24px); z-index: 20; }
.breadcrumb { display: flex; align-items: center; gap: 9px; color: var(--muted-2); font-size: 12px; }
.breadcrumb b { color: #c2c8d1; font-weight: 400; }.breadcrumb strong { color: #344054; font-weight: 600; }
.top-actions { display: flex; align-items: center; gap: 9px; }
.status-chip { display: inline-flex; align-items: center; gap: 7px; border: 1px solid var(--line); border-radius: 999px; padding: 7px 11px; color: #526072; font-size: 11px; background: #fff; }
.status-chip i { width: 6px; height: 6px; border-radius: 50%; background: var(--green); }
.icon-button, .mobile-menu { width: 34px; height: 34px; display: grid; place-items: center; background: #fff; border: 1px solid var(--line); color: #667085; border-radius: 9px; cursor: pointer; }
.icon-button:hover { color: #172033; border-color: var(--line-strong); background: #f8fafc; }.icon-button svg, .mobile-menu svg { width: 15px; height: 15px; }
.mobile-menu { display: none; }
.page { padding: 34px 36px 70px; max-width: 1540px; margin: 0 auto; }
.page-loading { min-height: 64vh; display: grid; place-items: center; align-content: center; gap: 10px; color: var(--muted); }
.page-loading strong { color: #344054; font-size: 14px; }.page-loading small { color: var(--muted-2); }
.loader { width: 26px; height: 26px; border: 2px solid rgba(255,255,255,.09); border-top-color: var(--cyan); border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

.eyebrow { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 10px; font-weight: 800; letter-spacing: .15em; text-transform: uppercase; }
.eyebrow:before { content: ""; width: 22px; height: 1px; background: currentColor; opacity: .7; }
.hero { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(340px, .65fr); gap: 30px; align-items: end; margin-bottom: 36px; }
.hero h1, .page-head h1, .detail-title h1 { margin: 12px 0 11px; font-size: clamp(31px, 4vw, 53px); line-height: 1.04; letter-spacing: -.055em; font-weight: 680; }
.hero h1 span { color: #667085; }.hero-copy { color: var(--muted); line-height: 1.7; font-size: 14px; max-width: 670px; margin: 0; }
.hero-side { display: flex; justify-content: flex-end; gap: 9px; flex-wrap: wrap; }
.hero-pill { border: 1px solid var(--line); background: #fff; border-radius: 12px; padding: 12px 15px; min-width: 108px; box-shadow: 0 4px 14px rgba(31,42,61,.04); }
.hero-pill strong { display: block; font-size: 18px; letter-spacing: -.03em; }.hero-pill small { color: var(--muted-2); font-size: 10px; }

.kpi-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 13px; margin-bottom: 34px; }
.kpi { border: 1px solid var(--line); background: #fff; border-radius: 15px; padding: 20px; min-height: 121px; position: relative; overflow: hidden; box-shadow: 0 5px 18px rgba(31,42,61,.045); }
.kpi:after { content: ""; position: absolute; width: 90px; height: 90px; border-radius: 50%; filter: blur(42px); opacity: .13; right: -20px; top: -20px; background: var(--accent, white); }
.kpi-top { display: flex; align-items: center; justify-content: space-between; color: var(--muted); font-size: 11px; }.kpi-top span:last-child { color: var(--green); }
.kpi strong { display: block; margin: 15px 0 3px; font-size: 29px; letter-spacing: -.045em; }.kpi small { color: var(--muted-2); }

.section-head { display: flex; justify-content: space-between; align-items: end; gap: 20px; margin: 31px 0 15px; }
.section-head h2 { margin: 0; font-size: 17px; letter-spacing: -.025em; }.section-head p { margin: 5px 0 0; color: var(--muted); font-size: 12px; }
.text-link { color: #c8cad1; font-size: 11px; border-bottom: 1px solid #4b4f58; padding-bottom: 2px; cursor: pointer; }
.dataset-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 13px; }
.inventory-formula { min-height: 72px; margin: -12px 0 31px; padding: 13px 18px; display: flex; align-items: center; justify-content: center; gap: 18px; border: 1px solid #dce3eb; border-radius: 14px; background: #fff; box-shadow: 0 5px 18px rgba(31,42,61,.04); }
.inventory-formula > strong { color: #172033; font-size: 25px; letter-spacing: -.04em; }
.inventory-formula .formula-label { color: #667085; font-size: 10px; margin-left: -12px; }
.inventory-formula > i { color: #a2aab7; font-style: normal; font-size: 16px; }
.inventory-formula > span:not(.formula-label) { min-width: 112px; padding: 7px 11px; border-radius: 9px; background: #f6f8fa; text-align: center; }
.inventory-formula b, .inventory-formula small { display: block; }
.inventory-formula b { color: #344054; font-size: 15px; }
.inventory-formula small { margin-top: 2px; color: #7b8797; font-size: 9px; }
.catalog-note { margin: -3px 0 14px; min-height: 54px; display: flex; align-items: center; gap: 12px; padding: 10px 14px; border: 1px solid #dce5ed; border-radius: 12px; background: linear-gradient(90deg, #f7fafc, #fff); color: #475467; }
.catalog-note-icon { width: 30px; height: 30px; display: grid; place-items: center; flex: none; border-radius: 9px; background: #eaf4f6; color: var(--cyan); font-size: 15px; }
.catalog-note strong, .catalog-note small { display: block; }
.catalog-note strong { font-size: 11px; color: #344054; }
.catalog-note small { margin-top: 3px; color: #7a8495; font-size: 10px; line-height: 1.45; }
.dataset-card { --accent: var(--violet); min-height: 242px; border: 1px solid var(--line); background: var(--panel); border-radius: var(--radius); padding: 20px; cursor: pointer; position: relative; overflow: hidden; transition: .22s ease; display: flex; flex-direction: column; }
.dataset-card:hover { transform: translateY(-3px); border-color: var(--line-strong); background: #151922; }
.dataset-card:before { content: ""; position: absolute; inset: 0 0 auto 0; height: 2px; background: linear-gradient(90deg, var(--accent), transparent 72%); opacity: .8; }
.accent-card-violet { --accent: var(--violet); }.accent-card-amber { --accent: var(--amber); }.accent-card-cyan { --accent: var(--cyan); }.accent-card-coral { --accent: var(--coral); }
.dataset-card-head { display: flex; align-items: center; justify-content: space-between; }
.dataset-card-head .card-icon { width: 34px; height: 34px; border: 1px solid color-mix(in srgb, var(--accent) 25%, transparent); color: var(--accent); border-radius: 10px; display: grid; place-items: center; background: color-mix(in srgb, var(--accent) 7%, transparent); }
.card-icon svg { width: 17px; height: 17px; }.done { color: var(--green); font-size: 9px; font-weight: 800; letter-spacing: .11em; }
.dataset-card h3 { margin: 21px 0 5px; font-size: 18px; letter-spacing: -.03em; }.dataset-count { color: var(--accent); font-size: 27px; font-weight: 680; letter-spacing: -.04em; }.dataset-count small { font-size: 10px; color: var(--muted); margin-left: 4px; font-weight: 500; }
.dataset-split { display: flex; align-items: center; gap: 7px; margin-top: 4px; color: #7b8797; font-size: 9px; }
.dataset-split span { padding: 4px 7px; border: 1px solid #e5e9ef; border-radius: 7px; background: #f8fafc; }
.dataset-split b { margin-left: 3px; color: #344054; font-size: 10px; }
.dataset-split i { color: #a8b0bc; font-style: normal; }
.dataset-card p { color: var(--muted); line-height: 1.55; font-size: 12px; margin: 9px 0 20px; }
.card-foot { margin-top: auto; display: flex; align-items: center; justify-content: space-between; color: var(--muted-2); font-size: 10px; }.arrow { color: var(--accent); font-size: 18px; }

.split-grid { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(300px, .55fr); gap: 13px; }
.panel { border: 1px solid var(--line); background: var(--panel); border-radius: var(--radius); overflow: hidden; }
.panel-head { padding: 17px 19px; border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; }
.panel-head h3 { margin: 0; font-size: 13px; }.panel-head span { color: var(--muted-2); font-size: 10px; }
.activity-row { display: grid; grid-template-columns: 34px minmax(0,1fr) auto; gap: 11px; align-items: center; padding: 13px 19px; border-bottom: 1px solid var(--line); cursor: pointer; }
.activity-row:last-child { border: 0; }.activity-row:hover { background: rgba(255,255,255,.025); }
.activity-dot { width: 29px; height: 29px; border-radius: 9px; display: grid; place-items: center; background: rgba(120,214,159,.08); color: var(--green); }.activity-dot svg { width: 14px; }
.activity-row strong { display: block; font-size: 12px; font-weight: 570; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }.activity-row small { display: block; color: var(--muted-2); margin-top: 4px; font-size: 10px; }.activity-row time { color: var(--muted-2); font-size: 10px; }
.readiness { padding: 18px; }.readiness-row { margin-bottom: 18px; }.readiness-row:last-child { margin-bottom: 0; }.readiness-label { display: flex; justify-content: space-between; color: #c3c5cc; font-size: 11px; margin-bottom: 8px; }.readiness-label span:last-child { color: var(--muted-2); }.track { height: 5px; border-radius: 10px; background: #252934; overflow: hidden; }.track i { display: block; height: 100%; border-radius: 10px; background: var(--track-color, var(--green)); }

.page-head { display: flex; justify-content: space-between; gap: 28px; align-items: end; margin-bottom: 27px; }.page-head h1 { font-size: clamp(28px,3.3vw,44px); margin-bottom: 9px; }.page-head p { color: var(--muted); margin: 0; font-size: 13px; line-height: 1.6; }.page-head .count-box { text-align: right; flex: none; }.count-box strong { display:block; font-size: 34px; letter-spacing: -.05em; }.count-box small { color: var(--muted-2); }
.toolbar { display: flex; align-items: center; gap: 10px; margin-bottom: 17px; }
.search { position: relative; flex: 1; max-width: 520px; }.search svg { position: absolute; left: 13px; top: 50%; transform: translateY(-50%); width: 15px; color: var(--muted-2); }.search input, .select { width: 100%; height: 40px; border-radius: 11px; border: 1px solid var(--line); background: rgba(255,255,255,.035); color: var(--text); outline: none; }.search input { padding: 0 14px 0 38px; }.search input:focus, .select:focus { border-color: rgba(255,255,255,.22); }.select { width: auto; padding: 0 31px 0 12px; color: #bbbfc8; }
.view-caption { margin-left: auto; color: var(--muted-2); font-size: 10px; }
.record-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.record-card { border: 1px solid var(--line); background: var(--panel); border-radius: 15px; padding: 17px; cursor: pointer; transition: .18s; min-height: 175px; display: flex; flex-direction: column; }
.record-card:hover { border-color: var(--line-strong); transform: translateY(-2px); background: #151922; }.record-top { display: flex; justify-content: space-between; gap: 12px; color: var(--muted-2); font-size: 10px; }.record-card h3 { margin: 14px 0 5px; font-size: 15px; letter-spacing: -.02em; }.record-card h3 span { color: var(--muted-2); font-weight: 500; }.record-card p { color: var(--muted); font-size: 11px; line-height: 1.55; margin: 9px 0 15px; }.tag-row { display: flex; flex-wrap: wrap; gap: 5px; }.tag { display: inline-flex; align-items: center; min-height: 22px; padding: 4px 7px; border-radius: 6px; background: rgba(255,255,255,.045); border: 1px solid rgba(255,255,255,.045); color: #aeb2bc; font-size: 9px; }.tag.violet { color: var(--violet); background: rgba(167,139,250,.07); }.tag.amber { color: var(--amber); background: rgba(245,185,76,.07); }.tag.cyan { color: var(--cyan); background: rgba(85,215,222,.07); }.tag.coral { color: var(--coral); background: rgba(255,128,108,.07); }.tag.green { color: var(--green); background: rgba(120,214,159,.07); }
.record-card .tag-row { margin-top: auto; }.pager { display: flex; align-items: center; justify-content: center; gap: 10px; margin-top: 22px; }.pager button { background: rgba(255,255,255,.035); color: #b8bbc4; border: 1px solid var(--line); border-radius: 9px; height: 34px; padding: 0 12px; cursor: pointer; }.pager button:disabled { opacity: .35; cursor: default; }.pager span { color: var(--muted-2); font-size: 10px; }

.detail-back { display: inline-flex; align-items: center; gap: 7px; color: var(--muted); font-size: 11px; margin-bottom: 20px; cursor: pointer; }.detail-back:hover { color: #fff; }.detail-title { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 30px; align-items: end; padding-bottom: 24px; border-bottom: 1px solid var(--line); }.detail-title h1 { font-size: clamp(27px,3.5vw,45px); }.detail-title p { color: var(--muted); max-width: 800px; line-height: 1.65; margin: 0; }.detail-meta { text-align: right; }.detail-meta strong { display:block; font-size: 26px; }.detail-meta small { color: var(--muted-2); }
.metric-row { display: grid; grid-template-columns: repeat(4,1fr); gap: 9px; margin: 18px 0 26px; }.metric { border: 1px solid var(--line); background: rgba(255,255,255,.02); border-radius: 12px; padding: 13px 14px; }.metric small { display:block; color: var(--muted-2); font-size: 9px; letter-spacing: .08em; text-transform: uppercase; }.metric strong { display:block; margin-top: 6px; font-size: 16px; font-weight: 620; }
.detail-layout { display: grid; grid-template-columns: minmax(0, 1.65fr) minmax(280px, .55fr); gap: 14px; align-items: start; }.detail-main, .detail-side { min-width: 0; }.content-card { border: 1px solid var(--line); background: var(--panel); border-radius: 15px; padding: 19px; margin-bottom: 13px; }.content-card h2 { font-size: 14px; margin: 0 0 15px; }.content-card h3 { font-size: 12px; margin: 18px 0 9px; color: #d7d8dd; }.content-card p { color: #b7bac3; line-height: 1.75; font-size: 12px; }.content-card pre { white-space: pre-wrap; word-break: break-word; color: #b9bdc7; font: 11px/1.7 ui-monospace, SFMono-Regular, Consolas, monospace; margin: 0; max-height: 520px; overflow: auto; }.sticky { position: sticky; top: 83px; }
.timeline { position: relative; margin-left: 7px; }.timeline:before { content:""; position:absolute; left: 5px; top: 6px; bottom: 7px; width:1px; background: #303540; }.timeline-item { position:relative; padding: 0 0 17px 25px; }.timeline-item:before { content:""; position:absolute; left:0; top:5px; width:11px; height:11px; border-radius:50%; background: var(--panel); border:2px solid var(--violet); box-sizing:border-box; }.timeline-item time { color:var(--muted-2); font-size:9px; }.timeline-item strong { display:block; font-size:11px; margin:4px 0; }.timeline-item p { margin:0; font-size:10px; line-height:1.55; color:var(--muted); }
.edge { display:grid; grid-template-columns:minmax(0,1fr) 20px minmax(0,1fr); gap:8px; align-items:center; border-top:1px solid var(--line); padding:11px 0; font-size:10px; color:#bcc0c9; }.edge:first-of-type { border-top:0; }.edge b { text-align:center; color:var(--violet); }.edge small { display:block; color:var(--muted-2); margin-top:3px; }
.message-block { border-left: 2px solid var(--line-strong); padding-left: 15px; margin-bottom: 18px; }.message-block.system { border-color: var(--violet); }.message-block.user { border-color: var(--cyan); }.message-block.assistant { border-color: var(--green); }.message-role { font-size:9px; letter-spacing:.12em; text-transform:uppercase; color:var(--muted-2); margin-bottom:7px; }.message-text { white-space:pre-wrap; word-break:break-word; color:#b7bac3; font-size:11px; line-height:1.72; max-height:620px; overflow:auto; }
.citation-cloud { display:flex; flex-wrap:wrap; gap:6px; }.citation { font:9px ui-monospace,monospace; padding:6px 8px; border:1px solid rgba(85,215,222,.15); background:rgba(85,215,222,.045); color:var(--cyan); border-radius:7px; }
.kv { display:grid; grid-template-columns:110px minmax(0,1fr); gap:8px 12px; padding:9px 0; border-bottom:1px solid var(--line); font-size:10px; }.kv:last-child { border:0; }.kv span:first-child { color:var(--muted-2); }.kv span:last-child { color:#c5c7ce; word-break:break-word; }
details.raw { border:1px solid var(--line); border-radius:12px; overflow:hidden; margin-top:12px; } details.raw summary { padding:12px 14px; cursor:pointer; color:var(--muted); font-size:10px; } details.raw pre { border-top:1px solid var(--line); padding:14px; background:#0d1016; }

.skill-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:13px; }.skill-card { --accent:var(--violet); border:1px solid var(--line); border-radius:17px; background:var(--panel); padding:22px; cursor:pointer; transition:.2s; min-height:250px; }.skill-card:hover { transform:translateY(-2px); border-color:var(--line-strong); }.skill-no { color:var(--accent); font:700 10px ui-monospace,monospace; }.skill-card h2 { font-size:20px; margin:21px 0 5px; letter-spacing:-.03em; }.skill-name { color:var(--muted-2); font:10px ui-monospace,monospace; }.skill-card p { color:var(--muted); font-size:11px; line-height:1.65; margin:15px 0; }.skill-sections { display:flex; flex-wrap:wrap; gap:5px; }.skill-reader { display:grid; grid-template-columns:230px minmax(0,1fr); gap:25px; align-items:start; }.skill-toc { position:sticky; top:87px; border:1px solid var(--line); border-radius:14px; background:var(--panel); padding:15px; }.skill-toc strong { font-size:10px; color:var(--muted-2); letter-spacing:.1em; }.skill-toc a { display:block; color:#9da1ac; font-size:10px; padding:7px 2px; }.skill-toc a:hover { color:#fff; }.markdown { border:1px solid var(--line); border-radius:17px; background:var(--panel); padding:clamp(22px,4vw,48px); }.markdown h1 { font-size:30px; letter-spacing:-.04em; margin:0 0 26px; }.markdown h2 { font-size:19px; margin:38px 0 14px; border-top:1px solid var(--line); padding-top:28px; }.markdown h3 { font-size:14px; margin:25px 0 10px; }.markdown p,.markdown li { color:#b9bcc5; font-size:12px; line-height:1.8; }.markdown code { background:rgba(255,255,255,.06); padding:2px 5px; border-radius:5px; font:11px ui-monospace,monospace; }.markdown pre { background:#0b0d12; border:1px solid var(--line); border-radius:11px; padding:15px; overflow:auto; }.markdown blockquote { border-left:2px solid var(--cyan); margin:15px 0; padding:1px 0 1px 15px; }.markdown table { width:100%; border-collapse:collapse; margin:16px 0; font-size:11px; }.markdown th,.markdown td { border-bottom:1px solid var(--line); text-align:left; padding:9px; color:#b8bbc4; }.markdown th { color:#e5e5e2; }

.trace-table { border:1px solid var(--line); border-radius:15px; overflow:hidden; background:var(--panel); }.trace-head,.trace-row { display:grid; grid-template-columns:minmax(260px,2fr) 150px 95px 80px 95px 26px; gap:10px; align-items:center; padding:0 16px; }.trace-head { height:38px; color:var(--muted-2); font-size:9px; text-transform:uppercase; letter-spacing:.08em; border-bottom:1px solid var(--line); }.trace-row { min-height:57px; border-bottom:1px solid var(--line); cursor:pointer; font-size:10px; }.trace-row:last-child { border:0; }.trace-row:hover { background:rgba(255,255,255,.025); }.trace-title strong { display:block; font-size:11px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }.trace-title small { display:block; margin-top:5px; color:var(--muted-2); font:9px ui-monospace,monospace; }.trace-row > span { color:#aeb1ba; }.trace-types { display:flex; gap:4px; }.trace-types i { font-style:normal; font-size:8px; padding:3px 5px; border-radius:5px; background:rgba(167,139,250,.08); color:var(--violet); }.trace-ok { color:var(--green)!important; }.trace-arrow { color:var(--muted-2)!important; font-size:15px; }
.trace-workspace { display:grid; grid-template-columns:minmax(420px,1.25fr) minmax(300px,.75fr); gap:13px; align-items:start; }.trace-tree-panel,.obs-panel { border:1px solid var(--line); border-radius:15px; background:var(--panel); overflow:hidden; }.trace-tree-panel header,.obs-panel header { padding:14px 17px; border-bottom:1px solid var(--line); display:flex; justify-content:space-between; align-items:center; }.trace-tree-panel header strong,.obs-panel header strong { font-size:11px; }.trace-tree-panel header span,.obs-panel header span { color:var(--muted-2); font-size:9px; }.trace-tree { padding:10px; }.trace-node { display:grid; grid-template-columns:18px minmax(150px,1fr) minmax(90px,.7fr) 57px; gap:8px; align-items:center; height:38px; border-radius:8px; padding:0 8px; cursor:pointer; position:relative; }.trace-node:hover,.trace-node.active { background:rgba(255,255,255,.05); }.trace-node .depth-line { position:absolute; left:calc(10px + var(--depth)*18px); top:0; bottom:0; border-left:1px solid #2e333d; }.trace-node-icon { margin-left:calc(var(--depth)*18px); width:16px; height:16px; border-radius:5px; display:grid; place-items:center; background:rgba(255,255,255,.05); color:var(--muted); z-index:1; }.trace-node-icon svg { width:10px; }.trace-node-name { min-width:0; }.trace-node-name strong { display:block; font-size:10px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }.trace-node-name small { color:var(--muted-2); font-size:8px; }.waterfall { height:6px; background:#242933; border-radius:5px; position:relative; overflow:hidden; }.waterfall i { position:absolute; height:100%; border-radius:5px; background:var(--node-color,var(--violet)); min-width:3px; }.duration { color:var(--muted-2); font:8px ui-monospace,monospace; text-align:right; }.obs-panel { position:sticky; top:83px; }.obs-body { padding:17px; max-height:72vh; overflow:auto; }.obs-id { color:var(--muted-2); font:9px ui-monospace,monospace; word-break:break-all; }.payload-block { margin-top:15px; }.payload-block h4 { margin:0 0 7px; color:var(--muted-2); font-size:9px; letter-spacing:.1em; }.payload { margin:0; white-space:pre-wrap; word-break:break-word; font:9px/1.65 ui-monospace,monospace; color:#b8bbc4; background:#0d1016; border:1px solid var(--line); border-radius:9px; padding:11px; max-height:300px; overflow:auto; }
.empty { min-height:340px; border:1px dashed var(--line-strong); border-radius:16px; display:grid; place-items:center; align-content:center; color:var(--muted); gap:8px; }.empty strong { color:#d6d7dc; }.toast { position:fixed; right:22px; bottom:22px; background:#e8e7e2; color:#16181e; border-radius:10px; padding:10px 14px; font-size:11px; transform:translateY(20px); opacity:0; pointer-events:none; transition:.2s; z-index:60; }.toast.show { transform:none; opacity:1; }

@media (max-width: 1160px) {
  .dataset-grid { grid-template-columns:repeat(2,1fr); }.record-grid { grid-template-columns:repeat(2,1fr); }.kpi-grid { grid-template-columns:repeat(2,1fr); }.hero { grid-template-columns:1fr; }.hero-side { justify-content:flex-start; }.detail-layout { grid-template-columns:1fr; }.sticky,.obs-panel { position:static; }.trace-workspace { grid-template-columns:1fr; }
}
@media (max-width: 780px) {
  .sidebar { transform:translateX(-105%); transition:.22s; box-shadow:20px 0 60px rgba(0,0,0,.4); }.sidebar.open { transform:none; }.sidebar-backdrop { position:fixed; inset:0; background:rgba(0,0,0,.45); z-index:25; opacity:0; pointer-events:none; transition:.2s; }.sidebar-backdrop.show { opacity:1; pointer-events:auto; }.main-shell { margin-left:0; }.topbar { padding:0 16px; }.mobile-menu { display:grid; }.breadcrumb span,.breadcrumb b { display:none; }.page { padding:25px 16px 55px; }.hero h1 { font-size:36px; }.dataset-grid,.record-grid,.skill-grid,.kpi-grid { grid-template-columns:1fr; }.split-grid { grid-template-columns:1fr; }.metric-row { grid-template-columns:repeat(2,1fr); }.page-head,.detail-title { grid-template-columns:1fr; display:grid; }.count-box,.detail-meta { text-align:left!important; }.skill-reader { grid-template-columns:1fr; }.skill-toc { position:static; }.trace-head { display:none; }.trace-row { grid-template-columns:1fr auto; padding:12px 14px; }.trace-row > span:not(.trace-arrow),.trace-types { display:none; }.trace-workspace { display:block; }.obs-panel { margin-top:12px; }.trace-node { grid-template-columns:18px minmax(100px,1fr) 70px 45px; }.status-chip { display:none; }
}

/* Professional light-surface refinements */
.dataset-card,
.panel,
.record-card,
.content-card,
.skill-card,
.skill-toc,
.markdown,
.trace-table,
.trace-tree-panel,
.obs-panel {
  box-shadow: 0 5px 20px rgba(31, 42, 61, .045);
}

.dataset-card:hover,
.record-card:hover {
  background: #f9fafc;
  box-shadow: 0 9px 28px rgba(31, 42, 61, .08);
}

.dataset-card-head .card-icon {
  background: color-mix(in srgb, var(--accent) 8%, white);
}

.activity-row:hover,
.trace-row:hover,
.trace-node:hover,
.trace-node.active {
  background: #f5f7fa;
}

.activity-dot {
  background: #edf8f3;
}

.track,
.waterfall {
  background: #e9edf2;
}

.readiness-label,
.record-card h3,
.content-card h3,
.trace-title strong,
.trace-node-name strong {
  color: #344054;
}

.text-link {
  color: #475467;
  border-color: #b7c0cc;
}

.search input,
.select {
  background: #fff;
  color: #344054;
  box-shadow: 0 1px 2px rgba(31, 42, 61, .025);
}

.search input::placeholder {
  color: #98a2b3;
}

.search input:focus,
.select:focus {
  border-color: #8293a8;
  box-shadow: 0 0 0 3px rgba(63, 88, 121, .08);
}

.tag {
  background: #f4f6f8;
  border-color: #e8ebf0;
  color: #5d687a;
}

.tag.violet { background: #f1effb; }
.tag.amber { background: #fbf4e8; }
.tag.cyan { background: #eaf6f7; }
.tag.coral { background: #fbefed; }
.tag.green { background: #edf7f2; }

.pager button {
  background: #fff;
  color: #475467;
  box-shadow: 0 1px 3px rgba(31, 42, 61, .04);
}

.pager button:not(:disabled):hover {
  background: #f7f9fb;
  border-color: var(--line-strong);
}

.metric {
  background: #fff;
  box-shadow: 0 3px 12px rgba(31, 42, 61, .035);
}

.content-card p,
.message-text,
.markdown p,
.markdown li,
.markdown td,
.content-card pre,
.payload,
.edge {
  color: #475467;
}

.timeline:before,
.trace-node .depth-line {
  background: #dfe4ea;
  border-color: #dfe4ea;
}

.timeline-item:before {
  background: #fff;
}

.citation {
  border-color: rgba(15, 123, 135, .18);
  background: #edf8f8;
}

.kv span:last-child,
.skill-toc a,
.trace-row > span {
  color: #526072;
}

details.raw {
  background: #fbfcfd;
}

details.raw pre,
.markdown pre,
.payload {
  background: #f6f8fa;
  color: #344054;
}

.markdown code {
  background: #eef1f5;
  color: #344054;
}

.markdown code.doc-ref {
  padding: 3px 6px;
  border: 1px solid #dfe5ec;
  background: #f6f8fa;
  color: #52647b;
  font-family: inherit;
  font-size: 10px;
}

.markdown th {
  color: #27364d;
  background: #f7f9fb;
}

.markdown a {
  color: #35617f;
  text-decoration: underline;
  text-decoration-color: #b8c8d4;
  text-underline-offset: 3px;
}

.trace-types i {
  background: #f1effb;
}

.trace-node-icon {
  background: #eef1f5;
  color: #667085;
}

.obs-panel,
.trace-tree-panel {
  background: #fff;
}

.obs-id {
  color: #7b8797;
}

.empty {
  background: rgba(255, 255, 255, .55);
}

.empty strong {
  color: #344054;
}

.toast {
  background: #27364d;
  color: #fff;
  box-shadow: 0 10px 30px rgba(31, 42, 61, .20);
}

@media (max-width: 780px) {
  .sidebar {
    box-shadow: 20px 0 60px rgba(31, 42, 61, .16);
  }
  .sidebar-backdrop {
    background: rgba(31, 42, 61, .28);
  }
}

/* Refined overview hierarchy */
.hero-refined {
  margin-bottom: 24px;
}

.hero-refined h1 {
  max-width: 720px;
}

.inventory-board {
  display: grid;
  grid-template-columns: minmax(330px, .82fr) minmax(480px, 1.18fr);
  border: 1px solid #dce3eb;
  border-radius: 20px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 15px 45px rgba(31, 42, 61, .075);
  margin-bottom: 38px;
}

.inventory-primary {
  min-height: 285px;
  padding: 28px 31px;
  color: #fff;
  background:
    radial-gradient(circle at 92% 8%, rgba(124, 152, 190, .34), transparent 34%),
    linear-gradient(145deg, #213149, #314764);
}

.board-eyebrow {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: center;
  color: #dbe6f1;
  font-size: 11px;
  font-weight: 700;
}

.board-eyebrow em {
  padding: 5px 8px;
  border: 1px solid rgba(255,255,255,.18);
  border-radius: 999px;
  color: #a9d7bd;
  font-style: normal;
  font-size: 8px;
  letter-spacing: .08em;
}

.grand-total {
  margin-top: 25px;
  font-size: clamp(54px, 6vw, 76px);
  line-height: .95;
  font-weight: 750;
  letter-spacing: -.065em;
  text-shadow: 0 6px 20px rgba(0,0,0,.12);
}

.grand-total small {
  margin-left: 7px;
  color: #c7d3e1;
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 0;
}

.inventory-primary > p {
  margin: 13px 0 24px;
  color: #b9c8d9;
  font-size: 11px;
}

.grand-equation {
  display: flex;
  align-items: center;
  gap: 9px;
  padding-top: 17px;
  border-top: 1px solid rgba(255,255,255,.15);
  color: #c7d2df;
  font-size: 10px;
}

.grand-equation span,
.grand-equation strong {
  padding: 6px 8px;
  border-radius: 7px;
  background: rgba(255,255,255,.08);
}

.grand-equation b,
.grand-equation strong {
  color: #fff;
  font-size: 12px;
}

.grand-equation i {
  color: #93a6bb;
  font-style: normal;
}

.inventory-breakdowns {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0;
}

.asset-breakdown {
  min-width: 0;
  padding: 28px 25px;
  border-left: 1px solid #e5e9ef;
}

.asset-breakdown + .asset-breakdown {
  background: #fbfcfd;
}

.asset-breakdown header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.asset-breakdown header > span {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #344054;
  font-size: 12px;
  font-weight: 700;
}

.asset-breakdown header span i {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: #edf6f7;
  color: var(--cyan);
}

.asset-breakdown.traces header span i {
  background: #edf7f2;
  color: var(--green);
}

.asset-breakdown header svg {
  width: 14px;
  height: 14px;
}

.asset-breakdown header > strong {
  color: #172033;
  font-size: 31px;
  line-height: 1;
  letter-spacing: -.05em;
}

.asset-breakdown > p {
  min-height: 38px;
  margin: 22px 0 20px;
  color: #7b8797;
  font-size: 10px;
  line-height: 1.6;
}

.asset-meter {
  height: 8px;
  display: flex;
  gap: 3px;
  border-radius: 999px;
  overflow: hidden;
  background: #edf0f4;
}

.asset-meter i {
  min-width: 3px;
  background: var(--cyan);
}

.asset-meter i + i {
  background: #b9dbe0;
}

.asset-breakdown.traces .asset-meter i {
  background: var(--green);
}

.asset-breakdown.traces .asset-meter i + i {
  background: #b8dcca;
}

.asset-breakdown footer {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 12px;
  color: #7b8797;
  font-size: 9px;
}

.asset-breakdown footer b {
  color: #344054;
  font-size: 12px;
}

.inventory-board-foot {
  grid-column: 1 / -1;
  min-height: 51px;
  padding: 0 22px;
  display: flex;
  align-items: center;
  gap: 25px;
  border-top: 1px solid #e5e9ef;
  background: #f8fafc;
  color: #667085;
  font-size: 9px;
}

.inventory-board-foot b {
  margin-right: 3px;
  color: #344054;
  font-size: 11px;
}

.inventory-board-foot .verified-mark {
  margin-left: auto;
  color: var(--green);
  font-weight: 650;
}

.section-kicker {
  margin-bottom: 6px;
  color: #8a94a6;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .14em;
}

.section-head-strong h2 {
  font-size: 21px;
}

.section-head-strong p b {
  color: #344054;
}

.dataset-card-v2 {
  min-height: 286px;
}

.dataset-card-v2 h3 {
  margin-top: 17px;
}

.dataset-total-row {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 14px;
  margin-top: 8px;
}

.coverage {
  margin-bottom: 3px;
  color: #7b8797;
  font-size: 9px;
}

.dataset-meter {
  height: 5px;
  margin: 10px 0 9px;
  overflow: hidden;
  border-radius: 999px;
  background: #e9edf2;
}

.dataset-meter i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--accent);
}

.dataset-split-v2 {
  justify-content: stretch;
  margin-top: 0;
}

.dataset-split-v2 > span {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 7px 8px;
}

.dataset-split-v2 small {
  color: #8a94a6;
  font-size: 8px;
}

.dataset-split-v2 b {
  font-size: 11px;
}

/* Refined SKILL operating-system view */
.skill-page-head h1 span {
  color: #657187;
}

.skill-page-head .count-box strong {
  color: #25364f;
  font-size: 30px;
}

.skill-foundation {
  min-height: 80px;
  display: grid;
  grid-template-columns: 210px minmax(0,1fr) auto;
  gap: 22px;
  align-items: center;
  padding: 14px 18px;
  border: 1px solid #dce3eb;
  border-radius: 15px;
  background: #fff;
  box-shadow: 0 6px 22px rgba(31,42,61,.045);
}

.foundation-title {
  display: flex;
  align-items: center;
  gap: 11px;
}

.foundation-mark {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: #263a57;
  color: #fff;
  font-size: 10px;
  font-weight: 800;
}

.foundation-title strong,
.foundation-title small {
  display: block;
}

.foundation-title strong {
  color: #2c394d;
  font-size: 12px;
}

.foundation-title small {
  margin-top: 3px;
  color: #98a2b3;
  font-size: 8px;
  letter-spacing: .08em;
}

.foundation-rules {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.foundation-rules span {
  padding: 7px 9px;
  border-radius: 8px;
  background: #f4f6f9;
  color: #5f6b7e;
  font-size: 9px;
}

.foundation-status {
  color: var(--green);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .08em;
}

.capability-ribbon {
  display: grid;
  grid-template-columns: repeat(4, minmax(0,1fr));
  gap: 10px;
  margin: 12px 0 32px;
}

.capability-ribbon article {
  min-width: 0;
  display: grid;
  grid-template-columns: 20px 27px minmax(0,1fr) 14px;
  gap: 8px;
  align-items: center;
  padding: 12px;
  border: 1px solid #e0e5eb;
  border-radius: 12px;
  background: rgba(255,255,255,.72);
  cursor: pointer;
  transition: .18s ease;
}

.capability-ribbon article:hover {
  transform: translateY(-2px);
  border-color: #cdd5df;
  background: #fff;
}

.capability-ribbon article > span {
  color: #98a2b3;
  font: 700 9px ui-monospace,monospace;
}

.capability-ribbon article > i {
  width: 27px;
  height: 27px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: #f0f3f7;
  color: #536985;
}

.capability-ribbon svg {
  width: 14px;
  height: 14px;
}

.capability-ribbon strong,
.capability-ribbon small {
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.capability-ribbon strong {
  color: #344054;
  font-size: 10px;
}

.capability-ribbon small {
  margin-top: 3px;
  color: #8a94a6;
  font-size: 8px;
}

.capability-ribbon article > b {
  color: #9ba5b3;
  font-size: 12px;
}

.method-count {
  color: #667085;
  font-size: 10px;
}

.skill-grid-v2 {
  gap: 14px;
}

.skill-card-v2 {
  min-height: 360px;
  position: relative;
  overflow: hidden;
  padding: 22px;
}

.skill-card-v2:before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 3px;
  background: var(--accent);
}

.skill-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.skill-index {
  color: var(--accent);
  font: 750 12px ui-monospace,monospace;
}

.skill-icon-large {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  margin-top: 22px;
  border-radius: 12px;
  color: var(--accent);
  background: color-mix(in srgb, var(--accent) 9%, white);
}

.skill-icon-large svg {
  width: 20px;
  height: 20px;
}

.skill-kicker {
  margin-top: 17px;
  color: #8a94a6;
  font-size: 8px;
  font-weight: 800;
  letter-spacing: .12em;
}

.skill-card-v2 h2 {
  margin: 6px 0 5px;
  font-size: 19px;
}

.skill-card-v2 > p {
  min-height: 52px;
  margin: 15px 0 13px;
  color: #667085;
  line-height: 1.65;
}

.skill-capabilities {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.skill-capabilities span {
  padding: 5px 7px;
  border: 1px solid #e5e9ef;
  border-radius: 7px;
  background: #f7f9fb;
  color: #5f6b7e;
  font-size: 9px;
}

.skill-card-v2 footer {
  min-height: 61px;
  display: grid;
  grid-template-columns: 100px minmax(0,1fr) auto;
  gap: 14px;
  align-items: end;
  margin-top: 20px;
  padding-top: 14px;
  border-top: 1px solid #e8ebf0;
}

.skill-card-v2 footer small,
.skill-card-v2 footer strong {
  display: block;
}

.skill-card-v2 footer small {
  color: #98a2b3;
  font-size: 8px;
}

.skill-card-v2 footer strong {
  margin-top: 4px;
  color: #344054;
  font-size: 10px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.skill-card-v2 footer > b {
  color: var(--accent);
  font-size: 9px;
}

.skill-detail-index {
  display: block;
  margin-bottom: 8px;
  color: #263a57;
  font: 750 35px ui-monospace,monospace;
}

.skill-detail-banner {
  display: grid;
  grid-template-columns: 170px 230px minmax(0,1fr);
  gap: 0;
  margin: 18px 0 0;
  border: 1px solid #dfe4ea;
  border-radius: 13px;
  background: #fff;
  overflow: hidden;
}

.skill-detail-banner > div {
  padding: 14px 17px;
  border-right: 1px solid #e6eaf0;
}

.skill-detail-banner > div:last-child {
  border: 0;
}

.skill-detail-banner small,
.skill-detail-banner strong {
  display: block;
}

.skill-detail-banner small {
  color: #98a2b3;
  font-size: 8px;
}

.skill-detail-banner strong {
  margin-top: 5px;
  color: #344054;
  font-size: 12px;
}

.skill-detail-banner span {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 5px;
}

.skill-detail-banner b {
  padding: 4px 6px;
  border-radius: 6px;
  background: #f1f4f7;
  color: #566176;
  font-size: 8px;
}

.toc-head {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 10px;
  padding-bottom: 11px;
  border-bottom: 1px solid #e5e9ef;
}

.toc-head > span {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: #263a57;
  color: #fff;
  font: 700 9px ui-monospace,monospace;
}

.toc-head strong,
.toc-head small {
  display: block;
}

.toc-head small {
  margin-top: 3px;
  color: #98a2b3;
  font-size: 8px;
}

.skill-toc .toc-head + a,
.skill-toc a {
  display: flex;
  gap: 7px;
  align-items: flex-start;
}

.skill-toc a > span {
  flex: none;
  color: #a0a8b5;
  font: 700 8px ui-monospace,monospace;
}

@media (max-width: 1160px) {
  .inventory-board {
    grid-template-columns: 1fr;
  }
  .inventory-primary {
    min-height: 250px;
  }
  .asset-breakdown:first-child {
    border-left: 0;
  }
  .capability-ribbon {
    grid-template-columns: repeat(2,1fr);
  }
}

@media (max-width: 780px) {
  .inventory-breakdowns {
    grid-template-columns: 1fr;
  }
  .asset-breakdown {
    border-top: 1px solid #e5e9ef;
    border-left: 0;
  }
  .inventory-board-foot {
    flex-wrap: wrap;
    gap: 9px 17px;
    padding: 12px 16px;
  }
  .inventory-board-foot .verified-mark {
    margin-left: 0;
    width: 100%;
  }
  .grand-equation {
    flex-wrap: wrap;
  }
  .skill-foundation {
    grid-template-columns: 1fr;
  }
  .capability-ribbon {
    grid-template-columns: 1fr;
  }
  .skill-detail-banner {
    grid-template-columns: 1fr;
  }
  .skill-detail-banner > div {
    border-right: 0;
    border-bottom: 1px solid #e6eaf0;
  }
  .skill-card-v2 footer {
    grid-template-columns: 1fr 1fr;
  }
  .skill-card-v2 footer > b {
    grid-column: 1 / -1;
  }
}

/* Trace execution tree + route graph */
.trace-workspace-v2 {
  grid-template-columns: minmax(520px, 1.45fr) minmax(310px, .55fr);
}

.trace-explorer {
  display: grid;
  gap: 13px;
  min-width: 0;
}

.execution-panel {
  overflow: hidden;
}

.execution-tree {
  max-height: 620px;
  overflow: auto;
  padding: 8px 10px 14px;
  scrollbar-width: thin;
  scrollbar-color: #b9c2cf transparent;
}

.exec-node {
  position: relative;
}

.exec-row {
  position: relative;
  min-height: 47px;
  display: grid;
  grid-template-columns: 27px minmax(0, 1fr) 28px;
  align-items: center;
  gap: 8px;
  padding: 5px 6px;
  border-radius: 8px;
  cursor: pointer;
  transition: background .15s ease;
}

.exec-row:hover,
.exec-row.active {
  background: #f0f4f8;
}

.exec-children {
  position: relative;
  margin-left: 18px;
  padding-left: 20px;
  border-left: 1px solid #cbd3de;
}

.exec-children > .exec-node > .exec-row:before {
  content: "";
  position: absolute;
  left: -20px;
  top: 23px;
  width: 16px;
  border-top: 1px solid #cbd3de;
}

.exec-node.collapsed > .exec-children {
  display: none;
}

.exec-icon {
  width: 25px;
  height: 25px;
  display: grid;
  place-items: center;
  border-radius: 7px;
  font-size: 14px;
  font-weight: 700;
  background: #f5f7fa;
  color: #6b7586;
}

.exec-copy {
  min-width: 0;
}

.exec-copy strong {
  display: block;
  color: #29364a;
  font-size: 12px;
  line-height: 1.25;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.exec-copy small {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: 3px;
  color: #98a2b3;
  font-size: 10px;
}

.exec-copy small b {
  color: #667085;
  font-weight: 600;
}

.exec-toggle,
.graph-collapse {
  border: 0;
  background: transparent;
  color: #475467;
  font-size: 17px;
  cursor: pointer;
}

.kind-agent { color: #8b3fd6; background: #f5ecfd; }
.kind-chain,
.kind-handoff { color: #d72f81; background: #fcecf4; }
.kind-generation { color: #e15f9e; background: #fdf0f6; }
.kind-span { color: #667085; background: #f1f3f6; }
.kind-tool { color: #e56314; background: #fff1e8; }
.kind-output,
.kind-turn { color: #72ad27; background: #f1f8e8; }
.kind-start { color: #159447; background: #e9f8ef; }

.exec-row[data-exec-id] .kind-agent + .exec-copy small b { color: #8b3fd6; }
.exec-row[data-exec-id] .kind-chain + .exec-copy small b { color: #d72f81; }
.exec-row[data-exec-id] .kind-generation + .exec-copy small b { color: #d95595; }
.exec-row[data-exec-id] .kind-tool + .exec-copy small b { color: #d65c12; }

.trace-graph-panel {
  border: 1px solid var(--line);
  border-radius: 15px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 5px 20px rgba(31, 42, 61, .045);
}

.graph-header {
  height: 42px;
  padding: 0 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
}

.graph-header strong {
  font-size: 11px;
}

.graph-toolbar {
  min-height: 48px;
  padding: 7px 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid var(--line);
}

.graph-segment {
  display: inline-flex;
  padding: 2px;
  border: 1px solid #dfe4ea;
  background: #f7f9fb;
  border-radius: 9px;
}

.graph-segment button,
.graph-controls button {
  height: 30px;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: #667085;
  font-size: 10px;
  font-weight: 600;
  cursor: pointer;
}

.graph-segment button {
  padding: 0 10px;
}

.graph-segment button.active {
  color: #fff;
  background: #26364f;
  box-shadow: 0 2px 6px rgba(31, 42, 61, .16);
}

.graph-controls {
  display: flex;
  gap: 5px;
}

.graph-controls button {
  width: 31px;
  border: 1px solid #dfe4ea;
  background: #fff;
  color: #344054;
  font-size: 16px;
}

.graph-controls button:hover {
  background: #f4f6f8;
}

.graph-canvas {
  max-height: 570px;
  min-height: 340px;
  overflow: auto;
  background-color: #fbfcfd;
  background-image: radial-gradient(#d9dee6 .7px, transparent .7px);
  background-size: 18px 18px;
  text-align: center;
}

.route-graph-svg {
  display: block;
  margin: 0 auto;
  transition: width .16s ease, height .16s ease;
}

.graph-edges path {
  fill: none;
  stroke: #bfc8d4;
  stroke-width: 1.5;
}

.graph-node {
  cursor: pointer;
}

.graph-node text {
  font: 600 10px Inter, "PingFang SC", "Microsoft YaHei", sans-serif;
  pointer-events: none;
}

.graph-node:hover rect,
.graph-node.active rect {
  filter: drop-shadow(0 3px 5px rgba(31, 42, 61, .16));
  stroke-width: 3;
}

.trace-graph-panel.collapsed .graph-toolbar,
.trace-graph-panel.collapsed .graph-canvas {
  display: none;
}

@media (max-width: 1160px) {
  .trace-workspace-v2 {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 780px) {
  .execution-tree {
    max-height: 520px;
  }
  .exec-children {
    margin-left: 13px;
    padding-left: 14px;
  }
  .exec-children > .exec-node > .exec-row:before {
    left: -14px;
    width: 11px;
  }
  .graph-toolbar {
    align-items: flex-start;
  }
  .graph-canvas {
    min-height: 300px;
  }
  .inventory-formula {
    padding: 14px;
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 9px;
  }
  .inventory-formula .formula-label {
    margin-left: -5px;
  }
.inventory-formula > span:not(.formula-label) {
    min-width: 95px;
  }
}

/* Rich Markdown and lightweight LaTeX rendering */
.markdown { min-width: 0; max-width: 100%; }
.markdown > p { margin: 11px 0; }
.markdown a { overflow-wrap: anywhere; }
.markdown ul, .markdown ol { margin: 10px 0 16px; padding-left: 23px; }
.markdown li { margin: 5px 0; padding-left: 3px; }
.markdown li::marker { color: #728198; font-weight: 700; }
.markdown hr { height: 1px; margin: 28px 0; border: 0; background: linear-gradient(90deg, #d9dfe7, transparent); }
.markdown blockquote { border-left-width: 3px; border-radius: 0 9px 9px 0; background: #f4f8f9; padding: 7px 14px; }
.markdown blockquote p { margin: 4px 0; }
.table-wrap { width: 100%; overflow-x: auto; margin: 16px 0; border: 1px solid #e2e7ed; border-radius: 10px; }
.table-wrap table { margin: 0; }

.math-block {
  position: relative;
  margin: 20px 0 24px;
  padding: 22px 24px;
  overflow-x: auto;
  border: 1px solid #dce4ec;
  border-left: 4px solid #536f91;
  border-radius: 11px;
  background: linear-gradient(100deg, #f5f8fb, #fbfcfd);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.8);
}

.math-block:before {
  content: "RELATION";
  position: absolute;
  top: 7px;
  right: 10px;
  color: #a1aab7;
  font: 700 7px ui-monospace,monospace;
  letter-spacing: .12em;
}

.math-expression {
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  color: #26364d;
  font-family: "Cambria Math", "STIX Two Math", "Times New Roman", "Songti SC", serif;
  font-size: 17px;
  line-height: 1.65;
}

.math-term {
  padding: 2px 4px;
  font-weight: 550;
  white-space: nowrap;
}

.math-operator {
  min-width: 26px;
  color: #3f6489;
  font-family: "Cambria Math", "Times New Roman", serif;
  font-size: 22px;
  font-weight: 700;
  text-align: center;
}

@media (max-width: 780px) {
  .math-block {
    padding: 22px 14px 17px;
  }
  .math-expression {
    justify-content: flex-start;
    gap: 7px;
    font-size: 15px;
  }
  .math-term {
    white-space: normal;
  }
  .math-operator {
    min-width: 22px;
    font-size: 19px;
  }
}

/* Macro price-anchor forecast matrix */
.price-anchor-card {
  padding: 0;
  overflow: hidden;
  border-color: #d8e0ea;
}

.anchor-section-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  padding: 22px 24px 19px;
  border-bottom: 1px solid #e2e7ee;
  background: linear-gradient(115deg, #f8fafc, #eef3f8);
}

.anchor-section-head > div:first-child > span {
  display: block;
  margin-bottom: 7px;
  color: #6e7f94;
  font: 700 8px ui-monospace,monospace;
  letter-spacing: .15em;
}

.anchor-section-head h2 {
  margin: 0 0 7px;
  color: #1d2a3d;
  font-size: 20px;
  letter-spacing: -.025em;
}

.anchor-section-head p {
  margin: 0;
  color: #697688;
  font-size: 11px;
}

.anchor-section-head > div:last-child {
  flex: none;
  min-width: 88px;
  padding-left: 20px;
  border-left: 1px solid #d7dfe8;
  text-align: right;
}

.anchor-section-head > div:last-child strong {
  display: block;
  color: #233b59;
  font-size: 30px;
  line-height: 1;
}

.anchor-section-head > div:last-child small {
  color: #7c8796;
  font-size: 9px;
}

.forecast-thesis {
  margin: 16px 18px;
  padding: 13px 15px;
  border: 1px solid #dfe6ee;
  border-left: 3px solid #596f91;
  border-radius: 9px;
  background: #f8fafc;
}

.forecast-thesis span,
.forecast-conditions span {
  color: #5c7190;
  font: 700 8px ui-monospace,monospace;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.forecast-thesis p {
  margin: 5px 0 0;
  color: #45546a;
  font-size: 11px;
  line-height: 1.65;
}

.anchor-matrix {
  overflow-x: auto;
  scrollbar-width: thin;
  scrollbar-color: #c0c9d5 transparent;
}

.anchor-matrix-head,
.anchor-row {
  display: grid;
  grid-template-columns: minmax(175px,.9fr) repeat(3,minmax(112px,1fr));
  min-width: 650px;
}

.anchor-matrix-head {
  margin: 0 18px;
  padding: 8px 10px;
  border: 1px solid #e0e5ec;
  border-radius: 8px 8px 0 0;
  background: #f3f6f9;
  color: #8a94a2;
  font: 700 8px ui-monospace,monospace;
  letter-spacing: .08em;
}

.anchor-matrix-head span:not(:first-child) {
  text-align: center;
}

.anchor-row {
  margin: 0 18px;
  border-right: 1px solid #e1e6ec;
  border-bottom: 1px solid #e1e6ec;
  border-left: 1px solid #e1e6ec;
  background: #fff;
}

.anchor-row:last-child {
  border-radius: 0 0 8px 8px;
}

.anchor-row > header {
  display: flex;
  min-width: 0;
  flex-direction: column;
  justify-content: center;
  padding: 12px 13px;
  background: #fbfcfd;
}

.anchor-row > header strong {
  overflow: hidden;
  color: #263449;
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.anchor-row > header small {
  overflow: hidden;
  margin-top: 3px;
  color: #9aa3af;
  font: 8px ui-monospace,monospace;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.anchor-horizon {
  position: relative;
  display: flex;
  min-width: 0;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 9px 8px 11px;
  border-left: 1px solid #e8ecf1;
  text-align: center;
}

.anchor-horizon > small {
  max-width: 100%;
  overflow: hidden;
  color: #8c96a4;
  font-size: 8px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.anchor-horizon > b {
  display: flex;
  align-items: center;
  gap: 4px;
  margin: 3px 0 1px;
  color: #4f6178;
  font-size: 11px;
}

.anchor-horizon > b i {
  font-style: normal;
  font-size: 14px;
}

.anchor-horizon > span {
  color: #9aa3af;
  font-size: 8px;
}

.anchor-horizon > em {
  width: 42px;
  height: 2px;
  margin-top: 6px;
  overflow: hidden;
  border-radius: 2px;
  background: #e7ebef;
}

.anchor-horizon > em i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: currentColor;
}

.anchor-horizon.up { color: #1e8b66; background: rgba(30,139,102,.025); }
.anchor-horizon.up > b { color: #18795a; }
.anchor-horizon.down { color: #c65f5f; background: rgba(198,95,95,.025); }
.anchor-horizon.down > b { color: #b44d4d; }
.anchor-horizon.mixed { color: #a77c31; background: rgba(167,124,49,.025); }
.anchor-horizon.mixed > b { color: #916b28; }
.anchor-horizon.flat { color: #557b9f; background: rgba(85,123,159,.025); }
.anchor-horizon.flat > b { color: #496f92; }

.forecast-conditions {
  display: grid;
  grid-template-columns: 1fr 1fr minmax(150px,.7fr);
  gap: 0;
  margin-top: 17px;
  border-top: 1px solid #e1e6ec;
  background: #f8fafb;
}

.forecast-conditions > div {
  min-width: 0;
  padding: 14px 17px;
  border-right: 1px solid #e1e6ec;
}

.forecast-conditions > div:last-child {
  border-right: 0;
}

.forecast-conditions p {
  margin: 5px 0 0;
  color: #667386;
  font-size: 9px;
  line-height: 1.55;
}

.forecast-cutoff strong,
.forecast-cutoff small {
  display: block;
}

.forecast-cutoff strong {
  margin: 5px 0 3px;
  color: #33465e;
  font: 700 9px ui-monospace,monospace;
  overflow-wrap: anywhere;
}

.forecast-cutoff small {
  color: #919aa7;
  font-size: 8px;
  line-height: 1.45;
}

@media (max-width: 780px) {
  .anchor-section-head {
    padding: 19px 17px 16px;
  }
  .anchor-section-head > div:last-child {
    min-width: 74px;
    padding-left: 13px;
  }
  .forecast-thesis {
    margin: 13px;
  }
  .anchor-matrix-head {
    display: none;
  }
  .anchor-row {
    grid-template-columns: repeat(3,1fr);
    min-width: 0;
    margin: 0 13px 12px;
    border-top: 1px solid #e1e6ec;
    border-radius: 9px;
    overflow: hidden;
  }
  .anchor-row > header {
    grid-column: 1 / -1;
    border-bottom: 1px solid #e5eaf0;
  }
  .anchor-horizon:first-of-type {
    border-left: 0;
  }
  .forecast-conditions {
    grid-template-columns: 1fr;
  }
  .forecast-conditions > div {
    border-right: 0;
    border-bottom: 1px solid #e1e6ec;
  }
  .forecast-conditions > div:last-child {
    border-bottom: 0;
  }
}

@media (max-width: 430px) {
  .anchor-section-head {
    gap: 12px;
  }
  .anchor-section-head p {
    display: none;
  }
  .anchor-horizon {
    padding-right: 3px;
    padding-left: 3px;
  }
  .anchor-horizon > small {
    font-size: 7px;
  }
}

/* Provenance training dialogue + fact graph */
.training-dialogue-card,
.fact-graph-card {
  padding: 0;
  overflow: hidden;
  border-color: #d9e2e8;
}

.training-dialogue-head,
.fact-graph-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  padding: 23px 25px 20px;
  border-bottom: 1px solid #e0e7ec;
  background: linear-gradient(115deg,#f7fafb,#eef5f5);
}

.training-dialogue-head > div:first-child > span,
.fact-graph-head > div:first-child > span {
  display: block;
  margin-bottom: 7px;
  color: #3d7f7e;
  font: 700 8px ui-monospace,monospace;
  letter-spacing: .15em;
}

.training-dialogue-head h2,
.fact-graph-head h2 {
  margin: 0 0 7px;
  color: #1e303e;
  font-size: 21px;
  letter-spacing: -.025em;
}

.training-dialogue-head p,
.fact-graph-head p {
  margin: 0;
  color: #6d7b87;
  font-size: 11px;
}

.training-dialogue-head > div:last-child {
  display: grid;
  grid-template-columns: auto auto auto auto auto;
  align-items: end;
  gap: 5px;
  flex: none;
  color: #8a959e;
  font-size: 8px;
}

.training-dialogue-head > div:last-child b {
  color: #2d555a;
  font-size: 22px;
  line-height: 1;
}

.training-dialogue-head > div:last-child i {
  padding: 0 4px 3px;
  color: #aab2b8;
  font-style: normal;
}

.training-user {
  margin: 17px 20px;
  padding: 15px 17px;
  border: 1px solid #dce6e8;
  border-left: 4px solid #398482;
  border-radius: 9px;
  background: #f6faf9;
}

.training-user > span,
.response-question > span,
.reasoning-disclosure > span {
  color: #3e7a79;
  font: 700 8px ui-monospace,monospace;
  letter-spacing: .1em;
}

.training-user p,
.response-question p {
  margin: 6px 0 0;
  color: #3d4b59;
  font-size: 11px;
  line-height: 1.7;
}

.dual-response-grid {
  display: grid;
  grid-template-columns: repeat(2,minmax(0,1fr));
  gap: 14px;
  padding: 0 20px 20px;
  align-items: start;
}

.training-response {
  min-width: 0;
  overflow: hidden;
  border: 1px solid #dce4e8;
  border-top: 3px solid #398482;
  border-radius: 11px;
  background: #fff;
}

.training-response.retrospective {
  border-top-color: #b4883d;
  background: #fffefa;
}

.response-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 17px 13px;
  border-bottom: 1px solid #e6ebee;
}

.response-head span {
  color: #40807e;
  font: 700 8px ui-monospace,monospace;
  letter-spacing: .13em;
}

.retrospective .response-head span {
  color: #a37931;
}

.response-head h3 {
  margin: 4px 0 0;
  color: #263745;
  font-size: 14px;
}

.response-head em {
  padding: 5px 8px;
  border: 1px solid #bcd9d5;
  border-radius: 999px;
  background: #eef8f6;
  color: #31766f;
  font-size: 8px;
  font-style: normal;
  white-space: nowrap;
}

.retrospective .response-head em {
  border-color: #e1d0ad;
  background: #fff7e8;
  color: #90691f;
}

.reasoning-disclosure {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 16px;
  border-bottom: 1px solid #e8edef;
  background: #f9fbfb;
}

.reasoning-disclosure strong {
  min-width: 0;
  overflow: hidden;
  color: #7d8992;
  font: 8px ui-monospace,monospace;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.response-question {
  margin: 13px 14px 0;
  padding: 11px 12px;
  border: 1px solid #eadfc9;
  border-radius: 8px;
  background: #fffbf3;
}

.think-panel {
  margin: 13px 14px;
  overflow: hidden;
  border: 1px solid #e0e6ea;
  border-radius: 9px;
  background: #fbfcfc;
}

.think-panel > summary {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 8px;
  align-items: center;
  padding: 11px 12px;
  cursor: pointer;
  list-style: none;
}

.think-panel > summary::-webkit-details-marker {
  display: none;
}

.think-panel > summary span,
.answer-panel > header span {
  padding: 3px 5px;
  border-radius: 4px;
  background: #e8f3f2;
  color: #317772;
  font: 700 8px ui-monospace,monospace;
  letter-spacing: .08em;
}

.think-panel > summary strong,
.answer-panel > header strong {
  color: #344451;
  font-size: 10px;
}

.think-panel > summary em {
  color: #9aa3aa;
  font-size: 8px;
  font-style: normal;
}

.training-copy {
  color: #56636f;
  font-size: 10px;
  line-height: 1.78;
}

.training-copy p {
  margin: 0 0 11px;
}

.training-copy p:last-child {
  margin-bottom: 0;
}

.think-copy {
  max-height: 420px;
  padding: 14px 15px 16px;
  overflow: auto;
  border-top: 1px solid #e5eaed;
  font-family: "Noto Serif SC","Songti SC",serif;
  scrollbar-width: thin;
  scrollbar-color: #c2cbd0 transparent;
}

.inline-evidence {
  display: inline;
  margin: 0 2px;
  padding: 1px 4px;
  border-radius: 4px;
  background: #e7f3f1;
  color: #27756f;
  font: 8px ui-monospace,monospace;
  overflow-wrap: anywhere;
}

.answer-panel {
  margin: 0 14px 13px;
  overflow: hidden;
  border: 1px solid #bcd8d1;
  border-radius: 9px;
  background: #f3faf7;
}

.retrospective .answer-panel {
  border-color: #dfcda9;
  background: #fffbf2;
}

.answer-panel > header {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 11px 13px 0;
}

.retrospective .answer-panel > header span {
  background: #f8eacf;
  color: #8d651e;
}

.answer-copy {
  padding: 12px 14px 14px;
  color: #304d48;
  font-size: 11px;
}

.retrospective .answer-copy {
  color: #594a30;
}

.answer-panel > footer {
  padding: 10px 13px 12px;
  border-top: 1px solid rgba(82,130,119,.15);
}

.answer-panel > footer > span {
  display: block;
  margin-bottom: 7px;
  color: #7c918d;
  font-size: 8px;
}

.answer-panel > footer > div,
.fact-node footer,
.atomic-timeline small {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.evidence-chip {
  max-width: 100%;
  padding: 3px 6px;
  border: 1px solid #c9dedb;
  border-radius: 5px;
  background: rgba(255,255,255,.7);
  color: #397872;
  font: 7px ui-monospace,monospace;
  overflow-wrap: anywhere;
}

.evidence-empty,
.empty-copy {
  color: #a0a8ae;
  font-size: 8px;
}

.rendered-training {
  border-top: 1px solid #e6ebed;
}

.rendered-training summary {
  padding: 10px 15px;
  color: #89949c;
  font-size: 8px;
  cursor: pointer;
}

.rendered-training pre {
  max-height: 320px;
  margin: 0;
  padding: 13px 15px;
  overflow: auto;
  border-top: 1px solid #e6ebed;
  background: #f7f9fa;
  color: #52616d;
  font: 8px/1.65 ui-monospace,monospace;
  white-space: pre-wrap;
}

.fact-graph-head {
  background: linear-gradient(115deg,#f8fafc,#f0f3f8);
}

.graph-counts {
  display: flex;
  gap: 9px;
  flex: none;
}

.graph-counts span {
  min-width: 62px;
  padding: 9px 11px;
  border: 1px solid #dae2e9;
  border-radius: 8px;
  background: rgba(255,255,255,.65);
  color: #82909c;
  font-size: 8px;
  text-align: center;
}

.graph-counts b {
  display: block;
  color: #2e4a64;
  font-size: 19px;
}

.graph-boundary {
  display: grid;
  grid-template-columns: auto minmax(180px,.6fr) 1fr;
  gap: 13px;
  align-items: center;
  margin: 16px 20px;
  padding: 12px 14px;
  border: 1px solid #dfe5eb;
  border-radius: 8px;
  background: #f8fafc;
}

.graph-boundary > span {
  color: #738397;
  font: 700 8px ui-monospace,monospace;
}

.graph-boundary strong {
  color: #324a63;
  font-size: 9px;
  overflow-wrap: anywhere;
}

.graph-boundary p {
  margin: 0;
  padding-left: 13px;
  border-left: 1px solid #dde3e9;
  color: #76828d;
  font-size: 9px;
  line-height: 1.55;
}

.fact-route {
  padding: 2px 20px 20px;
}

.fact-node {
  position: relative;
  overflow: hidden;
  border: 1px solid #dbe3ea;
  border-left: 4px solid #537493;
  border-radius: 9px;
  background: #fff;
  box-shadow: 0 4px 14px rgba(37,56,74,.04);
}

.fact-node header {
  display: grid;
  grid-template-columns: 30px minmax(0,1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 11px 13px 9px;
  border-bottom: 1px solid #edf0f3;
  background: #fbfcfd;
}

.fact-node header > span {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border-radius: 7px;
  background: #eaf0f6;
  color: #466b8d;
  font: 700 9px ui-monospace,monospace;
}

.fact-node header strong,
.fact-node header small {
  display: block;
}

.fact-node header strong {
  color: #3b5066;
  font-size: 9px;
  text-transform: capitalize;
}

.fact-node header small {
  margin-top: 2px;
  color: #9ca5ae;
  font: 7px ui-monospace,monospace;
}

.fact-node header time {
  color: #7f8d9a;
  font: 8px ui-monospace,monospace;
}

.fact-node > p {
  margin: 0;
  padding: 13px 15px 10px;
  color: #334354;
  font-size: 11px;
  line-height: 1.65;
}

.fact-node footer {
  padding: 0 15px 13px;
}

.fact-connector {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 8px;
  align-items: center;
  width: 70%;
  margin: 0 auto;
  padding: 7px 0;
}

.fact-connector i {
  height: 1px;
  background: #ced8e1;
}

.fact-connector span {
  padding: 4px 8px;
  border: 1px solid #d5dee7;
  border-radius: 999px;
  background: #f5f8fa;
  color: #607992;
  font-size: 8px;
}

.edge-ledger {
  border-top: 1px solid #e2e7ec;
}

.edge-ledger > summary {
  padding: 12px 20px;
  color: #60758a;
  font-size: 9px;
  cursor: pointer;
}

.edge-ledger > div {
  display: grid;
  gap: 7px;
  padding: 0 20px 18px;
}

.fact-edge {
  display: grid;
  grid-template-columns: 24px 1fr;
  gap: 9px;
  align-items: center;
  padding: 8px 10px;
  border: 1px solid #e2e7ec;
  border-radius: 7px;
  background: #fafbfc;
}

.fact-edge > span {
  color: #8d9aa6;
  font: 700 8px ui-monospace,monospace;
}

.fact-edge p {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 8px;
  align-items: center;
  margin: 0;
}

.fact-edge b {
  color: #4b5b69;
  font-size: 8px;
  font-weight: 500;
}

.fact-edge em {
  padding: 3px 6px;
  border-radius: 5px;
  background: #eaf0f5;
  color: #4d6d89;
  font-size: 7px;
  font-style: normal;
  white-space: nowrap;
}

.atomic-timeline article {
  display: grid;
  grid-template-columns: 75px 25px minmax(0,1fr);
  gap: 10px;
  padding: 12px 0;
  border-bottom: 1px solid #e7ebee;
}

.atomic-timeline article:last-child {
  border-bottom: 0;
}

.atomic-timeline time {
  color: #7d8b96;
  font: 8px ui-monospace,monospace;
}

.atomic-timeline article > span {
  display: grid;
  width: 22px;
  height: 22px;
  place-items: center;
  border-radius: 50%;
  background: #e8f3f2;
  color: #377b76;
  font: 700 7px ui-monospace,monospace;
}

.atomic-timeline strong {
  color: #40515e;
  font-size: 9px;
}

.atomic-timeline p {
  margin: 4px 0 8px;
  color: #68757f;
  font-size: 9px;
  line-height: 1.6;
}

@media (max-width: 980px) {
  .dual-response-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 780px) {
  .training-dialogue-head,
  .fact-graph-head {
    padding: 19px 17px 16px;
  }
  .training-dialogue-head > div:last-child {
    display: none;
  }
  .training-user {
    margin: 13px;
  }
  .dual-response-grid {
    gap: 12px;
    padding: 0 13px 13px;
  }
  .graph-counts span {
    min-width: 52px;
    padding: 7px 8px;
  }
  .graph-boundary {
    grid-template-columns: 1fr;
    margin: 13px;
  }
  .graph-boundary p {
    padding: 9px 0 0;
    border-top: 1px solid #dde3e9;
    border-left: 0;
  }
  .fact-route {
    padding: 2px 13px 13px;
  }
  .fact-node header {
    grid-template-columns: 30px minmax(0,1fr);
  }
  .fact-node header time {
    grid-column: 2;
  }
  .fact-connector {
    width: 92%;
  }
  .fact-edge p {
    grid-template-columns: 1fr;
  }
  .fact-edge em {
    justify-self: start;
  }
  .atomic-timeline article {
    grid-template-columns: 24px minmax(0,1fr);
  }
  .atomic-timeline time {
    grid-column: 2;
    grid-row: 1;
  }
  .atomic-timeline article > span {
    grid-column: 1;
    grid-row: 1 / span 2;
  }
  .atomic-timeline article > div {
    grid-column: 2;
  }
}

@media (max-width: 430px) {
  .fact-graph-head p,
  .training-dialogue-head p {
    display: none;
  }
  .graph-counts {
    gap: 5px;
  }
  .graph-counts span {
    min-width: 46px;
  }
}

/* Langfuse observation guide */
.breadcrumb a {
  color: #7d8993;
  transition: color .18s ease;
}

.breadcrumb a:hover {
  color: #2f6866;
}

.guide-parent-nav {
  display: flex;
  margin-bottom: 15px;
}

.guide-parent-nav a {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px 9px 9px;
  border: 1px solid #d9e2e5;
  border-radius: 9px;
  background: #fff;
  box-shadow: 0 4px 14px rgba(36,58,66,.04);
  transition: .18s ease;
}

.guide-parent-nav a:hover {
  border-color: #adc8c7;
  transform: translateX(-2px);
}

.guide-parent-nav a > span {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  border-radius: 7px;
  background: #eaf4f2;
  color: #33746f;
  font-size: 13px;
}

.guide-parent-nav small,
.guide-parent-nav strong {
  display: block;
}

.guide-parent-nav small {
  color: #98a2a8;
  font-size: 7px;
}

.guide-parent-nav strong {
  margin-top: 1px;
  color: #354852;
  font-size: 10px;
}

.guide-footer-nav {
  display: flex;
  justify-content: center;
  margin: -10px 0 30px;
  padding-top: 18px;
  border-top: 1px solid #dfe5e8;
}

.guide-footer-nav a {
  padding: 10px 16px;
  border: 1px solid #cbdcdd;
  border-radius: 8px;
  background: #f3f8f7;
  color: #356e6a;
  font-size: 9px;
  font-weight: 700;
}

.trace-guide-entry {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 18px;
  padding: 17px 19px;
  border: 1px solid #d8e2e4;
  border-radius: 12px;
  background: linear-gradient(105deg,#f5faf9,#f8fafc);
  box-shadow: 0 7px 24px rgba(34,66,73,.04);
  transition: .2s ease;
}

.trace-guide-entry:hover {
  transform: translateY(-1px);
  border-color: #a9c5c5;
  box-shadow: 0 10px 28px rgba(34,66,73,.08);
}

.trace-guide-entry > div {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 14px;
}

.trace-guide-entry > div > span {
  display: grid;
  width: 42px;
  height: 42px;
  flex: none;
  place-items: center;
  border-radius: 10px;
  background: #e4f1ef;
  color: #2f7972;
}

.trace-guide-entry svg {
  width: 20px;
  height: 20px;
}

.trace-guide-entry small {
  display: block;
  margin-bottom: 3px;
  color: #4b8782;
  font: 700 7px ui-monospace,monospace;
  letter-spacing: .13em;
}

.trace-guide-entry strong {
  display: block;
  color: #263947;
  font-size: 13px;
}

.trace-guide-entry p {
  margin: 3px 0 0;
  color: #76838c;
  font-size: 9px;
}

.trace-guide-entry > em {
  flex: none;
  color: #3d716e;
  font-size: 9px;
  font-style: normal;
  font-weight: 700;
}

.lf-guide-hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0,1.25fr) minmax(280px,.75fr);
  gap: 40px;
  align-items: end;
  min-height: 310px;
  margin-bottom: 38px;
  padding: 44px 46px 38px;
  overflow: hidden;
  border: 1px solid #dce3e9;
  border-radius: 18px;
  background: linear-gradient(125deg,#f9fbfc 5%,#eef4f6 58%,#e7f1ef);
  box-shadow: 0 18px 48px rgba(36,53,67,.07);
}

.lf-guide-hero:after {
  content: "";
  position: absolute;
  top: -90px;
  right: -55px;
  width: 310px;
  height: 310px;
  border: 1px solid rgba(65,123,118,.12);
  border-radius: 50%;
  box-shadow: 0 0 0 45px rgba(65,123,118,.025),0 0 0 90px rgba(65,123,118,.018);
}

.lf-guide-hero > div {
  position: relative;
  z-index: 1;
}

.lf-guide-hero > div:first-child > span,
.guide-section-head span {
  color: #397d77;
  font: 700 8px ui-monospace,monospace;
  letter-spacing: .15em;
}

.lf-guide-hero h1 {
  max-width: 720px;
  margin: 13px 0 14px;
  color: #1f3040;
  font-size: clamp(32px,4vw,52px);
  line-height: 1.05;
  letter-spacing: -.05em;
}

.lf-guide-hero p {
  max-width: 680px;
  margin: 0 0 18px;
  color: #657580;
  font-size: 12px;
  line-height: 1.75;
}

.lf-guide-hero small {
  color: #8a969e;
  font: 8px ui-monospace,monospace;
}

.lf-guide-stats {
  display: grid;
  grid-template-columns: repeat(3,1fr);
  overflow: hidden;
  border: 1px solid rgba(87,119,127,.18);
  border-radius: 12px;
  background: rgba(255,255,255,.62);
  backdrop-filter: blur(8px);
}

.lf-guide-stats span {
  padding: 18px 12px 16px;
  border-right: 1px solid rgba(87,119,127,.16);
  color: #76858e;
  font-size: 8px;
  text-align: center;
}

.lf-guide-stats span:last-child {
  border-right: 0;
}

.lf-guide-stats b {
  display: block;
  margin-bottom: 5px;
  color: #315c62;
  font-size: 25px;
}

.guide-section {
  margin-bottom: 42px;
}

.guide-section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 28px;
  margin-bottom: 17px;
  padding-bottom: 14px;
  border-bottom: 1px solid #dfe4e8;
}

.guide-section-head h2 {
  margin: 6px 0 0;
  color: #263643;
  font-size: 21px;
  letter-spacing: -.025em;
}

.guide-section-head > p {
  max-width: 520px;
  margin: 0;
  color: #7b878f;
  font-size: 9px;
  line-height: 1.6;
  text-align: right;
}

.lf-layer-grid {
  display: grid;
  grid-template-columns: repeat(3,1fr);
  gap: 12px;
}

.lf-layer-grid article {
  position: relative;
  min-height: 210px;
  padding: 20px;
  overflow: hidden;
  border: 1px solid #dce3e8;
  border-radius: 12px;
  background: #fff;
}

.lf-layer-grid article > span {
  position: absolute;
  top: 13px;
  right: 15px;
  color: #bcc5cb;
  font: 700 9px ui-monospace,monospace;
}

.lf-layer-grid article > i {
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
  border-radius: 9px;
  background: #e9f3f2;
  color: #377b76;
}

.lf-layer-grid svg {
  width: 17px;
  height: 17px;
}

.lf-layer-grid h3 {
  margin: 18px 0 8px;
  color: #314451;
  font-size: 14px;
}

.lf-layer-grid p {
  min-height: 48px;
  margin: 0 0 13px;
  color: #77838b;
  font-size: 9px;
  line-height: 1.65;
}

.lf-layer-grid code,
.probe-type code {
  display: inline-block;
  padding: 5px 7px;
  border: 1px solid #dfe6e9;
  border-radius: 5px;
  background: #f5f8f8;
  color: #476c70;
  font: 8px ui-monospace,monospace;
}

.lf-layer-grid article > small {
  display: block;
  margin-top: 10px;
  color: #9ba5ab;
  font-size: 8px;
}

.lf-route-map {
  padding: 25px;
  border: 1px solid #dae2e7;
  border-radius: 14px;
  background: #f8fafb;
}

.lf-route-root {
  width: 270px;
  margin: 0 auto;
  padding: 14px 16px;
  border: 2px solid #4b7475;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 5px 18px rgba(46,85,86,.08);
  text-align: center;
}

.lf-route-root span,
.lf-route-branches article > span {
  display: block;
  color: #4b8781;
  font: 700 7px ui-monospace,monospace;
  letter-spacing: .1em;
}

.lf-route-root strong,
.lf-route-root small,
.lf-route-branches article > strong,
.lf-route-branches article > small {
  display: block;
}

.lf-route-root strong {
  margin: 4px 0 3px;
  color: #263d49;
  font-size: 13px;
}

.lf-route-root small,
.lf-route-branches article > small {
  color: #939ea6;
  font-size: 8px;
}

.lf-route-stem {
  width: 1px;
  height: 28px;
  margin: 0 auto;
  background: #bfcdd3;
}

.lf-route-branches {
  position: relative;
  display: grid;
  grid-template-columns: .75fr .75fr 1.5fr;
  gap: 14px;
}

.lf-route-branches:before {
  content: "";
  position: absolute;
  top: -1px;
  left: 16.66%;
  right: 25%;
  height: 1px;
  background: #bfcdd3;
}

.lf-route-branches article {
  position: relative;
  min-width: 0;
  padding: 17px 16px;
  border: 1px solid #dae1e7;
  border-top: 3px solid #8d67bc;
  border-radius: 10px;
  background: #fff;
}

.lf-route-branches article:before {
  content: "";
  position: absolute;
  top: -17px;
  left: 50%;
  width: 1px;
  height: 14px;
  background: #bfcdd3;
}

.lf-route-branches article.agent {
  border-top-color: #437c76;
}

.lf-route-branches article > strong {
  margin: 5px 0 4px;
  color: #354653;
  font-size: 11px;
}

.mini-nodes {
  display: flex;
  gap: 5px;
  margin-top: 13px;
}

.mini-nodes i {
  padding: 4px 6px;
  border-radius: 5px;
  background: #f3eefa;
  color: #7655a2;
  font: 700 7px ui-monospace,monospace;
  font-style: normal;
}

.workflow-route {
  display: flex;
  align-items: center;
  gap: 5px;
  margin-top: 14px;
  overflow-x: auto;
  scrollbar-width: thin;
}

.workflow-route b {
  flex: none;
  padding: 6px 8px;
  border: 1px solid #cfe0de;
  border-radius: 6px;
  background: #eff7f6;
  color: #39716e;
  font-size: 8px;
}

.workflow-route i {
  flex: none;
  color: #a1abb1;
  font: 7px ui-monospace,monospace;
  font-style: normal;
}

.probe-type-grid {
  display: grid;
  grid-template-columns: repeat(3,1fr);
  gap: 11px;
}

.probe-type {
  --probe:#527993;
  min-height: 180px;
  padding: 17px;
  border: 1px solid #dce3e8;
  border-top: 3px solid var(--probe);
  border-radius: 10px;
  background: #fff;
}

.probe-type.agent { --probe:#3a857b; }
.probe-type.generation { --probe:#c95b99; }
.probe-type.tool { --probe:#d1813c; }
.probe-type.event { --probe:#7aae43; }
.probe-type.chain { --probe:#8b61bd; }

.probe-type header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.probe-type header span {
  color: #a6b0b7;
  font: 700 8px ui-monospace,monospace;
}

.probe-type header em {
  padding: 4px 6px;
  border-radius: 5px;
  background: color-mix(in srgb,var(--probe) 10%,white);
  color: var(--probe);
  font: 700 7px ui-monospace,monospace;
  font-style: normal;
}

.probe-type h3 {
  margin: 20px 0 9px;
  color: #334553;
  font-size: 13px;
}

.probe-type code {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.probe-type p {
  margin: 14px 0 0;
  color: #75828a;
  font-size: 9px;
  line-height: 1.65;
}

.payload-explorer {
  display: grid;
  grid-template-columns: minmax(0,1fr) 220px;
  gap: 12px;
}

.payload-tabs {
  display: flex;
  grid-column: 1 / -1;
  gap: 6px;
  padding: 6px;
  overflow-x: auto;
  border: 1px solid #dce3e8;
  border-radius: 9px;
  background: #f4f7f8;
}

.payload-tabs button {
  flex: none;
  padding: 8px 12px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: #79868e;
  font-size: 9px;
  cursor: pointer;
}

.payload-tabs button.active {
  background: #fff;
  color: #315d60;
  font-weight: 700;
  box-shadow: 0 2px 8px rgba(44,70,74,.08);
}

.payload-demo {
  min-width: 0;
  overflow: hidden;
  border: 1px solid #d8e0e5;
  border-radius: 11px;
  background: #17222d;
}

.payload-demo header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 11px 14px;
  border-bottom: 1px solid rgba(255,255,255,.09);
  background: #1b2935;
}

.payload-demo header span {
  color: #d7e4e7;
  font: 700 9px ui-monospace,monospace;
}

.payload-demo header em {
  color: #718690;
  font: 700 7px ui-monospace,monospace;
  font-style: normal;
  letter-spacing: .1em;
}

.payload-demo pre {
  min-height: 310px;
  max-height: 470px;
  margin: 0;
  padding: 17px;
  overflow: auto;
  color: #b9d3d4;
  font: 10px/1.7 ui-monospace,SFMono-Regular,Consolas,monospace;
}

.payload-keys {
  padding: 17px;
  border: 1px solid #dce3e8;
  border-radius: 11px;
  background: #fff;
}

.payload-keys h3 {
  margin: 0 0 13px;
  color: #384b58;
  font-size: 11px;
}

.payload-keys > div {
  padding: 9px 0;
  border-bottom: 1px solid #e9edef;
}

.payload-keys > div:last-child {
  border-bottom: 0;
}

.payload-keys span {
  color: #397975;
  font: 8px ui-monospace,monospace;
}

.payload-keys p {
  margin: 3px 0 0;
  color: #87929a;
  font-size: 8px;
}

.lf-coverage {
  overflow: hidden;
  border: 1px solid #dce3e8;
  border-radius: 10px;
  background: #fff;
}

.lf-coverage > div {
  display: grid;
  grid-template-columns: 1fr 85px 85px 1.6fr;
}

.lf-coverage > div:not(.lf-coverage-head) {
  border-top: 1px solid #e6ebee;
}

.lf-coverage span {
  padding: 11px 14px;
  color: #65737c;
  font-size: 9px;
}

.lf-coverage span:nth-child(2),
.lf-coverage span:nth-child(3) {
  border-left: 1px solid #e6ebee;
  text-align: center;
}

.lf-coverage span:nth-child(4) {
  border-left: 1px solid #e6ebee;
}

.lf-coverage-head {
  background: #f3f6f7;
}

.lf-coverage-head span {
  color: #8c979e;
  font: 700 8px ui-monospace,monospace;
  letter-spacing: .07em;
}

.lf-coverage .covered {
  color: #2c8a73;
  font-weight: 800;
}

.guide-note {
  display: grid;
  grid-template-columns: 85px 1fr;
  gap: 14px;
  align-items: center;
  margin-top: 12px;
  padding: 13px 15px;
  border-left: 4px solid #477a78;
  border-radius: 7px;
  background: #f1f7f6;
}

.guide-note b {
  color: #326c68;
  font-size: 9px;
}

.guide-note p {
  margin: 0;
  color: #697a80;
  font-size: 9px;
  line-height: 1.6;
}

@media (max-width: 980px) {
  .lf-guide-hero {
    grid-template-columns: 1fr;
  }
  .lf-route-branches {
    grid-template-columns: 1fr 1fr;
  }
  .lf-route-branches article.workflow {
    grid-column: 1 / -1;
  }
  .lf-route-branches:before {
    display: none;
  }
  .lf-route-branches article:before {
    display: none;
  }
  .probe-type-grid {
    grid-template-columns: repeat(2,1fr);
  }
}

@media (max-width: 780px) {
  .trace-guide-entry p,
  .trace-guide-entry > em {
    display: none;
  }
  .lf-guide-hero {
    min-height: 0;
    padding: 28px 23px 24px;
  }
  .lf-guide-stats {
    grid-template-columns: repeat(3,1fr);
  }
  .guide-section-head {
    align-items: flex-start;
  }
  .guide-section-head > p {
    display: none;
  }
  .lf-layer-grid,
  .probe-type-grid {
    grid-template-columns: 1fr;
  }
  .lf-layer-grid article,
  .probe-type {
    min-height: 0;
  }
  .lf-layer-grid p {
    min-height: 0;
  }
  .lf-route-map {
    padding: 17px 13px;
  }
  .lf-route-root {
    width: auto;
  }
  .lf-route-branches {
    grid-template-columns: 1fr;
  }
  .lf-route-branches article.workflow {
    grid-column: auto;
  }
  .payload-explorer {
    grid-template-columns: 1fr;
  }
  .payload-keys {
    display: grid;
    grid-template-columns: repeat(2,1fr);
    gap: 0 12px;
  }
  .payload-keys h3 {
    grid-column: 1 / -1;
  }
  .lf-coverage {
    overflow-x: auto;
  }
  .lf-coverage > div {
    min-width: 600px;
  }
}

@media (max-width: 430px) {
  .trace-guide-entry {
    padding: 13px;
  }
  .trace-guide-entry > div > span {
    width: 36px;
    height: 36px;
  }
  .lf-guide-hero h1 {
    font-size: 31px;
  }
  .lf-guide-stats span {
    padding: 13px 5px;
  }
  .lf-guide-stats b {
    font-size: 21px;
  }
  .workflow-route {
    align-items: stretch;
    flex-direction: column;
  }
  .workflow-route i {
    padding-left: 8px;
  }
  .payload-keys {
    grid-template-columns: 1fr;
  }
  .payload-keys h3 {
    grid-column: auto;
  }
  .guide-note {
    grid-template-columns: 1fr;
  }
}
