.page { max-width: 1080px; padding-bottom: 2rem; }
h1 { color: var(--accent-text); }
h1 img { object-fit: contain; vertical-align: middle; }
h1 { margin-bottom: 1.5rem; }
.hint { color: var(--text-light); font-size: .85rem; line-height: 1.55; }
.sketch { position: relative; isolation: isolate; }
.sketch > svg.rough { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: -1; overflow: visible; }
.map-wrap { padding: 6px; }
#map { height: 440px; background: #eaf1eb; }
button { font: inherit; cursor: pointer; }
button:focus-visible, a:focus-visible, .chart-scroll:focus-visible { outline: 2px solid var(--accent-text); outline-offset: 4px; }
#fit { position: absolute; left: 18px; bottom: 18px; background: var(--bg-color); border: 1px solid var(--hairline); border-radius: 4px; padding: 6px 10px; font-size: .8rem; color: var(--accent-text); }
.pin { background: none; border: 0; padding: 0; width: 30px; height: 38px; }
.pin svg { display: block; width: 30px; height: 38px; overflow: visible; transform-origin: bottom; transition: transform .15s; filter: drop-shadow(0 1px 1px #0003); }
.pin[aria-pressed="true"] svg, .pin:hover svg { transform: scale(1.2); }
.forecast { width: min(600px, calc(100vw - 32px)); max-height: min(720px, calc(100dvh - 64px)); box-sizing: border-box; overflow: auto; overscroll-behavior: contain; padding: 1.4rem; margin: auto; background: var(--bg-color); color: var(--text-color); border: 1px solid #4a7c59; border-radius: 10px; box-shadow: 0 20px 80px #172b2340; }
.forecast::backdrop { background: #172b231c; }
body:has(.forecast[open]) { overflow: hidden; }
#close-forecast { position: sticky; top: 0; float: right; margin: -.9rem -.9rem .3rem .5rem; z-index: 1; width: 32px; height: 32px; border: 0; border-radius: 50%; background: var(--bg-color); color: var(--accent-text); font-size: 1.5rem; line-height: 1; }
.shortlist { margin: 1.5rem 0; }
.shortlist summary { cursor: pointer; color: var(--accent-text); padding: .5rem 0; }
.shortlist summary span { color: var(--text-light); font-size: .8rem; }
.shortlist[open] summary { margin-bottom: .75rem; }
.forecast-heading { display: flex; justify-content: space-between; align-items: start; gap: 1rem; }
.forecast h2 { border: 0; margin: .2rem 0 .7rem; padding: 0; color: var(--accent-text); }
.tag { font-size: .8rem; color: var(--accent-text); }
#refresh { background: none; border: 0; color: var(--accent-text); font-size: .8rem; white-space: nowrap; padding: .3rem 0; }
.forecast-links { display: flex; flex-wrap: wrap; gap: .4rem 1.25rem; margin: 1rem 0; font-size: .85rem; }
.forecast-links a { text-decoration: underline; text-underline-offset: 3px; }
#chart-link { font-weight: 600; }
.station { font-size: .9rem; margin-bottom: .5rem; }
.chart-scroll { overflow-x: auto; max-width: 100%; background: white; border: 1px solid var(--hairline); }
#chart { display: block; max-width: none; }
.reading-guide { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.2rem; font-size: .85rem; padding-top: .5rem; }
.reading-guide b { color: var(--accent-text); }
.list-heading { border: 0; margin-bottom: 1rem; }
.list-heading span { font-size: .8rem; color: var(--text-light); font-weight: normal; }
.places { display: grid; grid-template-columns: 1fr 1fr; gap: .85rem; }
.place { text-align: left; border: 1px solid var(--hairline); border-radius: 5px; padding: 1rem; background: #fff; color: var(--text-color); }
.place[aria-pressed="true"] { border-color: var(--accent-text); background: #edf5ed; }
.place strong { display: block; margin: .25rem 0 .5rem; font-size: 1rem; }
.place .summary { display: block; font-size: .85rem; }
.place .action { display: block; color: var(--accent-text); font-size: .8rem; margin-top: .7rem; }
.footnote { margin-top: 1.5rem; }
.all-charts { font-size: .9rem; }
[hidden] { display: none !important; }
@media (max-width: 600px) {
 .page { padding: 1.5rem 1rem 2rem; }
 h1 { font-size: 1.65rem; }
 #map { height: 360px; }
 .forecast { padding: 1rem; }
 .forecast-heading { display: block; }
 #refresh { margin-bottom: .7rem; }
 .reading-guide, .places { grid-template-columns: 1fr; }
 .reading-guide { gap: 0; }
}
@media (prefers-reduced-motion: reduce) { .pin svg { transition: none; } }

.origin { width: 28px; height: 28px; }
.origin svg { display: block; width: 28px; height: 28px; overflow: visible; }
#route-status { color: var(--accent-text); font-weight: 600; }

/* Keep the sketched dialog frame outside its scrolling contents. */
.forecast.sketch { position: fixed; padding: 6px; overflow: hidden; border: 0; border-radius: 0; box-shadow: 0 12px 45px #172b2326; }
.forecast-body { max-height: min(708px, calc(100dvh - 76px)); padding: 1.2rem; overflow: auto; overscroll-behavior: contain; }
.place.sketch { border: 0; border-radius: 0; background: var(--bg-color); }
.place.sketch[aria-pressed="true"] { background: #edf5ed; }
#map .maplibregl-ctrl-group { box-shadow: none; border: 1px solid var(--hairline); border-radius: 6px; }
#map .maplibregl-ctrl-attrib { font: 11px/1.3 var(--font-family); background: #ffffffb3; }
@media (max-width: 600px) { .forecast-body { padding: 1rem; } }
