/* Icons are from Lucide (ISC); see research-data/icons/LUCIDE-LICENSE.txt. */
.research-marker-hit{display:flex;align-items:center;justify-content:center;width:44px;height:44px;background:transparent;border:0;border-radius:50%;cursor:pointer}
.research-marker-hit:focus-visible{outline:2px solid #176b87;outline-offset:-3px}
.research-marker-hit.is-selected:before{content:'';position:absolute;inset:4px;border:2px solid #176b87;border-radius:50%;box-shadow:0 0 0 2px #fcfbf7;pointer-events:none}
.research-marker{position:relative;display:grid;place-items:center;box-sizing:border-box;width:var(--marker-size,22px);height:var(--marker-size,22px);border:1.5px solid #24343a;border-radius:50%;background:#24343a;color:#fcfbf7;box-shadow:0 0 0 2px #fcfbf7,0 1px 4px #0009;overflow:hidden}
.research-marker.is-future,.research-marker.is-past,.research-marker.is-unknown{background:#fcfbf7;color:#24343a}
.research-marker.is-past{border-color:transparent;border-radius:3px;box-shadow:0 0 0 2px #fcfbf7,0 1px 4px #0009}
.research-marker.is-past:before{content:'';position:absolute;inset:0;background:linear-gradient(#24343a,#24343a) left top/6px 1.5px no-repeat,linear-gradient(#24343a,#24343a) left top/1.5px 6px no-repeat,linear-gradient(#24343a,#24343a) right top/6px 1.5px no-repeat,linear-gradient(#24343a,#24343a) right top/1.5px 6px no-repeat,linear-gradient(#24343a,#24343a) left bottom/6px 1.5px no-repeat,linear-gradient(#24343a,#24343a) left bottom/1.5px 6px no-repeat,linear-gradient(#24343a,#24343a) right bottom/6px 1.5px no-repeat,linear-gradient(#24343a,#24343a) right bottom/1.5px 6px no-repeat}
.research-marker.is-unknown{border-style:dashed}
.research-marker.is-construction:after{content:'';position:absolute;bottom:0;left:0;right:0;height:30%;background:repeating-linear-gradient(135deg,#24343a 0 1px,#fcfbf7 1px 3px);border-top:1px solid #24343a}
.research-marker.is-construction{background:#fcfbf7;color:#24343a}
.research-marker.is-construction.is-present{background:#24343a;color:#fcfbf7}
.research-glyph{position:relative;z-index:1;display:block;width:14px;height:14px;background:currentColor;-webkit-mask:var(--glyph-url) center/contain no-repeat;mask:var(--glyph-url) center/contain no-repeat}
.research-cluster{display:grid;place-items:center;box-sizing:border-box;width:26px;height:26px;border:1.5px solid #24343a;border-radius:50%;background:#fcfbf7;color:#24343a;box-shadow:0 0 0 2px #fcfbf7,0 2px 5px #0008;font:600 11px/1 system-ui,sans-serif}
.research-preview,.research-chooser{position:absolute;z-index:780;box-sizing:border-box;border:1px solid var(--hd-line,#454c45);border-radius:10px;background:var(--hd-surface,#202724);color:var(--hd-text,#f1f0e9);box-shadow:0 7px 28px #0006;font:13px/1.4 system-ui,-apple-system,BlinkMacSystemFont,'Segoe UI',sans-serif;color-scheme:light dark;--hd-surface:light-dark(#fcfbf7,#202724);--hd-text:light-dark(#24343a,#f1f0e9);--hd-muted:light-dark(#64747a,#b7beb6);--hd-line:light-dark(#d8dede,#454c45);--hd-soft:light-dark(#edf1ef,#303831)}
.research-preview[hidden],.research-chooser[hidden]{display:none}
.research-preview{width:min(272px,calc(100% - 20px));display:grid;grid-template-columns:minmax(0,1fr);padding:10px;gap:10px}
.research-preview.has-photo{grid-template-columns:96px minmax(0,1fr)}
.research-preview-image{width:96px;height:72px;border-radius:4px;overflow:hidden;background:var(--hd-soft)}
.research-preview-image img,.research-chooser-image img{width:100%;height:100%;display:block;object-fit:cover}
.research-preview-body{display:flex;flex-direction:column;min-width:0;gap:4px;padding-right:20px}
.research-preview-body strong{font-size:14px;font-weight:600;line-height:1.25;overflow-wrap:anywhere}
.research-preview-date,.research-preview-photo-date{font-size:11px;color:var(--hd-muted);font-variant-numeric:tabular-nums}
.research-preview-close,.research-chooser-close{position:absolute;right:5px;top:4px;width:26px;height:26px;border:0;border-radius:6px;background:transparent;color:inherit;font:20px/1 system-ui;cursor:pointer}
.research-preview-close:hover,.research-preview-close:focus-visible,.research-chooser-close:hover,.research-chooser-close:focus-visible{background:var(--hd-soft)}
.research-chooser{width:min(272px,calc(100% - 20px));max-height:min(48vh,330px);padding:8px;overflow:auto}
.research-chooser-header{display:flex;align-items:center;min-height:28px;padding:0 28px 4px 4px;font-size:12px}
.research-chooser-item{display:flex;align-items:center;gap:9px;width:100%;min-height:48px;padding:5px;border:0;border-radius:6px;background:transparent;color:inherit;text-align:left;cursor:pointer;font:inherit}
.research-chooser-item:hover,.research-chooser-item:focus-visible{background:var(--hd-soft);outline-color:#176b87}
.research-chooser-image{display:block;flex:0 0 44px;width:44px;height:40px;border-radius:4px;overflow:hidden;background:var(--hd-soft)}
.research-chooser-symbol{display:grid;place-items:center;width:24px;flex:0 0 24px}
.research-chooser-body{display:flex;flex-direction:column;min-width:0;gap:3px}.research-chooser-body strong{font-size:12px}.research-chooser-body small{font-size:11px;color:var(--hd-muted)}
#historic-places-results .research-search-result{display:flex;flex-direction:column;align-items:flex-start;justify-content:center;gap:2px;width:100%;border:0;border-radius:6px;background:transparent;color:inherit;text-align:left;cursor:pointer}#historic-places-results .research-search-result>span{display:block;width:100%;min-width:0;white-space:normal;overflow-wrap:anywhere;line-height:1.3}#historic-places-results .research-search-result small{display:block;color:var(--hd-muted,#b7beb6);font-size:10px;line-height:1.25}
@media(pointer:coarse){.research-preview-close,.research-chooser-close{width:44px;height:44px}.research-chooser-item{min-height:44px}}
/* Previews sit above the map controls (1000) and open the place when clicked. */
.research-preview,.research-chooser{z-index:1150}
.research-preview{cursor:pointer}
.research-preview:hover{border-color:var(--hd-muted)}
.research-preview-body::after{content:'Open place';margin-top:2px;font-size:11px;font-weight:600;color:var(--hd-muted)}
.research-preview-lead{grid-column:1/-1;margin:0;font-size:12.5px;line-height:1.45;color:var(--hd-text,#f1f0e9)}
.research-preview.has-lead .research-preview-body::after{content:none}
.research-preview-lead::after{content:'Open place';display:block;margin-top:6px;font-size:11px;font-weight:600;color:var(--hd-muted)}
/* On phones the nearby-places list is a bottom sheet, not a floating box beside a marker. */
@media(max-width:640px){.research-chooser{position:fixed;left:8px!important;right:8px;top:auto!important;bottom:calc(var(--map-footer-height,24px) + 6px);width:auto;max-height:46dvh;border-radius:14px;padding:6px 8px 10px}.research-chooser-header{min-height:40px;font-size:13px}.research-chooser-body strong{font-size:13.5px}.research-chooser-body small{font-size:12px}}
.research-area-profile{margin:9px 0 2px;padding:8px 9px;border:1px solid var(--hd-line,#454c45);border-radius:7px;background:var(--hd-soft,#303831);color:var(--hd-text,#f1f0e9);font:11px/1.35 system-ui,sans-serif}
.research-area-profile[hidden]{display:none}.research-area-profile strong{display:block;font-size:11px}.research-area-profile p{margin:4px 0 2px}.research-area-profile small{display:block;color:var(--hd-muted,#b7beb6);font-size:10px}.research-area-sources{margin-top:4px;color:var(--hd-muted,#b7beb6)}.research-area-sources summary{cursor:pointer}.research-area-sources ul{margin:4px 0 0;padding-left:16px}.research-area-sources a{color:var(--hd-text,#f1f0e9)}

.place-legend .research-marker { flex:none; margin:0 5px; width:18px; height:18px; }
/* Year cards: a pin whose status changed with the year crossfades to its new shape; a row the sources leave in doubt is ringed with a dash. */
.research-marker-hit.is-fading-in { animation:research-pin-in .2s ease-out; }
.research-marker-hit.is-fading-out { animation:research-pin-out .2s ease-in forwards; pointer-events:none; }
@keyframes research-pin-in { from { opacity:0; } to { opacity:1; } }
@keyframes research-pin-out { from { opacity:1; } to { opacity:0; } }
@media (prefers-reduced-motion:reduce) { .research-marker-hit.is-fading-in, .research-marker-hit.is-fading-out { animation:none; } }
.research-marker.is-doubtful { outline:1.5px dashed #24343a; outline-offset:3px; }
