@font-face { font-family: 'Fraunces'; font-weight: 400; font-display: swap; src: url('/fonts/fraunces-latin-400-normal.woff2') format('woff2'); }
@font-face { font-family: 'Fraunces'; font-weight: 600; font-display: swap; src: url('/fonts/fraunces-latin-600-normal.woff2') format('woff2'); }
@font-face { font-family: 'Instrument Sans'; font-weight: 400; font-display: swap; src: url('/fonts/instrument-sans-latin-400-normal.woff2') format('woff2'); }
@font-face { font-family: 'Instrument Sans'; font-weight: 500; font-display: swap; src: url('/fonts/instrument-sans-latin-500-normal.woff2') format('woff2'); }
@font-face { font-family: 'Instrument Sans'; font-weight: 600; font-display: swap; src: url('/fonts/instrument-sans-latin-600-normal.woff2') format('woff2'); }

:root {
  --bg: #FAF7F2; --surface: #FFFFFF; --soft: #F1ECE4; --line: #E8E1D6; --line-strong: #D8CFC1;
  --ink: #2A2420; --muted: #5E554C; --brand: #56705A; --accent: #B4530A; --accent-ink: #8A3E07;
  --green-bg: #E3EDE4; --green-ink: #2F5A3D; --blue-bg: #EAF0F4; --blue-ink: #2E4757; --warn-bg: #F9E4D2; --warn-ink: #8A3E07;
  --place: #3F6B4E; --toilet: #4F6676; --water: #2F82B0;
  --serif: 'Fraunces', Georgia, serif; --sans: 'Instrument Sans', system-ui, -apple-system, sans-serif;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #1F1C19; --surface: #29251F; --soft: #332E27; --line: #3A342C; --line-strong: #4A433A;
    --ink: #F3EDE3; --muted: #BDB3A6; --brand: #A9C2AC; --accent: #F0A15E; --accent-ink: #F0A15E;
    --green-bg: #2B3A2E; --green-ink: #BFD8C2; --blue-bg: #26303D; --blue-ink: #C9D4E0; --warn-bg: #45301F; --warn-ink: #F6C79A;
  }
}

* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 16px/1.5 var(--sans); -webkit-font-smoothing: antialiased; }
a { color: inherit; }
button { font: inherit; color: inherit; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }

.wrap { max-width: 640px; margin: 0 auto; padding: 0 16px; }
.app { padding-bottom: env(safe-area-inset-bottom); }

/* top of home */
.brandbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-top: 14px; }
.brand { margin: 0; font: 600 22px/1.2 var(--serif); letter-spacing: -0.3px; color: var(--brand); }
.heading { margin: 14px 0 12px; font: 400 32px/1.1 var(--serif); letter-spacing: -0.8px; }
.subheading { margin: 24px 0 6px; font: 600 18px/1.3 var(--serif); }
.kicker { margin: 0; font-size: 13px; font-weight: 600; letter-spacing: 1.4px; text-transform: uppercase; color: var(--accent-ink); }
.label { margin: 0 0 10px; font-size: 13px; font-weight: 600; letter-spacing: 1.2px; text-transform: uppercase; color: var(--accent-ink); }
.muted { color: var(--muted); }
.small { font-size: 14px; line-height: 1.45; }

/* chips and buttons */
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 16px; border-radius: 999px; border: 1.5px solid var(--line-strong); background: transparent; font-size: 15px; font-weight: 600; cursor: pointer; text-decoration: none; }
.chip[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.chip--more { background: var(--soft); border-color: var(--soft); }
.badge { min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px; background: var(--accent); color: #fff; font-size: 12px; display: inline-flex; align-items: center; justify-content: center; }
.pill-btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 44px; padding: 0 18px; border-radius: 999px; border: none; background: var(--ink); color: var(--bg); text-decoration: none; font-size: 15px; font-weight: 600; cursor: pointer; }
.pill-btn--soft { background: var(--soft); color: var(--ink); }
.pill-btn--wide { width: 100%; min-height: 52px; font-size: 16px; }
.round-btn { width: 44px; height: 44px; flex: none; border-radius: 50%; background: var(--soft); display: inline-flex; align-items: center; justify-content: center; color: var(--ink); }

.dog-switch { display: inline-flex; align-items: center; gap: 8px; min-height: 40px; padding: 0 6px 0 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); font-size: 13px; font-weight: 600; cursor: pointer; }
.dog-switch--row { width: 100%; justify-content: space-between; min-height: 60px; padding: 0 16px; border-radius: 16px; margin-top: 24px; text-align: left; }
.dog-switch__text { display: flex; flex-direction: column; gap: 2px; }
.dog-switch__label { font-size: 15px; }
.dog-switch__hint { font-size: 13px; font-weight: 400; color: var(--muted); }
.switch { width: 38px; height: 24px; flex: none; border-radius: 999px; background: var(--line-strong); position: relative; transition: background .2s; }
.switch__knob { position: absolute; left: 3px; top: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; transition: transform .2s; }
[aria-pressed="true"] > .switch { background: var(--place); }
[aria-pressed="true"] > .switch .switch__knob { transform: translateX(14px); }

/* map */
.map { margin-top: 16px; height: 42vh; min-height: 260px; max-height: 460px; border-radius: 20px; overflow: hidden; background: var(--soft); border: 1px solid var(--line); }
.map--off { display: none; }
.legend { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; margin: 10px 0 4px; font-size: 13px; font-weight: 600; color: var(--muted); }
.legend__item { display: inline-flex; align-items: center; gap: 6px; }
.dot { width: 12px; height: 12px; border-radius: 50%; border: 2px solid var(--surface); box-shadow: 0 0 0 1px var(--line-strong); }
.dot--place { background: var(--place); } .dot--toilet { background: var(--toilet); } .dot--water { background: var(--water); } .dot--dog { background: #B4530A; }
.near-me { margin-left: auto; display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); font-size: 13px; font-weight: 600; cursor: pointer; }
.near-me:disabled { opacity: .7; cursor: progress; }
.maplibregl-ctrl-attrib { font: 11px var(--sans); }

/* list */
.list { display: flex; flex-direction: column; gap: 10px; padding-top: 12px; }
.card { display: flex; gap: 12px; padding: 12px; border-radius: 18px; background: var(--surface); border: 1px solid var(--line); text-decoration: none; color: inherit; }
.card:hover { border-color: var(--line-strong); }
.card--dog { background: var(--soft); }
.card__img { width: 72px; height: 72px; flex: none; border-radius: 12px; object-fit: cover; background: var(--soft); }
.card__body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.card__head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.card__name { font-weight: 600; font-size: 17px; line-height: 1.25; }
.card__dist { flex: none; font-size: 13px; font-weight: 600; color: var(--muted); }
.card__kind { font-size: 13px; font-weight: 600; color: var(--muted); }
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 2px; }
.tag { display: inline-flex; align-items: center; gap: 5px; padding: 2px 9px; border-radius: 999px; background: var(--soft); color: var(--muted); font-size: 12px; font-weight: 600; }
.tag--lg { padding: 6px 12px; font-size: 13px; }
.tag--free { background: var(--green-bg); color: var(--green-ink); }
.tag--facility { background: var(--blue-bg); color: var(--blue-ink); }
.tag--warn { background: var(--warn-bg); color: var(--warn-ink); }
.show-more { align-self: center; margin-top: 4px; }
.empty { padding: 24px 0; text-align: center; color: var(--muted); }

/* placeholders: words in brackets until person-made symbols exist */
.placeholder { display: flex; align-items: center; justify-content: center; font: 600 12px var(--sans); color: var(--muted); letter-spacing: .3px; }
.placeholder--nature, .placeholder--urban, .placeholder--gardens { background: var(--green-bg); color: var(--green-ink); }
.placeholder--water { background: var(--blue-bg); color: var(--blue-ink); }

/* pages */
.page { padding-bottom: 24px; }
.topbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-top: 16px; flex-direction: row-reverse; }
.page--dog .topbar, .page--about .topbar { flex-direction: row; }
.topbar__title { margin: 0; font: 400 30px/1.1 var(--serif); letter-spacing: -0.6px; }
.group { margin-top: 24px; }
.seg { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 4px; padding: 4px; border-radius: 14px; background: var(--soft); }
.seg__btn { min-height: 42px; border: none; border-radius: 10px; background: transparent; font-weight: 600; font-size: 14px; cursor: pointer; }
.seg__btn[aria-pressed="true"] { background: var(--surface); box-shadow: 0 1px 2px rgba(0,0,0,.08); }
.sticky-cta { position: sticky; bottom: 0; margin: 28px -16px 0; padding: 14px 16px calc(18px + env(safe-area-inset-bottom)); background: var(--bg); border-top: 1px solid var(--line); }

.hero { position: relative; margin: 0 -16px; height: 260px; background: var(--soft); }
.hero__img { width: 100%; height: 100%; object-fit: cover; display: block; font-size: 15px; }
.hero__back { position: absolute; left: 16px; top: 16px; background: var(--bg); }
.hero__credit { position: absolute; left: 0; right: 0; bottom: 0; padding: 8px 16px; background: rgba(42,36,32,.75); color: #FAF7F2; font-size: 11px; line-height: 1.35; text-decoration: none; }
@media (min-width: 672px) { .hero { margin: 16px 0 0; border-radius: 20px; overflow: hidden; } }
.place { display: flex; flex-direction: column; gap: 12px; padding-top: 20px; }
.place__name { margin: -6px 0 0; font: 400 34px/1.1 var(--serif); letter-spacing: -0.6px; }
.place .muted { margin: -4px 0 0; }
.links { display: flex; flex-wrap: wrap; gap: 8px; }
.place__foot { margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--line); }
.place__foot p { margin: 0 0 6px; }
.fix { font-size: 14px; font-weight: 600; color: var(--accent-ink); }

.panel { margin-top: 16px; padding: 16px; border-radius: 18px; background: var(--surface); border: 1px solid var(--line); display: flex; flex-direction: column; gap: 10px; }
.panel p { margin: 0; }
.panel__head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.panel__title { margin: 0; font-size: 16px; font-weight: 600; }
.months { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 3px; }
.months__m { display: flex; flex-direction: column; align-items: center; gap: 4px; }
.months__bar { width: 100%; height: 24px; border-radius: 6px; background: var(--soft); }
.months__bar--ok { background: var(--place); }
.months__m--now .months__bar { box-shadow: 0 0 0 2px var(--surface), 0 0 0 4px var(--accent); }
.months__l { font-size: 10px; font-weight: 600; color: var(--muted); }
.months__m--now .months__l { color: var(--accent-ink); }
.season { position: relative; height: 10px; border-radius: 999px; background: var(--soft); margin: 4px 0; }
.season__band { position: absolute; top: 0; bottom: 0; border-radius: 999px; background: #E3B98F; }
.season__today { position: absolute; top: -4px; width: 18px; height: 18px; margin-left: -9px; border-radius: 50%; background: var(--ink); border: 3px solid var(--surface); }
.season__axis { display: flex; justify-content: space-between; font-size: 12px; font-weight: 600; color: var(--muted); }
.rows { list-style: none; margin: 0; padding: 0; }
.row { display: flex; justify-content: space-between; gap: 8px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.row:last-child { border-bottom: none; }
.row__name { font-weight: 600; }
.credits { padding-left: 20px; }
.credits li { margin: 4px 0; }

/* footer, status */
.footer { margin-top: 32px; padding: 18px 0 28px; border-top: 1px solid var(--line); text-align: center; }
.footer p { margin: 4px 0; }
.footer__slogan { font: 400 16px var(--serif); }
.footer__line, .footer__links { font-size: 12px; color: var(--muted); }
.langs { display: inline-flex; gap: 2px; align-items: center; }
.lang { border: none; background: none; padding: 6px 4px; font-size: 12px; font-weight: 600; color: var(--muted); cursor: pointer; }
.lang[aria-pressed="true"] { color: var(--ink); text-decoration: underline; }
.status { padding-top: 40vh; text-align: center; color: var(--muted); }
.note { position: fixed; left: 16px; right: 16px; bottom: calc(16px + env(safe-area-inset-bottom)); max-width: 560px; margin: 0 auto; padding: 12px 16px; border-radius: 14px; background: var(--ink); color: var(--bg); font-size: 14px; z-index: 10; }

@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
.placeholder.hero__img { display: flex; font-size: 15px; }

/* small phones: keep the brand and the dog switch on one line each */
.brand, .dog-switch:not(.dog-switch--row) { white-space: nowrap; }
@media (max-width: 380px) { .brand { font-size: 20px; } .dog-switch:not(.dog-switch--row) { font-size: 12px; gap: 6px; } }
.fix { display: inline-flex; align-items: center; min-height: 44px; }
