/* A visual refresh only: the history, map geometry and interaction code stay intact. */
@font-face {
  font-family: "Manrope";
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url("fonts/manrope-latin.woff2") format("woff2");
}
@font-face {
  font-family: "DM Sans";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("fonts/dm-sans-latin.woff2") format("woff2");
}
:root {
  --display: "Manrope", system-ui, sans-serif;
  --body: "DM Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --serif: var(--display);
}
body {
  font-family: var(--body);
  line-height: 1.7;
  background: radial-gradient(ellipse 650px 380px at 85% 0, #6bd5c409, transparent 80%), var(--bg);
  -webkit-font-smoothing: antialiased;
}
h1, h2, h3 { font-family: var(--display); font-weight: 750; text-wrap: balance; }
h1 { letter-spacing: -.02em; word-spacing: .025em; line-height: 1.2; }
h2, h3 { line-height: 1.35; }
button, a { -webkit-tap-highlight-color: #6bd5c42b; }
button {
  border-radius: 10px;
  min-height: 44px;
  transition: background-color .16s ease, border-color .16s ease, box-shadow .16s ease;
}
button:hover { background: #6bd5c410; border-color: #6bd5c480; }
button:disabled:hover { background: transparent; border-color: var(--line); }
button[aria-pressed="true"] { background: var(--up); color: var(--bg); border-color: var(--up); }
.site-header { padding-top: 1rem; padding-bottom: 1rem; }
.brand { font-family: var(--display); font-weight: 750; letter-spacing: -.01em; min-width: 0; max-width: 100%; }
.brand-amp { color: var(--up); font-family: inherit; font-style: normal; }
.brand-mark { gap: 4px; transform: none; flex-shrink: 0; }
.brand-mark i { border-radius: 3px; }
.site-header nav { gap: .45rem; }
.site-header nav a {
  padding: .55rem .8rem;
  border-radius: 999px;
  font-weight: 500;
  color: #c5d1da;
  transition: color .16s ease, background-color .16s ease;
}
.site-header nav a:hover { color: var(--text); background: #ffffff08; }
.site-header nav a[aria-current="page"] {
  color: var(--up);
  background: #6bd5c414;
  text-decoration: none;
}
.eyebrow {
  display: inline-block;
  max-width: 100%;
  padding: .3rem .65rem;
  background: #6bd5c40d;
  border: 1px solid #6bd5c427;
  border-radius: 999px;
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .01em;
  line-height: 1.5;
  text-transform: none;
  margin-bottom: 1.1rem;
}
.intro { padding-top: 2.3rem; padding-bottom: 2rem; gap: 3rem; }
.intro > div { min-width: 0; }
.intro h1 { font-size: clamp(2.6rem, 4.7vw, 4.2rem); font-weight: 800; max-width: 650px; }
.hook-accent { color: var(--up); }
.intro-note { font-size: 1rem; line-height: 1.7; }
.city-years { gap: .65rem 1.2rem; }
.city-years span { font-size: .85rem; }
.city-years b { font-weight: 700; color: var(--text); }
.explorer { border-radius: 20px; box-shadow: 0 20px 55px #0002; }
.timeline-head { background: var(--panel); padding: 1rem 1.25rem; }
.timeline-head h2 { font-weight: 750; letter-spacing: -.01em; font-size: 1.05rem; }
#step-count {
  background: #ffffff07;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: .22rem .55rem;
  font-size: .8rem;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.step-actions { display: flex; gap: .4rem; }
.step-actions button { font-size: .85rem; padding: .55rem .75rem; }
#previous::before { content: "←"; margin-right: .35rem; }
#next::after { content: "→"; margin-left: .35rem; }
.timeline-wrap { padding: 0 1rem; }
.timeline { gap: .35rem; padding: .8rem 0 1rem; }
.timeline button { min-width: 110px; border-radius: 12px 12px 0 0; padding: .7rem .4rem .85rem; }
.timeline button:hover { background: #ffffff07; }
.timeline .time-year { font-family: var(--display); font-size: .95rem; font-weight: 750; line-height: 1.5; }
.timeline .time-label { font-size: .8rem; font-weight: 500; line-height: 1.5; }
.timeline button[aria-current="true"] { background: var(--hp); color: var(--bg); }
.timeline button[aria-current="true"] .time-year,
.timeline button[aria-current="true"] .time-label { color: var(--bg); }
.timeline button .time-dot { width: 9px; height: 9px; bottom: -3px; }
.event-heading { margin-bottom: 1.4rem; gap: .75rem 1rem; }
.event-year { font-weight: 800; font-size: 2.6rem; letter-spacing: -.02em; line-height: 1.2; }
.event-type { border-radius: 999px; background: #ffffff04; padding: .35rem .65rem; line-height: 1.45; }
#event-title { font-weight: 750; font-size: clamp(1.65rem, 2.25vw, 2rem); line-height: 1.32; letter-spacing: -.01em; margin-bottom: 1.25rem; }
#event-content > p { line-height: 1.7; }
.outcome { border-radius: 0 12px 12px 0; padding: .9rem 1rem; background: #6bd5c411; }
.outcome span { letter-spacing: 0; text-transform: none; font-weight: 600; font-size: .8rem; margin-bottom: .45rem; }
.outcome strong { font-weight: 600; }
.event-sources { align-items: center; }
.event-sources a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: .1rem .4rem;
  border-radius: 7px;
  color: var(--up);
  text-decoration: none;
  background: #6bd5c40b;
}
.event-sources a:hover { background: #6bd5c420; text-decoration: underline; }
.map-head h2 { font-family: var(--display); font-size: 1.1rem; font-weight: 750; letter-spacing: -.01em; margin-bottom: .45rem; }
.map-actions { gap: .4rem; }
.map-actions button { padding: .5rem .7rem; font-size: .8rem; }
.map-help { font-size: .85rem; }
.place-buttons { gap: .55rem; margin-bottom: .9rem; }
.place-buttons button {
  --place-color: var(--text);
  min-height: 44px;
  border-radius: 999px;
  padding: .55rem .8rem;
  font-size: .85rem;
  background: #ffffff03;
}
.place-buttons button::before {
  content: "";
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-right: .45rem;
  border-radius: 50%;
  background: var(--place-color);
  vertical-align: .06em;
}
.place-buttons button[data-place="hp"],
.place-buttons button[data-place="preston"] { --place-color: var(--hp); }
.place-buttons button[data-place="up"],
.place-buttons button[data-place="smu"] { --place-color: var(--up); }
.place-buttons button:hover { background: #ffffff0a; border-color: var(--place-color); }
.place-buttons button[aria-pressed="true"] {
  background: var(--place-color);
  color: var(--bg);
  border-color: var(--place-color);
  box-shadow: 0 2px 12px #0002;
}
.place-buttons button[aria-pressed="true"]::before { background: var(--bg); }
.map-shell { border-radius: 14px; overflow: hidden; }
.real-map .leaflet-control-zoom { border: 0; border-radius: 12px; box-shadow: 0 2px 12px #10213130; overflow: hidden; }
.real-map .leaflet-control-zoom a { font-family: var(--body); }
.real-map .leaflet-popup-content-wrapper { border-radius: 16px; box-shadow: 0 8px 28px #10213130; }
.real-map .leaflet-popup-content { font-family: var(--body); line-height: 1.6; }
.city-popup strong { font-family: var(--display); font-weight: 800; letter-spacing: -.01em; line-height: 1.4; }
.real-map .city-map-label { font-family: var(--body); border-radius: 7px; line-height: 1.45; }
.real-map .selected-map-label { font-weight: 700; }
.map-legend { gap: .5rem 1rem; }
.swatch { border-radius: 3px; }
.continue-story { padding: 1.8rem 0; }
.continue-story h2 { font-weight: 750; font-size: 1.85rem; letter-spacing: -.015em; line-height: 1.35; margin-bottom: .9rem; }
.story-button {
  background: var(--up);
  color: var(--bg);
  border: 1px solid var(--up);
  border-radius: 999px;
  font-weight: 700;
  padding: .8rem 1.2rem;
  transition: box-shadow .16s ease, background-color .16s ease;
}
.story-button:hover { background: #88e4d5; box-shadow: 0 4px 24px #6bd5c420; }
.story-intro h1 { font-size: clamp(2.5rem, 4.2vw, 3.8rem); max-width: 960px; font-weight: 800; }
.story-intro > p:not(.eyebrow) { margin: 1.4rem 0 1.8rem; line-height: 1.75; }
.story-chapters { gap: .6rem; padding: .6rem 0 1rem; }
.story-chapters a { background: #ffffff04; border: 1px solid var(--line); border-radius: 999px; padding: .5rem .9rem; }
.story-chapters a:hover { color: var(--up); border-color: #6bd5c470; background: #6bd5c409; }
.section-heading { margin-bottom: 1.9rem; }
.section-heading h2 { font-weight: 750; font-size: clamp(1.8rem, 3vw, 2.3rem); letter-spacing: -.015em; }
.section-heading > p:not(.eyebrow) { margin-top: 1rem; }
.why-grid h3, .money-section .why-grid h3 { font-weight: 700; font-size: 1.4rem; letter-spacing: -.01em; line-height: 1.4; margin: 1rem 0; }
.city-chip { font-weight: 600; text-transform: none; letter-spacing: 0; font-size: .85rem; }
.concept-comparison, .boundary-demo, details { border-radius: 14px; }
.concept-comparison caption { font-family: var(--display); font-weight: 750; }
.concept-comparison thead th { color: var(--up); font-weight: 600; }
.document-excerpt { border-radius: 0 14px 14px 0; }
.document-excerpt > p:first-child { font-weight: 500; letter-spacing: 0; font-size: 1.4rem; line-height: 1.6; }
summary { font-weight: 600; }
summary::marker { color: var(--up); }
.archive-card { border-radius: 16px; }
.archive-card h3 { font-weight: 700; letter-spacing: -.01em; line-height: 1.4; margin: .8rem 0 .9rem; }
.archive-date { font-weight: 600; }
.watch-card { border-radius: 16px; }
.watch-card h3 { font-weight: 750; font-size: 1.5rem; letter-spacing: -.01em; line-height: 1.4; margin: 1rem 0; }
.watch-link { background: var(--hp); color: var(--bg); border-color: var(--hp); border-radius: 999px; font-weight: 700; }
.watch-link svg { color: currentColor; }
.watch-link:hover { background: #f7c780; }
.bibliography-page h1 { font-weight: 800; letter-spacing: -.02em; }
.bibliography-link { font-weight: 600; }
.source-list li { padding: 1.25rem 0 1.25rem 2.6rem; }
.source-list a { font-weight: 600; font-size: 1rem; line-height: 1.6; }
.source-list p { font-size: .875rem; line-height: 1.65; margin-top: .5rem; }
.source-list li::before { font-weight: 700; }
footer { font-size: .8rem; }
@media (max-width: 1050px) {
  .brand { font-size: 1rem; }
  .site-header nav { gap: .45rem; }
  .intro h1 { font-size: clamp(2.6rem, 5vw, 3.5rem); }
}
@media (max-width: 760px) {
  .site-header { padding: .9rem 1rem; gap: .6rem; }
  .site-header nav { width: 100%; gap: .4rem; font-size: .8rem; }
  .site-header nav a { padding: .45rem .7rem; }
  .intro { padding-top: 1.8rem; padding-bottom: 2rem; gap: 1.65rem; }
  .intro h1 { font-size: clamp(2.45rem, 8.8vw, 3.4rem); max-width: 540px; }
  h1 { line-height: 1.22; }
  .intro-note { font-size: 1rem; }
  .eyebrow { font-size: .75rem; }
  .explorer { border-radius: 16px; }
  .timeline-head { padding: .8rem; gap: .6rem; }
  .timeline-head h2 { font-size: 1rem; }
  .timeline-head .step-actions { margin-left: 0; }
  .step-actions button { font-size: .8rem; padding: .5rem .65rem; }
  .timeline-wrap { padding: 0 .75rem; }
  .timeline button { min-width: 105px; }
  .event-panel { padding: 1.3rem; }
  .event-year { font-size: 2.4rem; }
  #event-title { font-size: 1.8rem; }
  .map-head { flex-wrap: wrap; gap: .65rem; }
  .map-actions { width: 100%; }
  .place-buttons button { padding: .5rem .75rem; }
  .continue-story h2 { font-size: 1.7rem; }
  .story-intro h1 { font-size: clamp(2.3rem, 7.6vw, 3rem); }
  .story-chapters { gap: .55rem; }
  .story-chapters a { padding: .5rem .8rem; }
  .archive-card h3 { font-size: 1.35rem; }
  .document-excerpt > p:first-child { font-size: 1.25rem; }
  .bibliography-page h1 { font-size: clamp(2.2rem, 7.6vw, 3rem); }
}
@media (max-width: 380px) {
  .site-header { padding-left: .7rem; padding-right: .7rem; }
  .brand { font-size: .95rem; gap: .65rem; }
  .site-header nav a { padding: .4rem .65rem; }
  .timeline-head #step-count { margin-left: auto; }
  .timeline-head .step-actions { width: 100%; justify-content: flex-end; }
}
@media (prefers-reduced-motion: reduce) {
  button, a { transition: none; }
}

/* Keep the question beneath the brand readable when it wraps on a phone. */
.brand-copy { display: flex; flex-direction: column; gap: .4rem; min-width: 0; }
.brand-title { line-height: 1.35; }
.brand-tagline { font-family: var(--body); font-size: .75rem; font-weight: 500; letter-spacing: 0; line-height: 1.5; color: var(--muted); max-width: 28rem; white-space: normal; text-wrap: pretty; }
.story-button { max-width: 100%; white-space: normal; text-align: center; }

.city-years a { display: inline-flex; align-items: center; gap: .45rem; min-height: 44px; font-size: .85rem; text-decoration: none; border-radius: 6px; }
.city-years a:hover { text-decoration: underline; text-underline-offset: 4px; }
