/* ---------- Walk the dog: Nintendogs-style stroll around C.A.R.E. in Skokie ---------- */
#walk { position: fixed; inset: 0; z-index: 50; background: rgba(20, 30, 50, .72); backdrop-filter: blur(4px); display: grid; place-items: center; padding: 12px; }
#walk[hidden] { display: none; }
body.walk-open { overflow: hidden; }
.walk-stage { position: relative; width: min(480px, 100%); background: linear-gradient(180deg, #eef7e6 0%, #dff0d3 100%); border-radius: 22px; padding: 14px 14px 18px; box-shadow: 0 24px 60px rgba(0,0,0,.35); color: #1f2a1f; }
.walk-close { position: absolute; top: 10px; right: 10px; width: 34px; height: 34px; border-radius: 50%; border: 0; background: rgba(0,0,0,.08); font-size: 16px; cursor: pointer; color: inherit; z-index: 3; }
.walk-title { margin: 4px 36px 6px 4px; font-size: 18px; }
.walk-scene { position: relative; aspect-ratio: 10 / 9; border-radius: 16px; overflow: hidden; touch-action: none; user-select: none; -webkit-user-select: none; cursor: grab; background: #cfe6b8; }
.walk-scene.walking { cursor: grabbing; }
.walk-map { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.walk-layer { position: absolute; inset: 0; pointer-events: none; }
.walk-layer svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }

/* map art */
.map-block { fill: #f3ead6; stroke: #e2d6bd; stroke-width: .6; }
.map-park { fill: #9fd18a; stroke: #7fbd6a; stroke-width: .8; }
.map-water { fill: #8fc7ea; }
.map-road { stroke: #ffffff; stroke-width: 7; stroke-linecap: round; fill: none; }
.map-road-minor { stroke: #ffffff; stroke-width: 4; stroke-linecap: round; fill: none; }
.map-road-edge { stroke: #d9d3c4; stroke-width: 8.5; stroke-linecap: round; fill: none; }
.map-dash { stroke: #e8d27a; stroke-width: .9; stroke-dasharray: 4 4; fill: none; }
.map-rail { stroke: #7b7b8a; stroke-width: 2.2; stroke-dasharray: 5 3; fill: none; }
.map-label { font: 600 6.5px/1 system-ui, sans-serif; fill: #6b6457; letter-spacing: .3px; }
.map-label.big { font-size: 8px; fill: #4f4a40; }
.map-poi { font: 700 7px/1 system-ui, sans-serif; fill: #2c3e2c; }
.map-tree { fill: #6fb45a; }
.map-tree-trunk { fill: #8b6a3e; }
.map-bld { fill: #d8cbb0; stroke: #b9a98a; stroke-width: .6; }
.map-bld.roof { fill: #c96a4e; }
.map-shelter { fill: #ffd8c2; stroke: #e4572e; stroke-width: 1.2; }
.map-hydrant { fill: #e4572e; }

/* waypoints and home */
.wp { position: absolute; width: 34px; height: 34px; margin: -17px 0 0 -17px; display: grid; place-items: center; font-size: 20px; border-radius: 50%; background: rgba(255,255,255,.9); box-shadow: 0 3px 8px rgba(0,0,0,.2), 0 0 0 3px rgba(228,87,46,.35); transition: transform .3s, background .3s; animation: wp-bob 1.6s ease-in-out infinite; }
.wp.visited { background: #2a9d8f; color: #fff; animation: none; transform: scale(.9); box-shadow: 0 3px 8px rgba(0,0,0,.2); }
.wp.visited::after { content: "✓"; position: absolute; inset: 0; display: grid; place-items: center; font-size: 18px; font-weight: 800; color: #fff; }
.wp.visited span { visibility: hidden; }
.wp.home { background: #ffe9d6; box-shadow: 0 3px 8px rgba(0,0,0,.2), 0 0 0 3px rgba(228,87,46,.6); animation: none; }
.wp.home.ready { animation: wp-bob 1s ease-in-out infinite; box-shadow: 0 3px 8px rgba(0,0,0,.2), 0 0 0 4px #2a9d8f; }
@keyframes wp-bob { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-5px); } }
.wp-label { position: absolute; top: 20px; left: 50%; transform: translateX(-50%); white-space: nowrap; font: 700 10px/1 system-ui, sans-serif; color: #2c3e2c; background: rgba(255,255,255,.85); padding: 2px 6px; border-radius: 999px; }

/* the dog token */
.walk-dog { position: absolute; width: 58px; height: 58px; margin: -29px 0 0 -29px; border-radius: 50%; z-index: 4; pointer-events: none;
  background: radial-gradient(circle at 35% 30%, #fff1c2 0%, #f3c64f 45%, #c99324 100%);
  box-shadow: inset 0 0 0 4px #d9a93a, inset 0 0 0 5px #fff0b5, 0 6px 10px rgba(0,0,0,.28); }
.walk-dog img { width: 100%; height: 100%; object-fit: contain; padding: 5px; display: block; border-radius: 50%; transition: transform .15s; }
.walk-dog.flip img { transform: scaleX(-1); }
.walk-dog.moving { animation: trot .32s ease-in-out infinite; }
@keyframes trot { 0%,100% { transform: translateY(0) rotate(-3deg); } 50% { transform: translateY(-4px) rotate(3deg); } }
.walk-dog .bubble { position: absolute; left: 50%; bottom: 100%; transform: translate(-50%, -4px); white-space: nowrap; font: 600 11px/1 system-ui, sans-serif; background: #fff; color: #333; padding: 4px 8px; border-radius: 10px; box-shadow: 0 2px 6px rgba(0,0,0,.2); opacity: 0; transition: opacity .2s; }
.walk-dog .bubble.show { opacity: 1; }
.paw { position: absolute; font-size: 11px; margin: -6px 0 0 -6px; opacity: .8; animation: paw-fade 3s linear forwards; pointer-events: none; z-index: 3; }
@keyframes paw-fade { to { opacity: 0; } }
.leash-handle { position: absolute; width: 22px; height: 22px; margin: -11px 0 0 -11px; border-radius: 50%; background: #e4572e; box-shadow: 0 0 0 4px rgba(228,87,46,.35); z-index: 5; pointer-events: none; opacity: 0; transition: opacity .15s; }
.walk-scene.walking .leash-handle { opacity: 1; }
.leash { stroke: #e4572e; stroke-width: 3; fill: none; stroke-linecap: round; opacity: 0; transition: opacity .15s; }
.walk-scene.walking .leash { opacity: 1; }
.leash.tight { stroke: #c0392b; stroke-dasharray: 2 3; }

/* HUD */
.walk-hud { display: flex; justify-content: space-between; gap: 8px; margin: 10px 4px 0; font-size: 14px; }
.walk-hud strong { color: #2a9d8f; }
.walk-meter { height: 12px; margin: 8px 4px 6px; background: rgba(0,0,0,.08); border-radius: 6px; overflow: hidden; }
.walk-meter i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, #9fd18a, #2a9d8f); transition: width .2s linear; }
.walk-msg { margin: 0 4px; font-size: 14px; min-height: 1.4em; }
.walk-done { display: none; margin: 10px auto 0; padding: 9px 18px; border: 0; border-radius: 999px; background: #e4572e; color: #fff; font: inherit; font-weight: 700; cursor: pointer; }
.walk-stage.finished .walk-done { display: block; }
.walk-stage.finished .walk-scene { cursor: default; }
.walk-sparkle { position: absolute; z-index: 8; font-size: 22px; animation: walk-sparkle 1.4s ease-out forwards; pointer-events: none; }
@keyframes walk-sparkle { 0% { transform: scale(0); opacity: 0; } 30% { opacity: 1; } 100% { transform: scale(1.4) translateY(-30px); opacity: 0; } }

/* card bits */
.walk-btn { margin-top: 8px; padding: 7px 12px; border-radius: 999px; border: 1px solid var(--line, #d9d4ca); background: var(--card, #fff); color: var(--ink, #1f1d1a); font: inherit; cursor: pointer; }
.walk-btn:hover { border-color: #9fd18a; }
.pill.walked { background: #e2f5d9; color: #2f6b2f; }
.pill.walked[hidden] { display: none; }
@media (prefers-reduced-motion: reduce) { .wp, .walk-dog.moving { animation: none; } }
