:root { --rust:#934526; --teal:#175d61; --muted:#566863; --paper:#fcfbf7; --map-paper:#f8f6f0; --rule:#c8cfc4; --pale:#e9f0e9; }
body { background:var(--paper); }
[hidden] { display:none !important; }
.shell { max-width:1450px; margin:auto; padding:0 clamp(20px,4.5vw,72px); }
.masthead { min-height:65px; font-size:13px; }
.masthead a,.byline a { color:var(--ink); text-decoration:none; }
.masthead a:hover,footer a:hover { text-decoration:underline; }
.byline { display:flex; align-items:baseline; gap:15px; }
.byline span { color:#989e8e; }
.byline .wordmark { font-size:23px; }
.intro-row { display:flex; align-items:center; justify-content:space-between; gap:35px; padding:31px 0 27px; }
h1 { font:400 clamp(48px,5.6vw,82px)/1.05 var(--serif); letter-spacing:-.058em; }
h1 em { color:var(--teal); font-weight:400; }
.intro-row p { font:16px/1.55 system-ui,sans-serif; color:var(--body); max-width:47ch; }
button,input,select { font:inherit; color:inherit; }
button { cursor:pointer; }
button:disabled { cursor:default; opacity:.55; }
button:hover:not(:disabled),.reader a:hover { color:var(--rust); }
.controls { display:grid; grid-template-columns:1fr 1fr; gap:clamp(16px,2.4vw,36px); padding:15px 0 20px; border-top:1px solid var(--ink); }
.controls>div { min-width:0; }
.controls label,.section-label { font-size:12px; font-weight:650; letter-spacing:.035em; }
.controls label { display:inline-block; }
.label-row { display:flex; align-items:baseline; justify-content:space-between; gap:8px; }
.example,.result-head button { border:0; background:transparent; color:var(--teal); font:13px/1.3 system-ui,sans-serif; padding:0; text-decoration:underline; text-underline-offset:3px; }
select,.search-field { display:block; width:100%; height:43px; margin-top:6px; border:1px solid #adb7a9; border-radius:3px; background:#fffef9; }
select { overflow:hidden; text-overflow:ellipsis; padding:0 30px 0 13px; font:15px system-ui,sans-serif; }
.search-field { position:relative; }
.search-field input { border:none; background:transparent; width:100%; height:100%; padding:0 11px 0 38px; font-size:15px; }
.search-field i { position:absolute; left:14px; top:12px; width:13px; height:13px; border:1.7px solid #50655c; border-radius:50%; pointer-events:none; }
.search-field i:after { content:""; position:absolute; width:7px; height:1.7px; background:#50655c; transform:rotate(47deg); top:11px; left:9px; }
.study { display:grid; grid-template-columns:minmax(0,1.64fr) minmax(0,1fr); border:1px solid var(--rule); border-radius:5px; overflow:hidden; }
figure { margin:0; min-width:0; display:flex; flex-direction:column; background:var(--map-paper); }
.map-head,.result-head,.neighbors header { display:flex; align-items:center; justify-content:space-between; gap:12px; }
.map-head { padding:16px 21px 0; }
.map-head>div:first-child { display:flex; flex-wrap:wrap; align-items:baseline; gap:5px 12px; }
.map-head h2 { font:500 clamp(19px,1.8vw,25px)/1.1 var(--serif); letter-spacing:-.025em; }
#map-count,.map-tip,#neighbor-caption { font-size:12px; color:var(--muted); }
.zoom { display:flex; border:1px solid #b6bdaf; border-radius:3px; overflow:hidden; }
.zoom button { border:0; padding:4px 9px; min-width:30px; background:transparent; font-size:14px; }
.zoom button+button { border-left:1px solid #c7ccbf; }
#map { position:relative; flex:1; min-height:240px; display:grid; align-items:center; overflow:hidden; }
#map svg { display:block; width:100%; height:100%; min-height:240px; max-height:min(46vw,535px); }
#map circle[data-key] { cursor:pointer; }
#map circle[data-key]:hover { stroke:#132f37; stroke-width:2px; }
#map .overlay { pointer-events:none; }
#map .bridge { stroke:var(--rust); stroke-width:1.5; stroke-dasharray:4 3; fill:none; }
#map .seed-marker,#map .neighbor-marker { stroke:#fffdf7; stroke-width:2; stroke-linejoin:round; }
#map .seed-marker { fill:var(--start-mark); }
#map .neighbor-marker { fill:var(--neighbor-mark); }
#map .match-marker { fill:none; stroke:var(--neighbor-mark); stroke-width:1.6; }
#map .match-marker,#map .neighbor-marker,#map .seed-marker { pointer-events:all; cursor:pointer; }
.paper-tooltip { position:absolute; z-index:20; width:max-content; max-width:min(23rem,calc(100vw - 14px)); padding:10px 13px; border:1px solid #899b90; border-radius:4px; box-shadow:0 3px 14px #203b3226; background:#fffefa; color:#24382f; pointer-events:none; overflow-wrap:anywhere; }
.paper-tooltip strong,.paper-tooltip span { display:block; }
.paper-tooltip strong { font:600 16px/1.25 var(--serif); }
.paper-tooltip span { font:13px/1.4 system-ui,sans-serif; margin-top:4px; }
.paper-tooltip .tip-publication { color:var(--muted); }
#map .seed-center { fill:white; }
:root { --start-mark:#114d72; --neighbor-mark:#ae430c; }
.map-method { flex-basis:100%; font-size:13px; color:var(--muted); }
figcaption { padding:10px 20px 12px; font-size:12px; color:#344b47; }
.selection-key { display:flex; align-items:center; flex-wrap:wrap; gap:8px 19px; font-weight:650; }
.selection-key span,.section-label { display:inline-flex; gap:7px; align-items:center; }
.map-tip { margin:7px 0 0; line-height:1.45; }
.key-dot { display:inline-block; flex:none; width:13px; height:13px; }
.start-dot { border-radius:50%; background:radial-gradient(circle,#fff 0 18%,var(--start-mark) 23%); }
.neighbor-dot { width:10px; height:10px; margin:1.5px; transform:rotate(45deg); background:var(--neighbor-mark); }
.match-dot { width:12px; height:12px; border-radius:50%; border:2px solid var(--neighbor-mark); }
.match-rank,.pair-ranks,.reference-frequency { font-size:12px; color:var(--muted); }
.match-rank { display:inline-block; margin-left:12px; }
.pair-ranks { display:grid; gap:4px; width:fit-content; margin:10px 0; }
.pair-ranks div { display:flex; align-items:baseline; justify-content:space-between; gap:16px; }
.pair-ranks dd { margin:0; color:var(--ink); font-weight:600; font-variant-numeric:tabular-nums; }
.reference-frequency { display:block; }
.reader { border-left:1px solid var(--rule); padding:22px clamp(17px,2vw,32px); background:#fffefa; }
.section-label { color:var(--teal); }
.paper-head h2,.neighbor-title { font:500 clamp(22px,2.1vw,31px)/1.14 var(--serif); letter-spacing:-.032em; overflow-wrap:break-word; }
.citation { font-size:13px; color:var(--muted); margin:9px 0 4px; }
.paper-head>a,.sources a,.switch { font-size:13px; }
.paper-head>a { display:inline-block; margin-top:7px; }
#comparison { border-top:1px solid var(--rule); padding-top:15px; margin-top:16px; }
#comparison .section-label { color:var(--rust); }
#comparison h3 { margin:6px 0; font:500 clamp(18px,1.65vw,23px)/1.18 var(--serif); letter-spacing:-.02em; }
#comparison .why { font-size:14px; line-height:1.52; color:#344b47; margin:8px 0; }
.sources { display:flex; flex-wrap:wrap; column-gap:15px; row-gap:5px; }
.switch { margin-top:13px; border:0; padding:0; background:none; color:var(--teal); font-weight:650; }
.neighbors { margin:30px 0; }
.neighbors h2,.result-head h2 { font:400 clamp(28px,2.8vw,39px)/1.1 var(--serif); letter-spacing:-.04em; }
.neighbors header { align-items:baseline; justify-content:flex-start; flex-wrap:wrap; }
.comparison-controls { display:flex; align-items:center; flex-wrap:wrap; gap:6px 12px; margin:0 0 14px; }
.comparison-controls strong { font-size:13px; }
#modes { display:flex; gap:5px; flex-wrap:wrap; }
#mode-help { flex-basis:100%; }
#modes button { border:1px solid #b4bfb3; border-radius:18px; padding:6px 13px; background:transparent; font-size:13px; }
#modes [aria-pressed=true] { color:white; background:var(--teal); border-color:var(--teal); }
#modes button[aria-pressed=true]:hover { color:white; }
#mode-help,#search-status,.methods p { font-size:14px; line-height:1.55; color:var(--muted); }
#neighbor-list { display:grid; grid-template-columns:1fr 1fr; gap:0 28px; margin:11px 0 0; padding:0; list-style:none; }
#neighbor-list li { border-top:1px solid var(--rule); }
.row { display:block; width:100%; text-align:left; background:transparent; border:0; padding:12px 10px 12px 12px; }
.row[aria-current=true] { background:var(--pale); box-shadow:inset 3px 0 var(--teal); }
.row:hover { background:#f1f3ed; }
.row strong { font-size:12px; letter-spacing:.025em; color:var(--teal); }
.row .row-title { display:block; font:500 19px/1.2 var(--serif); margin:3px 0; }
.row .reason { display:block; font-size:13px; line-height:1.4; color:var(--body); }
#results { padding:17px 20px 14px; margin:0 0 20px; background:#f1f4ed; border:1px solid var(--rule); border-radius:4px; }
.result-head h2 { font-size:26px; } #search-status { margin:5px 0; }
.hit { display:flex; align-items:center; gap:12px; justify-content:space-between; padding:8px 0; border-top:1px solid var(--rule); font-size:13px; }
.hit>div { min-width:0; } .hit button,.more { color:var(--teal); border:0; background:none; padding:0; text-align:left; }
.hit button { font:500 17px/1.22 var(--serif); }
.hit .pages { display:flex; align-items:center; justify-content:flex-end; flex-wrap:wrap; gap:4px 9px; flex:none; max-width:39%; }
.more { margin:8px 0; text-decoration:underline; } .methods { border-block:1px solid var(--rule); padding:13px 0; }
.methods summary { cursor:pointer; font-size:14px; font-weight:600; } .methods p { margin:9px 0; max-width:80ch; }
#missing-texts { margin:10px 0 14px; }
.text-available { display:block; color:var(--muted); font-size:13px; line-height:1.5; }
#missing-texts li { margin:7px 0; max-width:82ch; }
#missing-texts ul { margin:7px 0; padding-left:20px; font-size:13px; line-height:1.6; }
.downloads,footer { display:flex; flex-wrap:wrap; gap:9px 20px; font-size:13px; } footer { justify-content:space-between; padding:19px 0 32px; }
#error { padding:12px; background:#f8eee4; }
@media(max-width:850px){.study{grid-template-columns:minmax(0,1.17fr) minmax(0,1fr)} .map-tip{margin-left:0}.map-head{padding-inline:13px}}
@media(max-width:680px){.shell{padding-inline:16px}.masthead{min-height:54px;gap:8px}.byline{gap:7px}.byline .wordmark{font-size:20px}.masthead a:not(.wordmark){font-size:12px}
.intro-row{display:block;padding:22px 0 17px}.intro-row p{margin-top:7px;font-size:14px;max-width:60ch}.controls{grid-template-columns:1fr;gap:10px;padding:11px 0 15px}
.study{grid-template-columns:1fr}.reader{border:0;border-top:1px solid var(--rule);padding:15px 17px}#map svg{min-height:0;max-height:430px;height:auto}#map{min-height:150px}
.map-head{padding-top:12px}.map-head h2{font-size:20px}figcaption{padding:6px 14px 10px}.neighbors{margin:22px 0}.neighbors header{gap:4px 10px}
#neighbor-list{grid-template-columns:1fr}.hit{align-items:flex-start}.hit .pages{max-width:32%}#results{padding:12px}.sources a{line-height:1.65}}
.shared-list,.seed-notes { font-size:13px; margin:8px 0; }
.shared-list summary,.seed-notes summary,.extra-pages summary { cursor:pointer;color:var(--teal); }
.shared-list ul { padding-left:18px; margin:6px 0; }
.shared-list li { margin:4px 0; line-height:1.32; }
.seed-notes p,.seed-notes .coverage-note { color:var(--body); margin:6px 0; line-height:1.5; }
.seed-notes a { font-size:13px; }
.more-pages { display:flex; flex-wrap:wrap;gap:4px 9px; }
.hit-cite { color:var(--muted);font-size:12px;margin-bottom:3px; }
#map-key { display:flex; flex-wrap:wrap; align-items:baseline; gap:5px 13px; border-top:1px solid var(--rule); margin-top:10px; padding-top:8px; }
#map-key strong { font-size:12px; }
#map-key ul { display:flex; flex-wrap:wrap; gap:5px 14px; padding:0; margin:0; list-style:none; }
#map-key li { display:flex; gap:6px; align-items:center; }
#map-key li:before { content:""; width:12px; height:12px; border-radius:50%; background:var(--swatch); }
#title-matches summary { cursor:pointer; color:var(--teal); }
#title-matches details { font-size:14px; margin:9px 0; }
#title-matches button { display:block; padding:5px 0; text-align:left; border:0; background:transparent; color:var(--teal); font-family:var(--serif); font-size:16px; }
.other-signal { display:block; margin-top:8px; border:0; padding:0; background:transparent; color:var(--teal); font-size:13px; text-decoration:underline; text-underline-offset:3px; }
.shared-list ul { max-height:13rem; overflow:auto; }
