/* Two Worlds — the dot map (home Travel side and the atlas). Loaded after base.css. Behaviour: js/land.js + js/home.js. */
.map { position: relative; width: 100%; height: clamp(380px, 64vh, 680px); overflow: hidden; background: #121417; border: 1px solid var(--line); touch-action: pan-y; cursor: grab; user-select: none; -webkit-user-select: none; }
.map.dragging { cursor: grabbing; } .map.over-pin { cursor: pointer; }
.map > canvas, .map-layer { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.zoom { position: absolute; right: 14px; bottom: 14px; display: flex; flex-direction: column; gap: 8px; z-index: 6; }
.zoom button { -webkit-user-select: none; user-select: none; touch-action: manipulation; width: 44px; height: 44px; border: 1px solid #4C5157; border-radius: 50%; background: var(--ink); color: var(--paper); font: inherit; font-size: 20px; line-height: 1; cursor: pointer; }
.zoom button:hover, .zoom button[aria-pressed="true"] { background: var(--paper); color: var(--ink); }
.pin { position: absolute; width: 44px; height: 44px; margin: -22px 0 0 -22px; padding: 0; border: 0; background: transparent; pointer-events: none; display: flex; align-items: center; justify-content: center; }
.pin i { display: block; width: 12px; height: 12px; border-radius: 50%; background: var(--paper); transition: width .35s ease, height .35s ease, background-color .35s ease, box-shadow .35s ease; }
.pin.hot i { width: 16px; height: 16px; box-shadow: 0 0 0 8px rgba(241,238,231,.14); }
.pin-label { position: absolute; transform: translate(20px, -50%); padding: 5px 12px; border-radius: 999px; background: var(--paper); color: var(--ink); font-size: 13px; white-space: nowrap; pointer-events: none; opacity: 0; }
.pin:focus-visible + .pin-label { opacity: 1; }
@media (max-width: 700px) { .map { height: 380px; } }
.map-cap { margin: 10px 0 0; font-size: 12px; color: #6B6F6C; } .map-cap a { border-bottom: 1px solid currentColor; }

/* map: one dot per article, styled by kind */
.pin[aria-pressed="true"] i { width: 16px; height: 16px; background: var(--paper); box-shadow: 0 0 0 8px rgba(241,238,231,.16); }
.pin.k-music::before { content: ""; position: absolute; width: 20px; height: 20px; box-sizing: border-box; border: 2px solid var(--indigo-light); border-radius: 50%; transition: width .35s ease, height .35s ease; }
.pin.k-music[aria-pressed="true"]::before, .pin.k-music.hot::before { width: 28px; height: 28px; }
.pin.k-music:not(.k-been):not(.k-next) i { width: 0; height: 0; box-shadow: none; }
.pin.k-next i, .pin.k-next[aria-pressed="true"] i { width: 8px; height: 8px; background: rgba(79,193,182,.75); box-shadow: none; }
.pin.k-next.hot i { width: 11px; height: 11px; }
/* the upcoming journey's dot carries its own small label, so it doesn't read as a stray dot */
.pin.k-next + .pin-label { opacity: 1; transform: translate(12px, -50%); padding: 2px 8px; font-size: 11px; background: rgba(12,13,15,.85); color: var(--oxide-light); }
.pin.k-next.hot + .pin-label { background: var(--paper); color: var(--ink); }
.legend { position: absolute; left: 14px; bottom: 14px; z-index: 5; display: flex; flex-direction: column; gap: 8px; padding: 12px 14px; background: rgba(12,13,15,.86); border: 1px solid var(--rule); font-size: 12px; line-height: 1.3; color: var(--soft); pointer-events: none; }
.legend > span { display: flex; align-items: center; gap: 10px; }
.legend .lg-t { font-size: 11px; font-weight: 500; letter-spacing: .02em; color: var(--mute); }
.legend .lg-sym { flex: 0 0 auto; width: 10px; height: 10px; box-sizing: border-box; border-radius: 50%; }
.legend .lg-music { border: 2px solid var(--indigo-light); }
.legend .lg-been { background: var(--paper); }
.legend .lg-both { background: var(--paper); box-shadow: 0 0 0 2px #121417, 0 0 0 4px var(--indigo-light); }
.legend .lg-route { width: 20px; height: 0; border-radius: 0; border-top: 2px dashed #4FC1B6; }
.legend .lg-next { width: 20px; height: 0; border-radius: 0; border-top: 1.5px dashed rgba(79,193,182,.7); }

/* hover preview: rolling photo carousel */
.peek { position: absolute; z-index: 5; width: 240px; transform: translate(22px, -50%) scale(.96); background: var(--paper); color: #111214; box-shadow: 0 18px 40px rgba(0,0,0,.45); opacity: 0; pointer-events: none; transition: opacity .25s ease, transform .35s cubic-bezier(.2,.7,.2,1); }
.peek.show { opacity: 1; transform: translate(22px, -50%); pointer-events: auto; }
.peek.left { transform: translate(calc(-100% - 22px), -50%) scale(.96); } .peek.left.show { transform: translate(calc(-100% - 22px), -50%); }
.peek.below { transform: translate(-50%, 26px) scale(.96); } .peek.below.show { transform: translate(-50%, 26px); }
.peek-imgs { position: relative; aspect-ratio: 4 / 3; overflow: hidden; background: #DDD7CB; }
.peek-imgs img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transform: scale(1.08); transition: opacity .6s ease, transform 2.6s ease; }
.peek-imgs img.on { opacity: 1; transform: none; }
.peek-dots { position: absolute; left: 10px; right: 10px; top: 10px; display: flex; gap: 3px; }
.peek-dots i { flex: 1; height: 2px; background: rgba(255,255,255,.35); } .peek-dots i.on { background: #fff; }
.peek-txt { padding: 10px 12px 12px; display: flex; flex-direction: column; gap: 2px; }
.peek-txt b { font-family: var(--serif); font-weight: 400; font-size: 20px; line-height: 1.1; }
.peek-txt span { font-family: var(--sans); font-size: 10px; letter-spacing: .02em; color: var(--oxide); }
.peek-txt em i { font-style: italic; }
.peek-txt em { display: flex; flex-direction: column; margin-top: 4px; font-style: normal; font-size: 12px; } .peek-txt em:empty { display: none; }
.peek-txt em a { display: block; padding: 8px 0; color: var(--ink-soft); text-decoration: none; border-top: 1px solid rgba(17,18,20,.1); }
.peek-txt em a:hover, .peek-txt em a:focus-visible { color: var(--oxide); }
@media (prefers-reduced-motion: reduce) { .peek, .peek-imgs img { transition: none; } }

/* narrow maps (phones): the preview is a card along the bottom of the map, opened by a tap */
.peek.sheet, .peek.sheet.show { left: 10px; right: 10px; bottom: 10px; top: auto; width: auto; z-index: 7; display: grid; grid-template-columns: 38% 1fr; transform: translateY(12px); }
.peek.sheet.show { transform: none; }
.peek.sheet .peek-imgs { aspect-ratio: auto; min-height: 150px; }
.peek.sheet .peek-dots { right: auto; width: calc(38% - 20px); }
.peek.sheet .peek-txt { padding-right: 40px; }
.peek-close { position: absolute; top: 4px; right: 4px; width: 44px; height: 44px; border: 0; background: none; color: var(--ink-soft); font: inherit; font-size: 22px; line-height: 1; cursor: pointer; }

/* the same links as the dots, as a plain list (made by tools/build.py). Shown without JavaScript;
   with it, hidden until it gets keyboard focus, then shown over the top-left of the map. */
.place-index { position: absolute; left: 14px; top: 14px; z-index: 8; max-width: min(420px, calc(100% - 28px)); max-height: calc(100% - 28px); overflow: auto; padding: 14px 16px; background: rgba(12,13,15,.94); border: 1px solid var(--rule); font-size: 13px; line-height: 1.35; }
.place-index ul { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 12px; }
.place-index li { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 12px; }
.place-index .pi-name { font-family: var(--serif); font-size: 18px; color: var(--paper); }
.place-index .pi-when { flex-basis: 100%; order: 1; font-size: 11px; color: var(--mute); }
.place-index a { order: 2; display: inline-block; padding: 7px 0; color: var(--soft); text-decoration: none; border-bottom: 1px solid var(--rule); }
.place-index a:hover, .place-index a:focus-visible { color: var(--oxide-light); }
.map.has-js .place-index:not(:focus-within) { clip-path: inset(50%); width: 1px; height: 1px; padding: 0; border: 0; overflow: hidden; white-space: nowrap; }
