:root {
  font: 100%/1.5 system-ui, sans-serif;
  color: #172d25;
  background: #fffaf0;
  --green: #172d25;
  --yellow: #ffdb54;
  --pink: #ffc0d8;
  --mint: #d0e9a8;
  --paper: #fffdf7;
  --blue: #1265c1;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; }
header { background: var(--pink); border-bottom: 2px solid var(--green); overflow: hidden; }
.masthead, main, footer { max-width: 76rem; margin: auto; padding: 1rem; }
.masthead { position: relative; isolation: isolate; padding-block: 1.35rem 1.65rem; }
h1, h2, h3, p { margin: 0; }
h1 { font-size: clamp(2.55rem, 7vw, 5.25rem); font-weight: 950; line-height: .95; letter-spacing: -.075em; max-width: 12ch; }
.region { font-weight: 750; margin-bottom: .55rem; font-size: .9rem; }
.date { margin-top: .85rem; font-weight: 800; font-size: .92rem; }
.date time { display: inline-block; background: var(--yellow); padding: .3rem .65rem; border: 1.5px solid; box-shadow: 2px 2px var(--green); transform: rotate(-2deg); }
.sale-hours {
  display: inline-block;
  margin-top: .65rem;
  padding: .3rem .65rem;
  border: 2px solid #000;
  background: #fff;
  color: #000;
  font-weight: 850;
}
#sale-day-notice {
  width: min(27rem, calc(100% - 2rem));
  padding: 1.25rem;
  border: 2px solid var(--green);
  border-radius: 1rem;
  background: var(--paper);
  color: var(--green);
  box-shadow: 4px 4px var(--green);
}
#sale-day-notice::backdrop { background: rgb(23 45 37 / 65%); }
#sale-day-rule { margin-block: .5rem 1rem; }
.controls { display: grid; gap: .45rem; margin-bottom: 1rem; }
label { font-weight: 700; }
input, button, textarea { font: inherit; }
input, textarea { width: 100%; min-height: 3rem; padding: .5rem .75rem; border: 1.5px solid var(--green); border-radius: .65rem; background: var(--paper); color: var(--green); }
textarea { resize: vertical; }
.view { display: flex; gap: .35rem; background: var(--mint); padding: .35rem; border: 1.5px solid var(--green); border-radius: .85rem; }
nav.view { position: sticky; top: .35rem; z-index: 1100; margin-bottom: 1.1rem; box-shadow: 3px 3px var(--green); }
button { cursor: pointer; }
.view button { flex: 1; min-height: 44px; border: 1px solid transparent; border-radius: .55rem; background: transparent; color: var(--green); font-weight: 800; }
.view button span { font-size: 1.14em; }
.view button[aria-pressed="true"] { background: var(--paper); border-color: var(--green); box-shadow: 2px 2px var(--green); }
.filters { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: .25rem; }
.filters button { display: inline-flex; align-items: center; gap: .3rem; min-height: 44px; padding: .25rem .65rem; border-radius: 2rem; border: 1px solid var(--green); background: var(--paper); color: var(--green); font-size: .88rem; font-weight: 750; }
.filters button[aria-pressed="true"] { background: var(--yellow); box-shadow: 2px 2px var(--green); }
.filters .garage { width: 1.1rem; height: 1.1rem; }
.filters .garage { --roof-height: .36rem; }
.layout { display: grid; align-items: start; gap: 1rem; }
#map-panel, #directory, .planner { background: var(--paper); border: 1.5px solid var(--green); border-radius: 1rem; box-shadow: 3px 3px var(--green); }
#map-panel { overflow: hidden; scroll-margin-top: 4.5rem; }
#map { height: clamp(300px, 58svh, 620px); background: #dce8e0; }
.legend { display: flex; flex-wrap: wrap; gap: .6rem 1.2rem; padding: .65rem .85rem; font-size: .9rem; font-weight: 750; background: var(--mint); border-bottom: 1px solid var(--green); }
.legend span, h3 { display: flex; align-items: center; gap: .5rem; }
.garage, .triangle { display: inline-grid; place-items: center; width: 1.55rem; height: 1.55rem; flex: none; }
.garage {
  --roof-height: .5rem;
  position: relative;
  isolation: isolate;
  padding-top: var(--roof-height);
  color: #382c06;
  font-size: .88rem;
  font-weight: 850;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}
.garage::before, .garage::after {
  content: "";
  position: absolute;
  z-index: -1;
  pointer-events: none;
}
.garage::before {
  inset: 0;
  background: #704719;
  clip-path: polygon(50% 0, 100% var(--roof-height), 100% calc(var(--roof-height) + 2px), 0 calc(var(--roof-height) + 2px), 0 var(--roof-height));
}
.garage::after {
  inset: var(--roof-height) 2px 0;
  border: 2px solid #704719;
  border-radius: 2px 2px 4px 4px;
  background: linear-gradient(to bottom, #f0bd36 0 2px, var(--yellow) 2px calc(100% - 2px), #f0bd36 calc(100% - 2px));
}
.header-art {
  display: flex;
  align-items: flex-end;
  gap: .55em;
  margin-top: .8rem;
  font-size: 1.05rem;
  color: var(--green);
}
.header-art > span { position: relative; flex: none; }
.find-bike { width: 2.9em; height: 1.85em; transform: rotate(-9deg); }
.find-bike::before, .find-bike::after {
  content: "";
  position: absolute;
  bottom: 0;
  width: 1em;
  height: 1em;
  border: .13em solid;
  border-radius: 50%;
  background: var(--paper);
}
.find-bike::before { left: 0; }
.find-bike::after { right: 0; }
.find-bike i {
  position: absolute;
  z-index: 1;
  inset: 0;
  background: var(--green);
  clip-path: polygon(10% 72%, 30% 31%, 22% 31%, 22% 21%, 45% 21%, 45% 31%, 36% 31%, 42% 39%, 67% 39%, 62% 17%, 61% 7%, 85% 7%, 85% 16%, 70% 16%, 88% 72%, 81% 75%, 70% 49%, 54% 76%, 21% 76%, 24% 66%, 49% 66%, 60% 48%, 39% 48%, 18% 75%);
}
.find-books {
  width: 1.45em;
  height: .45em;
  border: .1em solid;
  border-radius: .14em;
  background: var(--yellow);
  box-shadow: 0 -.42em 0 -.07em var(--paper), 0 -.42em 0 .035em var(--green),
              -.12em -.84em 0 -.07em var(--mint), -.12em -.84em 0 .035em var(--green);
  transform: rotate(7deg);
}
.find-lamp { width: 1.6em; height: 1.9em; transform: rotate(-7deg); }
.find-lamp::before {
  content: "";
  position: absolute;
  inset: 0 0 .95em;
  background: var(--green);
  clip-path: polygon(24% 0, 76% 0, 100% 100%, 0 100%);
  box-shadow: inset 0 -.25em 0 #245346;
}
.find-lamp::after {
  content: "";
  position: absolute;
  inset: .85em .25em 0;
  background: var(--green);
  clip-path: polygon(44% 0, 56% 0, 56% 78%, 90% 78%, 100% 100%, 0 100%, 10% 78%, 44% 78%);
}
.header-art .header-garage {
  display: block;
  width: 3.8em;
  height: 2.3em;
  --roof-height: .55em;
  padding: 0;
  font-size: inherit;
  transform: rotate(5deg);
}
.header-garage::before {
  background: var(--green);
}
.header-garage::after {
  border: .12em solid var(--green);
  background: var(--mint);
  border-radius: 0 0 .12em .12em;
}
.header-garage i {
  position: absolute;
  inset: .85em .42em .12em;
  border: .1em solid var(--green);
  border-radius: .16em .16em 0 0;
  background: repeating-linear-gradient(to bottom, var(--yellow) 0 .22em, #c18e28 .22em .28em);
}
.triangle { background: #08376f; clip-path: polygon(50% 4%, 100% 92%, 0 92%); position: relative; }
.triangle::after { content: ""; position: absolute; inset: 3px; background: var(--blue); clip-path: polygon(50% 0, 100% 100%, 0 100%); }
.icon-library { position: absolute; width: 0; height: 0; overflow: hidden; }
.food-glyph { width: 1.25rem; height: 1.25rem; flex: none; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.food-badge { width: 33px; height: 30px; padding-top: 9px; color: white; }
.food-badge .food-glyph { position: relative; z-index: 1; width: 15px; height: 15px; }
.stop-pin { display: grid; place-items: center; filter: drop-shadow(0 1px 2px #0006); }
.stop-pin .food-badge { width: 44px; height: 42px; padding-top: 13px; }
.stop-pin .food-glyph { width: 21px; height: 21px; }
.stop-pin .garage { --roof-height: 7px; width: 38px; height: 32px; font-size: 18px; }
.leaflet-popup-content { font-size: .95rem; }
.leaflet-popup-content p { margin: .3rem 0; }
#missing-pins, #map-error { margin: .65rem .85rem; font-size: .9rem; }
#missing-pins:empty { display: none; }
#directory { padding: .85rem; }
#count { color: #455c51; }
ul { padding: 0; margin: .55rem 0 0; list-style: none; }
li { padding: .8rem 0; border-top: 1px solid #dce6df; }
h3 { line-height: 1.25; margin-bottom: .35rem; }
dl { display: grid; grid-template-columns: max-content 1fr; gap: .15rem .55rem; margin: .4rem 0; }
dt { font-weight: 700; }
dd { margin: 0; }
.unresolved { font-weight: 700; color: #794709; }
.action, .leaflet-popup-content a.action { display: inline-flex; align-items: center; min-height: 44px; margin: .45rem .4rem 0 0; background: var(--yellow); color: var(--green); border: 1px solid var(--green); border-radius: .55rem; padding: .35rem .65rem; text-decoration: none; font-weight: 750; }
.action.secondary, .leaflet-popup-content a.action.secondary { background: var(--paper); color: var(--green); }
.action[aria-pressed="true"] { background: var(--mint); }
.action:active:not(:disabled), .view button:active, .filters button:active { translate: 1px 1px; box-shadow: none; }
@media (hover: hover) {
  .action:hover:not(:disabled), .filters button:hover, .view button:hover { background: var(--pink); }
}
:focus-visible { outline: 3px solid #1265c1; outline-offset: 2px; }
footer a { color: var(--green); }
.planner { margin-bottom: 1rem; }
.planner-body { padding: .85rem; }
.planner-body h2 { margin-bottom: .5rem; }
.add-item { display: flex; align-items: stretch; gap: .5rem; margin-top: .35rem; }
.add-item input { min-width: 0; }
.add-item .action { flex: none; margin: 0; }
#wishlist-items li { display: flex; align-items: center; gap: .5rem; padding: .35rem 0; }
.wishlist-check { display: flex; align-items: center; gap: .6rem; flex: 1; min-height: 44px; min-width: 0; overflow-wrap: anywhere; cursor: pointer; }
.wishlist-check input { width: 1.25rem; min-height: auto; height: 1.25rem; flex: none; accent-color: var(--green); }
.wishlist-check input:checked + span { text-decoration: line-through; color: #455c51; }
#wishlist-items .action { margin: 0; }
.saved-heading { border-top: 1px solid #dce6df; margin-top: 1rem; padding-top: .8rem; }
.planner-body textarea { display: block; margin: .35rem 0 .55rem; }
#planner-status:empty { display: none; }
#route-status:empty { display: none; }
#route-options, .route-links, #food-suggestions { margin-block: .65rem; }
.route-links:empty { display: none; }
.route-links { display: flex; flex-wrap: wrap; gap: .45rem; }
.route-note { margin-block: .35rem; }
#suggested-food-stops { list-style: none; padding: 0; }
#suggested-food-stops li { margin-block: .6rem; }
#suggested-food-stops p { margin-block: .2rem; }
#saved-stops { padding-left: 1.4rem; margin: .65rem 0; }
.action:disabled { opacity: .5; cursor: default; }
@media (min-width: 44rem) {
  .masthead h1 { max-width: calc(100% - 17rem); }
  .header-art { position: absolute; z-index: -1; right: 2rem; bottom: 1.25rem; font-size: clamp(1.35rem, 2.25vw, 2.2rem); }
}
@media (min-width: 52rem) {
  .masthead, main, footer { padding-inline: 1.5rem; }
  .layout:has(#map-panel:not([hidden])) { grid-template-columns: minmax(0, 2fr) minmax(18rem, 1fr); }
}
