:root{--paper:#1e1e24;--white:#24242c;--surface:#292932;--ink:#e8e6ee;--muted:#94929e;--green:#a78bfa;--line:#383842;--gold:#c7a365;--teal:#48b7b0;--blue:#6898ed;--serif:-apple-system,BlinkMacSystemFont,'Segoe UI',sans-serif;--sans:-apple-system,BlinkMacSystemFont,'Segoe UI',sans-serif;font-family:var(--sans);color:var(--ink);font-size:14px;color-scheme:dark}*{box-sizing:border-box}body{margin:0;overflow:hidden;background:var(--paper)}button,input,a{font:inherit}button,a{-webkit-tap-highlight-color:transparent}button{cursor:pointer;color:inherit;background:none;border:0}button:disabled{cursor:default;opacity:.35}a{color:inherit;text-decoration:none}button:focus-visible,a:focus-visible,input:focus-visible{outline:2px solid var(--green);outline-offset:4px}[hidden]{display:none!important}svg{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:1.6;stroke-linecap:round;stroke-linejoin:round;flex-shrink:0}h1,h2,h3,p{margin:0}button,a,input{transition:background-color .15s,border-color .15s,color .15s}::selection{background:#a78bfa44}::-webkit-scrollbar{width:6px;height:6px}::-webkit-scrollbar-thumb{background:#494753;border-radius:5px}::-webkit-scrollbar-track{background:transparent}
.header{height:64px;background:#292932;border-bottom:1px solid var(--line);display:flex;align-items:center;padding:0 26px;gap:24px;position:relative;z-index:20}.brand{display:flex;align-items:center;gap:16px;white-space:nowrap;font-size:21px;font-weight:600;letter-spacing:-.4px}.brand-icon{width:34px;height:34px;color:var(--green);stroke-width:1.1}.brand-icon circle{fill:var(--green);stroke:#24242c;stroke-width:1.5}.brand-subtitle{font-size:13px;color:#a6a3b0;font-weight:400}.header nav{margin-left:auto;height:100%;display:flex;gap:20px;align-items:stretch}.nav-button{font-size:14px;position:relative;min-width:65px;padding:0 10px;color:#ada9ba}.nav-button:hover{color:#f0ebff}.nav-button.active{color:#ba9cff}.nav-button.active:after{position:absolute;content:'';height:3px;bottom:10px;left:0;right:0;background:var(--green);border-radius:2px}
.shell{display:flex;height:calc(100dvh - 64px)}.sidebar{width:264px;flex:0 0 264px;background:var(--white);border-right:1px solid var(--line);padding:25px 22px 24px;display:flex;flex-direction:column;gap:24px;z-index:15;overflow-y:auto}.sidebar h1{font-size:14px;font-weight:500;color:#c3bece;line-height:1.4}.search-wrap{position:relative;margin-top:-13px}.search{height:41px;border:1px solid #41404b;border-radius:6px;display:flex;align-items:center;padding:0 10px;gap:10px;background:#25252e;color:#a7a0bd}.search input{min-width:0;width:100%;border:0;outline:none;background:none;font-size:13px;color:var(--ink)}.search input::placeholder{color:#95909f}.search input:focus-visible{outline:0}.search:focus-within{border-color:#9873df;box-shadow:0 0 0 2px #a78bfa12}.search button{font-size:22px;color:var(--muted);padding:0}.search-results{background:#2d2b37;border:1px solid #50455f;border-radius:6px;margin-top:7px;box-shadow:0 8px 28px #0006;position:absolute;max-height:340px;overflow:auto;width:100%;z-index:40}.search-results button{display:block;text-align:left;width:100%;padding:12px 13px;border-bottom:1px solid #3b3546;font-size:13px;line-height:1.45}.search-results button:hover{background:#413551}.search-results small{display:block;color:#aaa1bc;font-size:10px;margin-top:4px}.search-results p{padding:14px;font-size:12px;color:var(--muted)}
.branches{border:0;margin:1px -10px 0;padding:0}.branches legend{font-size:13px;color:#a9a3b6;margin-bottom:12px;padding:0 10px}.branches label{display:flex;align-items:center;gap:13px;min-height:37px;font-size:13px;cursor:pointer;white-space:nowrap;padding:0 10px;border-radius:5px;position:relative}.branches label:has(input:checked){background:#a78bfa23;color:#f0e9ff}.branches label:has(input:checked):before{content:'';position:absolute;width:2px;left:0;top:7px;bottom:7px;border-radius:2px;background:#b399f3}.branches label:hover{background:#ffffff06}.branches input{appearance:none;width:13px;height:13px;flex-shrink:0;border-radius:50%;border:0;margin:0;background:#9892a9;cursor:pointer}.branches input[value='all'],.branches input[value='5']{background:var(--green)}.branches input[value='4']{background:var(--teal)}.branches input[value='3']{background:var(--blue)}.branches input:checked{box-shadow:0 0 9px #a78bfa22}
.motion-controls{border-top:1px solid var(--line);margin-top:23px;padding-top:28px}.motion-controls h2{font-size:13px;font-weight:400;color:#bbb5c9;margin-bottom:12px}.motion-controls .outline-button{min-width:122px;justify-content:flex-start;padding-left:13px}.motion-controls .outline-button svg{color:#c4b1f5;width:17px;height:17px;stroke-width:2.7}.tree-settings{font-size:12px;color:#aaa4b6;margin-top:1px}.tree-settings label{display:flex;justify-content:space-between;align-items:center}.tree-settings output{font-variant-numeric:tabular-nums;color:#b6accb}.tree-settings input{accent-color:var(--green);width:100%;margin:15px 0 14px;height:4px;cursor:pointer}.text-button{font-size:11px;color:#aaa0bd;text-decoration:none;padding:0}.text-button:hover{color:#c9afff}.sidebar-bottom{margin-top:auto;border-top:1px solid var(--line);padding-top:21px}.source-note{display:flex;align-items:center;gap:9px;padding:0;color:#aaa3b8;font-size:12px}.source-note svg{width:16px;height:16px;color:#9e95ae}.source-note:hover{color:#d7c3ff}.dataset-summary{font-size:11px;line-height:1.6;color:#888291;margin-top:8px;font-variant-numeric:tabular-nums}
main{position:relative;min-width:0;flex:1}.view{position:absolute;inset:0}.tree-view{background:var(--paper)}.canvas-heading{position:absolute;z-index:3;left:22px;top:19px;pointer-events:none}.canvas-heading h2{font-size:20px;line-height:1.35;font-weight:500;letter-spacing:-.2px}.canvas-heading p{font-size:12px;color:#93909f;margin-top:5px;font-variant-numeric:tabular-nums}.tree-view:before{content:'';position:absolute;inset:0 0 auto;height:78px;z-index:2;pointer-events:none;background:var(--paper)}.outline-button{border:1px solid #41404c;border-radius:6px;background:#292932;padding:10px 13px;display:inline-flex;align-items:center;justify-content:center;gap:10px;font-size:12px;white-space:nowrap;box-shadow:0 2px 5px #0000000c}.outline-button:hover{background:#34303f;border-color:#75628e;color:#e8d9ff}.entire-tree{position:absolute;right:22px;top:17px;z-index:4;min-height:38px}.entire-tree svg{width:17px;height:17px;color:#bdb0d3}.has-details .entire-tree{right:348px}
.viewport{position:absolute;inset:0;overflow:hidden;touch-action:none;cursor:grab;outline:none;--graph-scale:1;--label-scale:1}.viewport.dragging{cursor:grabbing}.world{position:absolute;transform-origin:0 0;will-change:transform}.world>svg{position:absolute;overflow:visible;width:1px;height:1px;pointer-events:none}.world path{fill:none;stroke:var(--link-color,#5f596f);stroke-width:.8;stroke-opacity:.77;vector-effect:non-scaling-stroke;transition:stroke-opacity .22s,stroke .22s}.world path.ancestry,.world path.nearby,.world path.highlighted{stroke:#b397ed;stroke-width:1.25;stroke-opacity:.92}.world path.dimmed{stroke-opacity:.09}.node{position:absolute;width:calc(28px / var(--graph-scale));height:calc(28px / var(--graph-scale));padding:0;border:0;background:transparent;border-radius:50%;transform:translate(-50%,-50%);display:grid;place-items:center;isolation:isolate;cursor:grab;color:var(--node-color,#a6a1b6)}.node:active{cursor:grabbing}.node-dot{width:calc(var(--node-size,7px) / var(--graph-scale));height:calc(var(--node-size,7px) / var(--graph-scale));border-radius:50%;background:var(--node-color,#a6a1b6);display:block;transition:box-shadow .25s,opacity .25s;position:relative}.node:hover .node-dot,.node.hovered .node-dot,.node.nearby .node-dot{box-shadow:0 0 11px color-mix(in srgb,var(--node-color,#a78bfa) 38%,transparent)}.node.selected{z-index:6}.node.selected .node-dot{background:#c3a5ff;box-shadow:0 0 14px #a78bfa70}.node.selected .node-dot:after{content:'';position:absolute;inset:calc(-6px / var(--graph-scale));border:calc(1.5px / var(--graph-scale)) solid #b991ff;border-radius:50%;animation:selected-ring 3.5s ease-in-out infinite}.node.selected .node-label,.node:hover .node-label,.node.nearby .node-label{color:#f1e9ff;opacity:1}.node.dimmed .node-dot{opacity:.19}.node.dimmed .node-label{opacity:.15}.node-label{position:absolute;left:calc(30px / var(--graph-scale));top:50%;transform:translateY(-50%) scale(var(--label-scale));transform-origin:left center;display:flex;flex-direction:column;align-items:flex-start;gap:1px;white-space:nowrap;pointer-events:none;font-size:12px;line-height:1.2;color:#d7d1e3;opacity:.88;max-width:none;text-shadow:0 1px 3px #1e1e24,1px 0 3px #1e1e24,-1px 0 3px #1e1e24;transition:opacity .2s}.node-name{font-size:13px;font-weight:500;line-height:1.25;letter-spacing:0}.node-patronymic{font-size:11px;line-height:1.25;font-weight:400;color:inherit}.node-meta{display:none;font-size:9px;color:#a69ab9;line-height:1.4}.node:hover .node-meta,.node.selected .node-meta{display:block}.node.label-hidden .node-label,.node-label.label-hidden{visibility:hidden}.node:hover .node-label,.node.selected .node-label,.node:focus-visible .node-label{visibility:visible!important;z-index:10}.node.uncertain .node-dot{outline:calc(.65px / var(--graph-scale)) solid #c7a36588;outline-offset:calc(2px / var(--graph-scale))}.viewport.motion-paused *{animation-play-state:paused!important}.viewport.labels-hidden .node:not(.priority):not(.selected):not(.nearby):not(:hover) .node-label{visibility:hidden}.viewport.labels-compact .node-label{opacity:.78}.viewport.labels-compact .node.selected .node-label,.viewport.labels-compact .node.nearby .node-label{opacity:1}@keyframes selected-ring{0%,100%{opacity:.8}50%{opacity:.35}}
.canvas-footer{position:absolute;bottom:23px;left:22px;right:22px;display:flex;justify-content:space-between;pointer-events:none;gap:15px}.legend{display:flex;gap:18px;font-size:11px;color:#a8a0ba;align-items:center}.legend span{display:flex;align-items:center;gap:7px;white-space:nowrap}.legend i{width:11px;height:11px;border-radius:50%}.branch-adrian{background:var(--teal)}.branch-boris{background:var(--green)}.branch-fedor{background:var(--blue)}.pan-hint{font-size:11px;color:#7e778e;align-self:flex-end}.zoom-controls{position:absolute;z-index:4;bottom:20px;left:50%;transform:translateX(-50%);display:flex;align-items:center;height:41px;gap:0;background:#292932;border:1px solid #41404d;border-radius:6px;box-shadow:0 4px 20px #0002}.zoom-controls button{height:39px;min-width:40px;font-size:25px;font-weight:300;color:#c8b6eb}.zoom-controls button:hover{background:#3b334c}.zoom-controls output{font-size:12px;width:48px;text-align:center;color:#b4a6cc;font-variant-numeric:tabular-nums}.zoom-controls .fit-button{display:flex;align-items:center;gap:8px;border-left:1px solid #41404d;margin-left:0;padding:0 11px;font-size:12px;color:#a99dbd}.fit-button svg{width:17px;height:17px;color:#b3a6ce}.fit-button span{display:none}.has-details .zoom-controls{left:calc((100% - 342px)/2)}.has-details .canvas-footer{right:348px}.has-details .pan-hint{display:none}
.details{position:absolute;right:16px;top:22px;max-height:calc(100% - 44px);width:310px;background:#24242c;z-index:10;box-shadow:0 8px 30px #0002;border:1px solid #3c3946;border-radius:6px;overflow:auto;padding:27px 20px 24px;animation:panel-in .22s ease-out}.detail-close{position:absolute;right:12px;top:12px;font-size:25px;font-weight:300;color:#a99db9;width:30px;height:30px;border-radius:4px}.detail-close:hover{background:#ffffff09;color:#eee}.detail-number{font-size:11px;color:#91899f;margin:12px 0 16px}.details h2{font-size:23px;font-weight:500;line-height:1.25;letter-spacing:-.3px;padding-right:12px;color:#e8dfef}.details h2:before{content:'';display:inline-block;width:12px;height:12px;background:#ae8ce9;border-radius:50%;margin-right:10px;vertical-align:2px}.detail-dates{font-size:13px;color:#bba5d4;margin-top:11px}.detail-generation{font-size:12px;color:#a39bad;margin:12px 0 21px}.detail-section{margin:23px 0;border-top:1px solid #393541;padding-top:20px}.detail-section h3{font-size:11px;letter-spacing:.2px;font-weight:400;color:#9f96ad;margin-bottom:12px;text-transform:none}.detail-section p{font-size:13px;line-height:1.7;color:#b5adbf;white-space:pre-line}.detail-section .related{display:block;padding:7px 0;text-align:left;font-size:13px;line-height:1.45;color:#b69adb;text-decoration:underline;text-underline-offset:3px}.detail-section .related:hover{color:#d1b6f9}.detail-section .related:before{content:'';display:inline-block;width:8px;height:8px;border-radius:50%;background:#a78bfa;margin-right:10px;vertical-align:1px}.uncertainty{padding:12px 13px;background:#b7913710;border:1px solid #a8823133;border-radius:4px;font-size:11px;line-height:1.7;color:#c4af83}.uncertainty strong{font-weight:500;color:#d1b888}.source-crop{display:block;width:100%;padding:0;border:1px solid #554d5a;border-radius:4px;overflow:hidden;margin-top:8px;background:#e9e6dd}.source-crop img{width:100%;display:block}.crop-caption{font-size:10px!important;color:#a196ae!important;line-height:1.6!important;margin-top:10px}.detail-actions{display:flex;gap:10px;margin-top:22px}.details .detail-source{width:100%;margin-top:14px;font-size:11px}.reveal-descendants{width:100%;font-size:11px}.details .detail-section:last-of-type{margin-bottom:17px}@keyframes panel-in{from{opacity:0;transform:translateX(9px)}to{opacity:1;transform:translateX(0)}}
.people-view{background:var(--paper);overflow:auto;padding:31px 36px}.page-heading{display:flex;justify-content:space-between;gap:20px;align-items:flex-start;margin-bottom:24px}.page-heading h2,.source-toolbar h2{font-size:24px;font-weight:500;letter-spacing:-.3px}.page-heading p,.source-toolbar p{color:var(--muted);font-size:12px;line-height:1.5;margin-top:7px}.people-filter{font-size:12px;color:#a49aaf;display:flex;align-items:center;gap:9px;margin-bottom:24px;cursor:pointer}.people-filter input{accent-color:var(--green)}.people-list{border-top:1px solid #38323f}.person-row{width:100%;display:grid;grid-template-columns:48px 1fr 160px 100px;align-items:center;gap:18px;padding:18px 4px;border-bottom:1px solid #302b36;text-align:left}.person-row:hover{background:#a78bfa09}.person-row .person-id{font-size:11px;color:#7a6f8c}.person-row strong{font-size:15px;font-weight:400;color:#d4c9e1}.person-row small{display:block;color:#b39a6c;font-size:10px;margin-top:6px}.person-row .person-dates{font-size:12px;color:#a695b6}.person-row .person-gen{font-size:10px;color:#a093ad;text-align:right}.empty{font-size:14px;padding:35px;color:var(--muted)}
.source-view{background:#19191f;display:flex;flex-direction:column}.source-toolbar{padding:23px 27px;display:flex;align-items:center;justify-content:space-between;gap:20px;background:#24242c;border-bottom:1px solid var(--line)}.source-toolbar>div:last-child{display:flex;gap:8px}.source-toolbar h2{font-size:22px}.source-toolbar p{font-size:12px}.source-scroll{overflow:auto;flex:1;padding:28px}.source-sheet{width:min(100%,1100px);position:relative;margin:0 auto;box-shadow:0 5px 28px #0003}.source-sheet.zoomed{width:1800px;max-width:none;margin:0}.source-sheet img{width:100%;height:auto;display:block}.source-sheet #source-marker{position:absolute;width:18%;height:1.2%;border:3px solid #9063cf;background:#a78bfa26;border-radius:5px;pointer-events:none;transform:translate(-50%,-50%)}.loading{position:fixed;inset:64px 0 0 264px;z-index:12;display:grid;place-items:center;background:var(--paper);font-size:20px;color:#a28cbf}.menu,.sidebar-backdrop{display:none}.icon-button{padding:0;width:28px;height:32px;color:#bda7df}
@media(max-width:1200px){.header{padding:0 22px;gap:20px}.sidebar{width:244px;flex-basis:244px;padding:23px 20px}.pan-hint{display:none}.legend{font-size:10px;gap:13px}.details{width:300px;right:12px}.has-details .entire-tree{right:328px}.has-details .zoom-controls{left:calc((100% - 324px)/2)}.has-details .canvas-footer{right:328px}.loading{left:244px}}
@media(max-width:900px){.header{padding:0 18px;gap:14px}.brand{font-size:19px;gap:11px}.brand-icon{width:29px;height:29px}.brand-subtitle{display:none}.header nav{gap:7px}.nav-button{font-size:13px;min-width:62px}.sidebar{width:224px;flex-basis:224px;padding:22px 18px}.branches label{font-size:12px;gap:10px}.canvas-heading{left:18px}.canvas-heading h2{font-size:19px}.entire-tree{right:16px;font-size:11px;padding:9px 10px}.legend{display:none}.motion-controls{margin-top:7px;padding-top:22px}.people-view{padding:26px 24px}.person-row{grid-template-columns:36px 1fr;gap:12px}.person-row .person-dates{grid-column:2}.person-gen{display:none}.source-toolbar{align-items:flex-start;flex-direction:column;padding:20px}.source-toolbar h2{font-size:22px}.loading{left:224px}.details{width:280px}.has-details .entire-tree{display:none}.has-details .zoom-controls{left:calc((100% - 304px)/2)}}
@media(max-width:680px){.header{padding:0 12px;gap:10px;height:60px}.shell{height:calc(100dvh - 60px)}.menu{display:block}.brand{font-size:18px;gap:0}.brand-icon{display:none}.header nav{gap:0}.nav-button{min-width:53px;padding:0 7px;font-size:12px}.nav-button.active:after{bottom:9px}.sidebar{position:fixed;top:60px;left:0;bottom:0;width:274px;transform:translateX(-100%);transition:transform .2s;box-shadow:10px 0 40px #0005;padding:25px 22px}.sidebar.open{transform:translateX(0)}.sidebar-backdrop.open{display:block;position:fixed;inset:60px 0 0;background:#0007;border:0;z-index:14}.sidebar h1{font-size:14px}.branches label{font-size:13px}.motion-controls{margin-top:18px}.canvas-heading{top:18px;left:17px;max-width:calc(100% - 128px)}.canvas-heading h2{font-size:19px;line-height:1.3}.canvas-heading p{font-size:10px;margin-top:7px}.tree-view:before{height:82px}.entire-tree{top:18px;right:14px;gap:7px;font-size:11px;padding:9px 10px}.entire-tree svg{width:14px;height:14px}.zoom-controls,.has-details .zoom-controls{bottom:25px;left:50%;right:auto;transform:translateX(-50%);white-space:nowrap}.zoom-controls .fit-button{padding:0 13px}.zoom-controls output{width:52px}.canvas-footer{display:none}.details{width:100%;right:0;top:auto;bottom:0;max-height:83%;border-radius:12px 12px 0 0;padding:27px 23px;box-shadow:0 -15px 50px #0005;animation:sheet-in .2s ease-out}.detail-close{top:12px;right:15px}.details h2{font-size:23px;padding-right:22px}.detail-section p{font-size:14px}.detail-section .related{font-size:14px}.detail-number{margin-top:12px}.detail-source{min-height:40px}.people-view{padding:25px 20px}.page-heading{align-items:center;gap:8px}.page-heading h2{font-size:23px}.page-heading .outline-button{font-size:10px;padding:9px}.person-row strong{font-size:14px}.source-scroll{padding:12px}.source-toolbar>div:last-child{gap:5px}.source-toolbar .outline-button{font-size:12px;padding:8px 10px}.loading{inset:60px 0 0}.has-details .zoom-controls{visibility:hidden}.has-details .entire-tree{display:inline-flex}.node-name{font-size:12px}.node-patronymic{font-size:10px}@keyframes sheet-in{from{opacity:0;transform:translateY(12px)}to{opacity:1;transform:translateY(0)}}}
@media(prefers-reduced-motion:reduce){*{transition:none!important;scroll-behavior:auto!important;animation:none!important}}

.brand-copy{display:flex;flex-direction:column;gap:3px;line-height:1.2}.brand-copy strong{font:inherit}.brand-copy small{font-size:12px;font-weight:400;letter-spacing:0;color:#a09aab}@media(max-width:680px){.brand-copy small{display:none}}

.node.label-left .node-label{left:auto;right:calc(30px / var(--graph-scale));transform-origin:right center;align-items:flex-end;text-align:right}

@media(max-width:680px){.has-details .entire-tree{right:14px;top:18px}}

/* Published evidence stays distinct from the handwritten transcription. */
.detail-sources ol{list-style:none;margin:0;padding:0}.detail-sources li+li{margin-top:18px}.detail-sources a{font-size:12px;line-height:1.6;color:#c3a5ee;text-decoration:underline;text-underline-offset:3px;overflow-wrap:anywhere}.detail-sources a:hover{color:#e0ccff}.detail-sources a:focus-visible{outline:2px solid #b991ff;outline-offset:4px;border-radius:2px}.detail-sources li p{font-size:11px;line-height:1.65;color:#9f96ad;margin-top:5px}.source-conflicts{padding:13px;margin:0 0 22px;background:#b7913710;border:1px solid #a8823144;border-radius:4px}.source-conflicts h3{font-size:11px;font-weight:500;color:#d1b888;margin-bottom:7px}.source-conflicts p{font-size:11px;line-height:1.7;color:#c4af91}.source-conflicts p+p{margin-top:9px}.person-row .person-provenance{color:#9e8ab8}.world path.kinship{stroke-dasharray:3 4;stroke-opacity:.8}.world path.kinship.dimmed{stroke-opacity:.09}
