/* FEAT-000130 — Map v1. Clean FHDP research-site styling; historical
   meaning comes from governed map data, not themed chrome. */
#page-map{padding-bottom:28px}
#page-map .map-page-heading{align-items:stretch}
.map-year-card{
  min-width:128px;
  border:1px solid var(--line);
  border-radius:5px;
  background:#fff;
  padding:8px 12px;
  display:grid;
  align-content:center;
  justify-items:end;
  font-family:Arial,sans-serif;
}
.map-year-card span{font-size:10px;font-weight:700;text-transform:uppercase;letter-spacing:.07em;color:#687783}
.map-year-card strong{font-size:28px;line-height:1;color:var(--navy);margin-top:3px}
.map-card{overflow:visible}
.map-time-toolbar{align-items:center}
.map-time-toolbar .toolbar-left{flex:1 1 650px}
.map-year-slider{
  flex:1 1 430px;
  min-width:220px;
  accent-color:var(--navy);
}
.map-year-range-label{font:11px Arial,sans-serif;color:#687783;white-space:nowrap}
.map-local-filters{gap:8px;z-index:500}
.map-filter-control{position:relative;z-index:510}
.map-filter-popover{z-index:2300}
.map-layer-toggles{
  display:flex;
  flex-wrap:wrap;
  align-items:center;
  gap:5px 10px;
  margin-left:auto;
  font:11px Arial,sans-serif;
  color:#405365;
}
.map-layer-toggle{display:inline-flex;align-items:center;gap:5px;white-space:nowrap}
.map-layer-toggle input{margin:0}
.map-layer-count{color:#74818c}
.map-layout{
  display:grid;
  grid-template-columns:minmax(0,1fr) 320px;
  min-height:600px;
}
#fhdpMap{
  min-height:600px;
  background:#eef2f4;
  border-right:1px solid var(--line);
  font-family:Arial,sans-serif;
}
.map-feature-detail{
  min-width:0;
  background:#fbfcfd;
  padding:14px;
  font:12px/1.4 Arial,sans-serif;
  color:#3f5264;
}
.map-detail-empty{
  min-height:140px;
  border:1px dashed #b9c3cc;
  border-radius:4px;
  padding:14px;
  display:flex;
  flex-direction:column;
  gap:5px;
  color:#687783;
}
.map-detail-empty strong{color:#30485d}
.map-detail-heading{
  display:flex;
  justify-content:space-between;
  gap:10px;
  align-items:flex-start;
  padding-bottom:10px;
  border-bottom:1px solid #dfe5ea;
  margin-bottom:12px;
}
.map-detail-heading h2{font:700 18px/1.2 Georgia,"Times New Roman",serif;color:#20384e;margin:3px 0 0}
.map-detail-grid{grid-template-columns:115px minmax(0,1fr)}
.map-detail-grid a{color:#154f7b;text-decoration:underline;text-underline-offset:2px}
.map-note{
  border-top:1px solid var(--line);
  padding:8px 12px;
  background:#fafbfc;
  font:11px/1.4 Arial,sans-serif;
  color:#657482;
}
.map-note strong{color:#40586c}
#page-map .leaflet-container{font:12px Arial,sans-serif}
#page-map .leaflet-control-zoom a{color:#30465a}
#page-map .leaflet-control-attribution{font-size:9px}
#page-map .error-text{color:#8a403c}
@media (max-width:980px){
  .map-layout{grid-template-columns:1fr}
  #fhdpMap{min-height:520px;border-right:0;border-bottom:1px solid var(--line)}
  .map-feature-detail{min-height:150px}
  .map-layer-toggles{margin-left:0;width:100%}
}
@media (max-width:620px){
  #page-map{padding-left:10px;padding-right:10px}
  .map-year-card{min-width:100px}
  .map-year-card strong{font-size:24px}
  .map-time-toolbar .toolbar-left{align-items:flex-start}
  .map-year-slider{flex-basis:100%;width:100%}
  #fhdpMap{min-height:440px}
  .map-detail-grid{grid-template-columns:100px minmax(0,1fr)}
}


/* F130 Leaflet core fallback.
   Keep the map functional if the external Leaflet stylesheet is blocked or late.
   These are structural rules only; FHDP styling remains above. */
#fhdpMap.leaflet-container{
  position:relative;
  overflow:hidden;
  -webkit-tap-highlight-color:transparent;
  background:#eef2f4;
  outline:0;
}
#fhdpMap .leaflet-pane,
#fhdpMap .leaflet-tile,
#fhdpMap .leaflet-marker-icon,
#fhdpMap .leaflet-marker-shadow,
#fhdpMap .leaflet-tile-container,
#fhdpMap .leaflet-pane > svg,
#fhdpMap .leaflet-pane > canvas,
#fhdpMap .leaflet-zoom-box,
#fhdpMap .leaflet-image-layer,
#fhdpMap .leaflet-layer{
  position:absolute;
  left:0;
  top:0;
}
#fhdpMap .leaflet-pane{z-index:400}
#fhdpMap .leaflet-tile-pane{z-index:200}
#fhdpMap .leaflet-overlay-pane{z-index:400}
#fhdpMap .leaflet-shadow-pane{z-index:500}
#fhdpMap .leaflet-marker-pane{z-index:600}
#fhdpMap .leaflet-tooltip-pane{z-index:650}
#fhdpMap .leaflet-popup-pane{z-index:700}
#fhdpMap .leaflet-map-pane canvas{z-index:100}
#fhdpMap .leaflet-map-pane svg{z-index:200}
#fhdpMap .leaflet-container .leaflet-overlay-pane svg,
#fhdpMap .leaflet-container .leaflet-marker-pane img,
#fhdpMap .leaflet-container .leaflet-shadow-pane img,
#fhdpMap .leaflet-container .leaflet-tile-pane img,
#fhdpMap img.leaflet-image-layer{
  max-width:none!important;
  max-height:none!important;
}
#fhdpMap .leaflet-control{
  position:relative;
  z-index:800;
  pointer-events:auto;
}
#fhdpMap .leaflet-top,
#fhdpMap .leaflet-bottom{
  position:absolute;
  z-index:1000;
  pointer-events:none;
}
#fhdpMap .leaflet-top{top:0}
#fhdpMap .leaflet-right{right:0}
#fhdpMap .leaflet-bottom{bottom:0}
#fhdpMap .leaflet-left{left:0}
#fhdpMap .leaflet-control{float:left;clear:both}
#fhdpMap .leaflet-right .leaflet-control{float:right}
#fhdpMap .leaflet-top .leaflet-control{margin-top:10px}
#fhdpMap .leaflet-bottom .leaflet-control{margin-bottom:10px}
#fhdpMap .leaflet-left .leaflet-control{margin-left:10px}
#fhdpMap .leaflet-right .leaflet-control{margin-right:10px}
#fhdpMap .leaflet-control-zoom{
  border:1px solid #a9b4be;
  border-radius:4px;
  overflow:hidden;
  background:#fff;
}
#fhdpMap .leaflet-control-zoom a{
  display:block;
  width:30px;
  height:30px;
  line-height:30px;
  text-align:center;
  text-decoration:none;
  background:#fff;
  border-bottom:1px solid #d7dee4;
  font:700 20px/30px Arial,sans-serif;
}
#fhdpMap .leaflet-control-zoom a:last-child{border-bottom:0}
#fhdpMap .leaflet-control-zoom a:hover{background:#f3f6f8}
#fhdpMap .leaflet-control-attribution{
  margin:0;
  padding:2px 5px;
  background:rgba(255,255,255,.82);
  color:#566674;
}
#fhdpMap .leaflet-control-attribution a{color:#244f70}
#fhdpMap .leaflet-interactive{cursor:pointer}
