/* Match the compact Atlas topic actions. */
.topic-actions .kg-open{display:inline-flex;align-items:center;justify-content:center;width:32px;min-height:32px;padding:7px;border:1px solid var(--line,#e1e6ee);border-radius:5px;background:#fff;color:var(--ink,#18212f);font:500 12px/1.4 var(--sans,system-ui);cursor:pointer}
.topic-actions .kg-open:hover{border-color:var(--accent,#2563eb);color:var(--accent,#2563eb);background:var(--accent-soft,#e8efff)}
.kg-page{box-sizing:border-box;width:min(1440px,calc(100vw - 48px));max-width:calc(100vw - 48px);height:min(920px,calc(100dvh - 48px));max-height:calc(100dvh - 48px);padding:0;border:1px solid var(--line,#e1e6ee);border-radius:12px;background:var(--paper,#f7f9fc);color:var(--ink,#18212f);box-shadow:0 24px 80px #18212f33;overflow:hidden;font:14px/1.5 var(--sans,system-ui)}

.kg-page *{box-sizing:border-box}.kg-page button,.kg-page select{font:500 12px/1.4 var(--sans,system-ui)}.kg-page button{min-height:36px;cursor:pointer;border:1px solid var(--line,#e1e6ee);background:#fff;color:var(--ink,#18212f);border-radius:6px;padding:8px 12px}.kg-page button:hover{border-color:var(--accent,#2563eb);background:var(--accent-soft,#e8efff)}.kg-page button:disabled{opacity:.45;cursor:default}.kg-page :focus-visible,.kg-open:focus-visible{outline:2px solid var(--accent,#2563eb);outline-offset:3px}
.kg-header{padding:20px 24px;display:flex;align-items:flex-start;justify-content:space-between;border-bottom:1px solid var(--line);gap:16px;background:#fff}.kg-header small{font-size:10px;color:var(--muted);letter-spacing:1.6px;font-weight:650}.kg-header h1{margin:5px 0 7px;font:500 28px/1.15 var(--serif,Georgia);letter-spacing:-.4px}.kg-header p{margin:0;max-width:960px;color:var(--muted);font-size:13px}.kg-tools{display:flex;justify-content:space-between;align-items:center;padding:12px 24px 6px;gap:12px}.kg-tools>div:last-child{display:flex;gap:6px}.kg-legend{display:flex;align-items:center;gap:8px;color:var(--muted);font-size:12px}.kg-seed-dot,.kg-neighbor-dot{width:10px;height:10px;border-radius:50%;display:inline-block;background:#17866f}.kg-neighbor-dot{background:#5275a3;margin-left:14px}
#kg-status{padding:6px 24px 12px;margin:0;color:var(--muted);font-size:12px;min-height:36px}.kg-workspace{display:grid;grid-template-columns:minmax(0,1fr) minmax(330px,370px);min-height:0;flex:1;border-top:1px solid var(--line)}.kg-canvas-wrap{min-width:0;min-height:0;position:relative;background:radial-gradient(circle,#cdd6e2 .7px,transparent .9px);background-size:24px 24px;overflow:hidden}#kg-canvas{width:100%;height:100%;min-height:280px;touch-action:none;user-select:none}.kg-canvas-help{position:absolute;bottom:8px;left:12px;right:12px;text-align:center;pointer-events:none;font-size:11px;color:var(--muted);background:#f7f9fcee;margin:0;padding:6px;border-radius:5px}
.kg-edge{stroke:#8299b3;stroke-width:2;cursor:pointer;pointer-events:stroke;transition:opacity .15s}.kg-edge:hover,.kg-edge:focus{stroke:#b77e23;stroke-width:5}.kg-edge.kg-highlight{stroke:#508b80;stroke-width:2.5}.kg-edge.kg-muted{opacity:.2}.kg-node{cursor:pointer;transition:opacity .15s}.kg-node circle{fill:#5275a3;stroke:#fff;stroke-width:3;filter:drop-shadow(0 2px 2px #18212f22)}.kg-node.kg-seed circle{fill:#17866f}.kg-node.kg-selected circle{fill:#d7a345;stroke:#714b13;stroke-width:3}.kg-node text{font:12px var(--sans,system-ui);fill:#26364b;paint-order:stroke;stroke:#f7f9fc;stroke-width:5;stroke-linejoin:round}.kg-node.kg-selected text{font-weight:700}.kg-node.kg-muted{opacity:.36}.kg-node:hover,.kg-node:focus{opacity:1}.kg-no-labels .kg-node text{display:none}
.kg-sidebar{background:#fff;border-left:1px solid var(--line);overflow:auto;padding:20px;min-height:0;scrollbar-gutter:stable}.kg-node-picker{display:block;color:var(--muted);font-size:12px}.kg-node-picker select{display:block;width:100%;height:40px;padding:8px;margin:6px 0 20px;border:1px solid var(--line);border-radius:6px;background:#fff;color:var(--ink)}.kg-domain-label{color:var(--muted);text-transform:uppercase;font-size:10px;letter-spacing:1px}#kg-detail h3{font:500 21px/1.35 var(--serif,Georgia);margin:8px 0 16px;overflow-wrap:anywhere}.kg-original{display:flex;justify-content:center;align-items:center;min-height:40px;padding:10px 12px;border:1px solid var(--accent,#2563eb);border-radius:6px;color:var(--accent,#2563eb);background:var(--accent-soft,#e8efff);text-decoration:none;font-size:12px;font-weight:550;margin:8px 0}.kg-original:hover{background:#dce8fc}.kg-expand{width:100%;min-height:40px!important}.kg-statement-body{white-space:pre-wrap;overflow-wrap:anywhere;font-size:13px;line-height:1.75;color:#3c4b60;max-height:230px;overflow:auto;padding:14px;border:1px solid var(--line);border-radius:6px;background:var(--paper);margin:16px 0 22px}#kg-detail h4{font-size:12px;font-weight:650;margin:14px 0 8px}.kg-related{display:block;width:100%;text-align:left;font-size:12px;line-height:1.5;margin-top:10px}.kg-connection{border:1px solid var(--line);border-radius:6px;margin:8px 0;padding:10px 12px;background:#fff}.kg-connection>summary{cursor:pointer;font-size:12px;line-height:1.55;font-weight:550;overflow-wrap:anywhere}.kg-keywords{display:block;font-size:11px;font-weight:400;color:#217765;margin:6px 0 0}.kg-connection[open]>summary{padding-bottom:8px;border-bottom:1px solid var(--line)}.kg-evidence{padding:4px 0 10px;font-size:12px}.kg-evidence h4{color:#217765}.kg-source summary{cursor:pointer;color:var(--muted);font-size:11px;overflow-wrap:anywhere;margin:10px 0}.kg-source blockquote{margin:8px 0;padding:10px;border-left:3px solid #76a99c;background:#f4f8f6;white-space:pre-wrap;overflow-wrap:anywhere;line-height:1.65}.kg-source code{font-size:10px;overflow-wrap:anywhere;color:var(--muted)}.kg-footer{padding:12px 24px;display:flex;align-items:center;justify-content:space-between;gap:16px;border-top:1px solid var(--line);background:#fff;font-size:12px}.kg-footer div{display:flex;gap:6px;flex-shrink:0}.kg-footer small{color:var(--muted);font-size:11px;max-width:260px}
@media(max-width:1000px){.kg-page{width:calc(100vw - 24px);max-width:calc(100vw - 24px)}.kg-workspace{grid-template-columns:minmax(0,1fr) 320px}.kg-header,.kg-tools,.kg-footer{padding-left:18px;padding-right:18px}.kg-legend{gap:6px;font-size:11px}}
@media(max-width:760px){.kg-page{height:calc(100dvh - 16px);max-height:calc(100dvh - 16px);width:calc(100vw - 16px);max-width:calc(100vw - 16px);border-radius:10px}.kg-header{padding:14px 16px}.kg-header h1{font-size:25px}.kg-header p{font-size:12px;max-height:40px;overflow:auto}.kg-tools{padding:10px 14px 4px;flex-wrap:wrap}.kg-tools button{padding:7px 10px;min-height:36px}.kg-legend{font-size:12px}#kg-status{padding:4px 14px 10px;font-size:11px}.kg-workspace{display:flex;flex-direction:column;overflow:auto}.kg-canvas-wrap{min-height:330px;height:330px;flex-shrink:0}.kg-sidebar{border-left:0;border-top:1px solid var(--line);overflow:visible;padding:16px}.kg-footer{padding:10px 14px;gap:8px;flex-wrap:wrap}.kg-footer small{max-width:none;width:100%;font-size:10px}.kg-canvas-help{font-size:10px}.kg-node text{font-size:14px}}

/* Standalone page: normal document flow, no overlay or modal container. */
.kg-page-body{height:100dvh;min-height:100dvh;display:flex;flex-direction:column;overflow:hidden}
.kg-masthead{flex-shrink:0;min-height:62px;padding:14px 24px;background:#fff;border-bottom:1px solid var(--line)}
.kg-masthead nav{display:flex;align-items:center;gap:20px;font-size:12px;color:var(--muted)}
.kg-masthead nav a{color:var(--ink);text-decoration:none}.kg-masthead nav a:hover{text-decoration:underline}
.kg-page{display:flex;flex-direction:column;width:100%;max-width:none;min-height:0;height:auto;max-height:none;flex:1;border:0;border-radius:0;box-shadow:none;margin:0;overflow:hidden}
.kg-back{display:inline-flex;align-items:center;justify-content:center;flex-shrink:0;min-height:40px;padding:9px 14px;border:1px solid var(--line);border-radius:6px;background:#fff;color:var(--ink);font-size:12px;text-decoration:none}
.kg-back:hover{border-color:var(--accent);color:var(--accent)}
.topic-actions .kg-open{text-decoration:none;text-align:center}
@media(max-width:760px){.kg-masthead{min-height:54px;padding:12px 16px}.kg-masthead nav{gap:12px;font-size:11px}.kg-header{flex-wrap:wrap}.kg-header>div{flex:1;min-width:190px}.kg-back{min-height:36px;padding:7px 10px}.kg-page{width:100%;max-width:none;height:auto;max-height:none;border-radius:0}}
/* Compact navigation and a freely movable graph. */
.kg-masthead{min-height:46px;padding:10px 20px}
.kg-header{padding:10px 20px;align-items:center;gap:12px;min-height:56px}
.kg-header .kg-heading{display:flex;align-items:center;gap:14px;min-width:0;flex:1}
.kg-header h1{margin:0;font:500 19px/1.3 var(--serif,Georgia);letter-spacing:0;white-space:nowrap}
.kg-heading-divider{color:#a4afbe;font-size:16px}
.kg-header p{font-size:12px;line-height:1.4;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;max-width:none}
.kg-back{min-height:32px;padding:6px 10px;border:0;background:transparent}
.kg-tools{padding:6px 20px 2px}.kg-tools button{min-height:30px;padding:5px 9px}
#kg-status{min-height:26px;padding:4px 20px 6px;font-size:11px}
.kg-footer{padding:7px 20px}.kg-footer button{min-height:30px;padding:5px 10px}
.kg-sidebar{padding-top:16px}.kg-statement-body{background:transparent;border:0;border-bottom:1px solid var(--line);border-radius:0;padding:10px 0 16px}
.kg-node.kg-selected circle{fill:#17866f;stroke:#b6d8d0;stroke-width:5}
.kg-node:focus-visible{outline:none}.kg-node:focus-visible circle{stroke:var(--accent);stroke-width:5}
#kg-canvas,.kg-node{cursor:grab}#kg-canvas.kg-dragging,#kg-canvas.kg-dragging .kg-node{cursor:grabbing}
.kg-details-hidden .kg-workspace{grid-template-columns:minmax(0,1fr)}
.kg-sidebar[hidden]{display:none}
@media(max-width:760px){.kg-header{padding:9px 14px;flex-wrap:nowrap;min-height:52px}.kg-header .kg-heading{flex-wrap:wrap;gap:2px 8px;min-width:0}.kg-header h1{font-size:18px}.kg-heading-divider{display:none}.kg-header p{flex-basis:100%;font-size:11px}.kg-back{font-size:11px;padding:5px 0}.kg-tools{padding:6px 14px 2px;gap:6px}.kg-tools>div:last-child{flex-wrap:wrap}.kg-tools button{padding:5px 8px;min-height:30px}#kg-status{padding:4px 14px 6px}.kg-details-hidden .kg-canvas-wrap{height:100%;min-height:350px;flex:1}.kg-footer{padding:6px 14px}.kg-masthead{min-height:44px;padding:10px 14px}}
/* Open canvas: selection is a color change, never a rectangular focus box. */
.kg-canvas-wrap{background:#fafbfd}
#kg-canvas:focus,#kg-canvas *:focus,#kg-canvas *:focus-visible{outline:none!important}
.kg-node circle{stroke:#fff;stroke-width:2;filter:none}
.kg-node.kg-selected circle{fill:#0e6657;stroke:#fff;stroke-width:2}
.kg-node:focus-visible circle{stroke:#2458a0;stroke-width:2}
.kg-node.kg-muted{opacity:.72}
.kg-node text{fill:#4f6176;font-weight:400;pointer-events:none;stroke:#fafbfd;stroke-linejoin:round}
.kg-node.kg-selected text{fill:#144f45;font-weight:600}
.kg-edge{stroke:#98acbf;stroke-width:1.3;vector-effect:non-scaling-stroke;opacity:.8;fill:none}
.kg-edge.kg-highlight{stroke:#3a8f7c;stroke-width:1.9;opacity:1}
.kg-edge:hover,.kg-edge:focus-visible{stroke:#397d9c;stroke-width:2.5;opacity:1}
.kg-canvas-help{background:transparent}
@media(max-width:760px){#kg-canvas{touch-action:pan-y pinch-zoom}}
.kg-location{font-size:11px;line-height:1.6}.kg-location a{color:#36746a;text-decoration:none}.kg-location a:hover{text-decoration:underline}
.kg-scope-label{font-size:11px;color:var(--muted)}
@media(max-width:760px){.kg-tools{align-items:flex-start}.kg-tools>div:last-child{gap:4px}}
.kg-node.kg-selected circle{fill:#345a83}.kg-node.kg-seed.kg-selected circle{fill:#0e6657}.kg-node.kg-muted{opacity:.88}
.kg-statement-graph{display:block;margin:10px 0;padding:10px 12px;background:#edf5f2;color:#226653;border-radius:6px;text-align:center;text-decoration:none;font-size:12px;font-weight:550}
.kg-statement-graph:hover{background:#dfeee7}.kg-footer div[hidden]{display:none}

/* No persistent graph statistics or empty status row. */
#kg-status:empty{display:none}
.kg-reference-edge{stroke:#796b9a;stroke-width:1.6;stroke-dasharray:none}.kg-keyword-edge{stroke-dasharray:4 4}
.kg-legend{flex-wrap:wrap}.kg-reference-swatch,.kg-keyword-swatch{width:20px;height:0;border-top:2px solid #796b9a;margin-left:10px}.kg-keyword-swatch{border-top:2px dashed #98acbf}
.kg-reference-source{font-size:11px;margin:10px 0}.kg-reference-source summary{cursor:pointer;color:#685b87}.kg-reference-source pre{white-space:pre-wrap;overflow-wrap:anywhere;background:#f6f5fa;padding:10px}.kg-reference-source code{display:block;overflow-wrap:anywhere}
/* Formula captions are complete typeset HTML inside SVG, not truncated TeX text. */
.kg-math-label{box-sizing:border-box;width:180px;padding:2px 4px;font:11px/15px var(--sans,system-ui);text-align:center;color:#4f6176;overflow-wrap:normal;white-space:normal;pointer-events:none}
.kg-math-label .math-fragment{font-size:inherit}.kg-math-label mjx-container{max-width:none!important;overflow:visible!important}
.kg-math-measure{position:fixed;left:-20000px;top:0;visibility:hidden;height:auto}
.kg-formula-caption{pointer-events:none;overflow:visible}.kg-no-labels .kg-formula-caption{display:none}
.kg-node.kg-selected .kg-math-label{color:#144f45}
.kg-statement-body{white-space:normal}.kg-statement-body mjx-container[display="true"]{overflow-x:auto;max-width:100%}
.kg-caption-leader{stroke:#b5becb;stroke-width:1;stroke-dasharray:2 3;vector-effect:non-scaling-stroke;pointer-events:none}

/* Keep navigation without the statement-count / pagination summary. */
#kg-page-info{display:none}

.kg-sidebar-pagination{display:flex;justify-content:space-between;gap:8px;margin-bottom:16px;padding-bottom:12px;border-bottom:1px solid var(--line)}
.kg-sidebar-pagination[hidden]{display:none}

/* Distinct relation layers remain visible for overlapping endpoints. */
.kg-formal-edge{stroke:#2463b6;stroke-width:2;stroke-dasharray:none}
.kg-reference-edge{stroke:#796b9a;stroke-dasharray:8 3 2 3}
.kg-keyword-edge{stroke:#98acbf;stroke-dasharray:4 4}
.kg-formal-edge.kg-highlight{stroke:#2463b6;stroke-width:2.6}
.kg-reference-edge.kg-highlight{stroke:#796b9a}
.kg-formal-swatch{width:24px;height:0;border-top:2px solid #2463b6;margin-left:10px;position:relative}
.kg-formal-swatch:after{content:"";position:absolute;right:-1px;top:-5px;width:6px;height:6px;border-top:2px solid #2463b6;border-right:2px solid #2463b6;transform:rotate(45deg)}
.kg-reference-swatch{height:2px;border:0;background:repeating-linear-gradient(to right,#796b9a 0 8px,transparent 8px 11px,#796b9a 11px 13px,transparent 13px 16px)}
.kg-formal-coverage{font-size:12px;margin:12px 0}.kg-formal-coverage p{overflow-wrap:anywhere}

/* Declaration identity is independent of its natural-language Atlas binding. */
.kg-formal-node circle { fill: #e4efff; stroke: #2463b6; stroke-width: 2; }
.kg-binding-edge { stroke: #4b8a72; stroke-width: 1.3; stroke-dasharray: 3 5; }
.kg-declaration-dot { width:10px; height:10px; border-radius:50%; background:#e4efff; border:2px solid #2463b6; flex-shrink:0; }
.kg-binding-swatch { width:20px; height:0; border-top:2px dashed #4b8a72; margin-left:10px; flex-shrink:0; }

/* Content-first inspector: title, actions, natural language, exact Lean versions. */
.kg-view-label select,.kg-depth-label select{min-height:30px;max-width:150px;border:1px solid var(--line);border-radius:6px;background:#fff;padding:5px 8px;color:var(--ink)}
.kg-other-label{display:flex;align-items:center;gap:5px;white-space:nowrap;font-size:12px;color:var(--muted)}
.kg-tools{flex-wrap:wrap;gap:8px 14px}.kg-legend{flex:1}
.kg-entry-links{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;margin:14px 0 22px}
.kg-entry-links>a,.kg-entry-links>button{display:flex;align-items:center;justify-content:center;min-width:0;min-height:36px;margin:0;padding:8px 10px;border:1px solid var(--line);border-radius:6px;background:#fff;color:#315b7d;text-align:center;text-decoration:none;font-size:12px;line-height:1.4}
.kg-entry-links>a:hover{border-color:#315b7d;background:#f2f7fb}
.kg-natural-section .kg-statement-body{max-height:none;padding:0 0 18px;margin:8px 0 18px;font-size:14px;line-height:1.8}
.kg-formal-version{margin:12px 0 20px}.kg-declaration-name{display:block;font-size:11px;color:#506377;overflow-wrap:anywhere;margin-bottom:8px}
.kg-support-label{display:block;color:var(--muted);font-size:11px;margin:4px 0 8px}
.kg-formal-version pre{margin:0;padding:14px;max-height:380px;overflow:auto;background:#f3f6fa;border:1px solid #e3e9f0;border-radius:7px;white-space:pre;font:12px/1.7 ui-monospace,SFMono-Regular,Consolas,monospace;color:#24364a}
.kg-empty-formal{font-size:13px;color:var(--muted)}.kg-edge-endpoint+.kg-edge-endpoint{margin-top:28px;padding-top:24px;border-top:1px solid var(--line)}
.kg-natural-section[hidden]{display:none}
.kg-formal-version+.kg-formal-version{padding-top:20px;border-top:1px solid var(--line)}
.kg-source-natural-section .kg-statement-body{padding:0;margin:8px 0 18px;border:0;line-height:1.8}
.kg-formal-version h5{font-size:12px;color:#506377;margin:14px 0 8px}
.kg-formal-version .kg-entry-links{margin:10px 0 16px}

/* October 19: one compact toolbar leaves the viewport to the graph. */
.kg-header{flex-wrap:wrap;gap:8px 14px;padding:8px 16px;min-height:48px}.kg-header .kg-heading{flex:1 1 220px;gap:10px}.kg-header h1{font-size:17px}.kg-header p{max-width:260px}.kg-header .kg-tools{padding:0;flex:0 1 auto;gap:6px 10px;align-items:center}.kg-tools>div:last-child{display:flex;flex-wrap:wrap;gap:4px}.kg-tools button{padding:4px 7px;min-height:28px;font-size:11px}.kg-view-label select,.kg-depth-label select{font-size:11px;padding:4px 6px;min-height:28px}.kg-other-label{font-size:11px}.kg-back{min-height:28px;font-size:11px;padding:4px 0}.kg-legend-disclosure{position:relative;font-size:11px;color:var(--muted)}.kg-legend-disclosure>summary{cursor:pointer;padding:5px 0;white-space:nowrap}.kg-legend-disclosure .kg-legend{position:absolute;z-index:12;top:100%;right:0;width:290px;max-width:calc(100vw - 32px);padding:12px;background:#fff;border:1px solid var(--line);border-radius:6px;box-shadow:0 6px 20px #18212f18;gap:8px;font-size:11px}.kg-workspace{flex:1;min-height:0}.kg-sidebar{padding:12px 14px}.kg-sidebar-pagination{margin-bottom:10px;padding-bottom:8px}.kg-entry-links{display:flex;flex-wrap:wrap;gap:4px 12px;margin:8px 0 12px}.kg-entry-links>a,.kg-entry-links>button{display:inline-flex;width:auto;min-height:24px;padding:2px 0;border:0;border-radius:0;background:transparent;font-size:11px;line-height:1.5}.kg-entry-links>a:hover{background:transparent;text-decoration:underline}#kg-detail h3{margin:6px 0 10px;font-size:19px}.kg-natural-section .kg-statement-body{margin:6px 0 12px;padding-bottom:12px}.kg-page .kg-loading-actions:has(button:not([hidden])){padding:4px 16px}.kg-page [hidden]{display:none!important}
@media(max-width:1100px){.kg-header .kg-heading{flex-basis:calc(100% - 80px)}.kg-header .kg-tools{order:3;flex-basis:100%;justify-content:flex-start}.kg-header .kg-back{margin-left:auto}.kg-header p{max-width:none}}
@media(max-width:760px){.kg-header{padding:8px 12px}.kg-header .kg-heading{min-width:0;flex-basis:calc(100% - 60px);flex-wrap:nowrap}.kg-header h1{font-size:16px}.kg-header p{min-width:0;font-size:11px;flex-basis:auto}.kg-header .kg-tools{gap:5px 8px;align-items:center}.kg-tools>div:last-child{flex-wrap:wrap}.kg-canvas-wrap{height:max(330px,48dvh)}.kg-sidebar{padding:12px}.kg-entry-links{gap:4px 14px}.kg-legend-disclosure .kg-legend{left:0;right:auto}.kg-masthead{grid-template-columns:auto minmax(0,1fr);display:grid;min-height:44px;padding:10px 12px}.kg-masthead nav{justify-content:flex-end}}

.kg-source-badges{display:flex;flex-wrap:wrap;gap:5px;margin:0 0 6px}.kg-source-badges:empty{display:none}
.kg-legend-disclosure .kg-legend{display:grid;grid-template-columns:minmax(0,1fr);gap:10px}
.kg-legend-item{display:flex;align-items:center;gap:10px;white-space:nowrap;min-width:0}
.kg-legend-item>span{flex:0 0 24px;margin:0}
.kg-legend-item>.kg-seed-dot,.kg-legend-item>.kg-neighbor-dot{flex-basis:10px;margin-right:14px}
@media(max-width:760px){.kg-legend-disclosure .kg-legend{position:fixed;top:auto;left:auto;right:12px;width:min(290px,calc(100vw - 24px));max-width:none}}

/* The graph shares Atlas masthead styles; only the workspace is graph-specific. */
.kg-page-body .kg-site-frame { display:flex; flex-direction:column; flex:1; min-height:0; height:100%; overflow:hidden; }
.kg-site-frame > .masthead { flex-shrink:0; }
.kg-site-frame > .masthead [hidden] { display:none!important; }
.kg-detail-heading { display:flex; flex-wrap:wrap; align-items:baseline; gap:6px 9px; margin:6px 0 10px; }
#kg-detail .kg-detail-heading h3 { margin:0; min-width:0; }
.kg-detail-heading .kg-source-badges { display:inline-flex; align-items:center; gap:5px; margin:0; }

/* The inspector has the same draggable boundary as the Atlas reading panes. */
.kg-atlas-view { color:var(--muted); font-size:11px; white-space:nowrap; }
.kg-workspace.kg-resizable { grid-template-columns:minmax(0,1fr) 7px minmax(0,var(--kg-sidebar-width,370px)); }
.kg-resizable .kg-sidebar { min-width:0; border-left:0; }
.kg-resizer { position:relative; min-width:7px; cursor:col-resize; touch-action:none; background:transparent; border-inline:1px solid var(--line); }
.kg-resizer::after { content:""; position:absolute; top:calc(50% - 20px); left:2px; width:1px; height:40px; background:#a9b9cf; }
.kg-resizer:hover,.kg-resizer.dragging,.kg-resizer:focus-visible { background:#e6eefb; }
.kg-resizer:focus-visible { outline:2px solid var(--accent); outline-offset:-2px; }
.kg-resizing,.kg-resizing * { cursor:col-resize!important; user-select:none!important; }
@media(max-width:760px) { .kg-workspace.kg-resizable { display:flex; flex-direction:column; } .kg-resizer { display:none; } }

.kg-header>.kg-back-link{display:inline-flex;align-items:center;justify-content:flex-end;flex:0 0 auto;min-height:28px;margin-left:auto;padding:4px 0;color:#315b7d;font-size:11px;text-decoration:none;white-space:nowrap}.kg-header>.kg-back-link:hover{text-decoration:underline;text-underline-offset:3px}.kg-header>.kg-back-link:focus-visible{outline:2px solid #315b7d;outline-offset:4px}
@media(max-width:1100px){.kg-header .kg-heading{flex-basis:calc(100% - 126px)}}
