:root{font-family:Arial,Helvetica,sans-serif;color:#17262d;background:#fff;font-synthesis:none}*{box-sizing:border-box}body{margin:0}main{max-width:1320px;margin:auto;padding:32px 28px 26px}h1{font-size:clamp(26px,3.4vw,40px);letter-spacing:-.035em;margin:10px 0;line-height:1.12}.eyebrow{font-size:11px;font-weight:700;letter-spacing:.17em;color:#586b73;margin:0}.dek{color:#54666e;margin:0;font-size:16px;line-height:1.5}.toolbar{display:flex;align-items:center;justify-content:space-between;gap:20px;margin:26px 0 20px;flex-wrap:wrap}.tabs{display:inline-flex;padding:4px;background:#edf1f3;border-radius:7px;gap:4px}button,select{font:inherit}button{cursor:pointer}.tabs button{border:0;background:transparent;color:#50636b;padding:11px 22px;font-size:14px;border-radius:4px;font-weight:700}.tabs button[aria-selected=true]{background:#172f3a;color:white;box-shadow:0 1px 3px #17262d20}.location-label{display:flex;gap:10px;align-items:center;font-size:12px;color:#415861}select{max-width:280px;width:235px;background:white;border:1px solid #bdcbd1;border-radius:4px;color:#17262d;padding:10px;font-size:13px}.scale{padding:16px 0 20px;border-top:1px solid #dbe3e7}.scale-title{display:flex;gap:16px;align-items:baseline;flex-wrap:wrap;font-size:12px;margin-bottom:12px}.scale-title span{color:#667880}.legend{display:flex;gap:10px 20px;flex-wrap:wrap;font-size:12px}.legend span{display:flex;align-items:center;gap:5px}.swatch{display:inline-block;width:18px;height:12px}.candidates{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:28px}.candidate{min-width:0}.profile{text-align:center;padding:10px 0 18px}.profile h2{font-size:24px;letter-spacing:-.025em;margin:0 0 5px}.party{font-size:13px;font-weight:700;margin:0 0 13px;color:var(--party)}.portrait{height:142px;width:142px;border-radius:50%;padding:10px;background:var(--party);margin:0 auto 15px}.portrait img{width:100%;height:100%;object-fit:cover;object-position:center 24%;border-radius:50%;display:block}.total-label{font-size:10px;letter-spacing:.13em;color:#52666f;text-transform:uppercase;margin:0 0 5px}.total{font-size:30px;font-weight:700;letter-spacing:-.035em;font-variant-numeric:tabular-nums;margin:0}.date{font-size:11px;color:#647780;margin:6px 0 0}.map{height:365px;border:1px solid #d0dbe0;border-radius:3px;background:#edf1f3}.mapped-total{font-size:12px;color:#556b75;margin:10px 0 0;font-variant-numeric:tabular-nums}.selection{font-size:14px;line-height:1.5;min-height:44px;padding:10px 0;font-variant-numeric:tabular-nums}.selection strong{display:block;font-weight:700}.unlocated{font-size:11px;color:#647780;line-height:1.4;margin:0 0 10px}.region-controls{display:flex;gap:7px;align-items:center;flex-wrap:wrap;font-size:12px;margin:0 0 8px;color:#556b75}.region-controls[hidden]{display:none}.region-controls button{background:#f0f4f6;border:1px solid #d1dce2;color:#213f4e;padding:7px 11px;border-radius:3px}.page-status{color:#8a3825;font-size:13px}.page-status:empty{display:none}.data-note{font-size:12px;line-height:1.55;color:#69522a;margin-top:16px}.data-note:empty{display:none}details{border-top:1px solid #dbe3e7;padding-top:16px;margin-top:20px;font-size:12px;color:#596d77;line-height:1.6}summary{cursor:pointer;color:#2e4856;font-weight:700}details p{max-width:1000px}a{color:#126489}button:focus-visible,select:focus-visible,summary:focus-visible{outline:3px solid #268bb0;outline-offset:3px}.mapboxgl-popup-content{font:13px/1.5 Arial,sans-serif;padding:14px 22px 14px 14px;color:#17262d}.mapboxgl-popup-close-button{font-size:19px}.mapboxgl-ctrl-attrib{font-size:10px}@media(max-width:700px){main{padding:24px 15px}.toolbar{gap:15px;align-items:stretch}.location-label{flex-wrap:wrap;width:100%;justify-content:space-between}select{width:210px;max-width:100%}.candidates{grid-template-columns:1fr;gap:25px}.map{height:320px}.profile{padding-top:12px}.portrait{width:128px;height:128px}.scale-title{gap:5px}.total{font-size:28px}}@media(prefers-reduced-motion:reduce){*{scroll-behavior:auto!important}}

/* Fit the comparison to the available screen, with no top margin. */
html,body{min-height:100%;margin:0}
main{height:100dvh;width:100%;max-width:none;margin:0;padding:0 16px 6px;display:flex;flex-direction:column;gap:6px}
.intro{flex:none}h1{font-size:clamp(20px,2.7vw,34px);margin:0 0 3px;line-height:1.1}.dek{font-size:13px;line-height:1.3}
.toolbar{flex:none;margin:4px 0;gap:8px}.tabs{padding:3px}.tabs button{padding:8px 16px}.location-label{width:auto;gap:8px}select{padding:7px;width:235px}
#comparison{flex:1;min-height:0;display:flex;flex-direction:column;gap:6px}
.scale{flex:none;padding:5px 0;border-top:0}.scale-title{margin:0 0 5px;gap:12px}.legend{gap:5px 16px}
.region-controls{flex:none;margin:0;gap:5px}.region-controls button{padding:5px 9px}
.candidates{flex:1;min-height:0;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:20px}
.candidate{min-height:0;display:flex;flex-direction:column}.profile{flex:none;padding:0 0 5px}.profile h2{font-size:clamp(16px,2vw,23px);margin:0 0 2px}.party{font-size:12px;margin:0 0 4px}.portrait{width:clamp(50px,10vh,92px);height:clamp(50px,10vh,92px);padding:6px;margin:0 auto 5px}.total-label{margin:0 0 2px;font-size:10px;letter-spacing:.06em}.total{font-size:clamp(18px,2.3vw,28px)}.date{margin:3px 0 0;line-height:1.2}
.map{flex:1;min-height:50px;height:auto;border:0;border-radius:0}.mapped-total{flex:none;margin:4px 0 0;font-size:11px;line-height:1.2}.selection{flex:none;padding:4px 0;min-height:30px;font-size:12px;line-height:1.2}.selection strong{display:inline;margin-right:5px}.unlocated{flex:none;margin:0;font-size:10px;line-height:1.2}.unlocated:empty{display:none}
.page-status{flex:none;margin:0;font-size:12px}details{flex:none;margin:0;padding-top:4px;line-height:1.4;font-size:12px}details[open]{position:fixed;z-index:10;left:12px;right:12px;bottom:8px;max-height:calc(100dvh - 24px);overflow:auto;padding:16px;background:white;border:1px solid #cbd6dc;box-shadow:0 3px 24px #17262d25}details[open] summary{position:sticky;top:-16px;background:white;padding:8px 0}.data-note{margin-top:10px}
@media(max-width:700px){main{padding:0 8px 4px;gap:4px}.dek{font-size:11px}.toolbar{margin:2px 0;gap:5px}.tabs button{padding:7px 10px;font-size:12px}.location-label{font-size:11px;gap:5px;flex:1;justify-content:flex-end}.location-label>span{display:none}select{width:100%;min-width:0;max-width:190px;font-size:12px;padding:6px}.scale-title{font-size:11px;gap:4px;margin-bottom:4px}.legend{font-size:10px;gap:4px 10px}.swatch{width:12px;height:9px}.candidates{gap:10px;grid-template-columns:minmax(0,1fr) minmax(0,1fr)}.profile h2{font-size:16px}.party{font-size:11px}.portrait{width:60px;height:60px;padding:5px;margin-bottom:4px}.total{font-size:20px}.total-label{font-size:9px;letter-spacing:0}.date{font-size:10px}.profile{padding-bottom:4px}.mapped-total{font-size:10px}.selection{font-size:11px;min-height:38px}.region-controls{font-size:10px;gap:4px}.region-controls button{font-size:11px;padding:4px 7px}.mapboxgl-ctrl-group button{width:26px;height:26px}.mapboxgl-ctrl-bottom-left .mapboxgl-ctrl{margin-left:2px}.mapboxgl-ctrl-bottom-right .mapboxgl-ctrl{margin-right:2px}}
@media(max-height:650px){h1{font-size:22px}.dek{font-size:11px}.toolbar{margin:0}.scale-title{font-size:10px;margin-bottom:3px}.scale{padding:2px 0}.legend{font-size:10px;gap:3px 10px}.profile h2{font-size:16px}.party{font-size:10px;margin-bottom:2px}.portrait{width:44px;height:44px;padding:4px;margin-bottom:2px}.total{font-size:18px}.date{font-size:9px;margin-top:2px}.total-label{font-size:9px}.tabs button{padding:5px 10px}.selection{min-height:25px;font-size:10px;padding:2px 0}.mapped-total{font-size:10px}.unlocated{font-size:9px}.candidates{gap:12px}.region-controls button{padding:3px 6px}main,#comparison{gap:3px}}

/* Share row sizes so both map panels remain aligned. */
.candidates{grid-template-rows:auto minmax(50px,1fr) auto auto auto;row-gap:0}
.candidate{display:grid;grid-template-rows:subgrid;grid-row:span 5;row-gap:0}
.profile{grid-row:1}.map{grid-row:2}.mapped-total{grid-row:3}.selection{grid-row:4}.unlocated{grid-row:5}

/* Center the presentation above the maps. */
.intro,.scale,.profile{text-align:center}
.toolbar{justify-content:center}
.scale-title,.legend,.region-controls{justify-content:center}
@media(max-width:700px){.location-label{flex:0 1 auto;justify-content:center}}

.hover-tooltip{pointer-events:none}
.selection strong{margin-right:0}

/* Stack candidate comparisons on narrow screens without squeezing maps. */
@media(max-width:700px){
 main{height:auto;min-height:100dvh}
 #comparison{flex:none;min-height:auto}
 .candidates{display:grid;grid-template-columns:minmax(0,1fr);grid-template-rows:none;gap:22px;flex:none}
 .candidate{display:flex;flex-direction:column;grid-row:auto;min-height:auto}
 .profile{padding:8px 0}
 .profile h2{font-size:20px}
 .portrait{width:72px;height:72px;padding:6px;margin-bottom:5px}
 .total{font-size:24px}
 .map{flex:none;width:100%;height:clamp(240px,42svh,380px);min-height:240px}
 .mapped-total{margin-top:6px;font-size:11px}
 .selection{min-height:30px;font-size:12px;padding:5px 0}
 .unlocated{font-size:11px}
 details{margin-top:12px}
}
