:root {
  --spruce: #13261F;      /* night forest: header, map, dark bands */
  --spruce-2: #1C352C;
  --spruce-3: #27463A;
  --lichen: #C9D3A4;      /* text on dark */
  --lantern: #F2B33D;     /* pins, buttons, the one bright thing */
  --lantern-2: #FFD27A;
  --mist: #E4EBE6;        /* light reading areas */
  --mist-2: #D3DED7;
  --ink: #15241E;         /* text on light */
  --muted-d: #8FA394;
  --muted-l: #4D6157;
  --red: #E5483B;
  --c-hominid: #D9A05B; --c-canid: #D0633F; --c-winged: #B98ACB; --c-aquatic: #4FB3A9;
  --c-entity: #9CC46B; --c-fae: #E58FB0; --c-ufo: #8E8CF0; --c-other: #E0C36A;
  --display: "Zilla Slab", Rockwell, "Roboto Slab", Georgia, serif;
  --body: "Public Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --r-sm: 6px; --r-md: 12px;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--spruce); color: var(--lichen); font: 400 1.0625rem/1.6 var(--body); }
a { color: var(--lantern); text-underline-offset: 3px; }
a:hover { color: var(--lantern-2); }
:focus-visible { outline: 3px solid var(--lantern); outline-offset: 2px; border-radius: 4px; }
img, svg { max-width: 100%; }
h1, h2, h3 { font-family: var(--display); font-weight: 700; line-height: 1.12; margin: 0 0 .5em; letter-spacing: -.005em; }
h1 { font-size: clamp(2rem, 5vw, 3.25rem); }
h2 { font-size: clamp(1.45rem, 3vw, 1.9rem); margin-top: 1.6em; }
h3 { font-size: 1.2rem; }
p { margin: 0 0 1em; }
.skip { position: absolute; left: -999px; top: 0; background: var(--lantern); color: var(--spruce); padding: .5em 1em; z-index: 99; }
.skip:focus { left: 8px; top: 8px; }
/* Pinned to the corner of the nearest positioned box: unpinned, a hidden label near the right edge stretched the page sideways on 320px phones. */
.visually-hidden { position: absolute; left: 0; top: 0; width: 1px; height: 1px; margin: -1px; padding: 0; border: 0; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }
.small { font-size: .875rem; }
.muted { color: var(--muted-d); }
.band-mist .muted { color: var(--muted-l); }

/* header */
.top { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: .7rem clamp(16px, 3vw, 28px); background: rgba(19, 38, 31, .94); backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--spruce-3); }
.brand { display: flex; align-items: center; gap: .55rem; font: 700 1.3rem var(--display); color: var(--lichen); text-decoration: none; white-space: nowrap; }
.brand:hover { color: #fff; }
.lantern { width: 14px; height: 14px; border-radius: 50%; background: var(--lantern);
  box-shadow: 0 0 0 4px rgba(242, 179, 61, .18), 0 0 18px 4px rgba(242, 179, 61, .55); flex: none; }
.nav { display: flex; gap: .2rem; overflow-x: auto; scrollbar-width: none; }
.nav a, .nav-dd summary { color: var(--lichen); text-decoration: none; font-weight: 600; font-size: .95rem; padding: .45rem .7rem; border-radius: 999px; white-space: nowrap; }
.nav a:hover { background: var(--spruce-2); color: #fff; }
.nav a[aria-current] { color: var(--spruce); background: var(--lichen); }
@media (max-width: 720px) {
  .top { flex-wrap: wrap; padding-bottom: .4rem; }
  .nav { width: 100%; margin: 0 -6px; }
  .nav a, .nav-dd summary { font-size: .9rem; padding: .35rem .6rem; }
}

/* bands */
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 clamp(16px, 3vw, 28px); }
.band { padding: clamp(2.5rem, 6vw, 4.5rem) 0; }
.band-dark { background: var(--spruce); color: var(--lichen); }
.band-mist { background: var(--mist); color: var(--ink); }
.band-mist a { color: #7A4E00; }
.band-mist a:hover { color: #A86A00; }
.band-mist h2 { color: var(--spruce); }
.lede { font-size: clamp(1.1rem, 2.2vw, 1.3rem); max-width: 62ch; color: var(--lichen); }
.lede-dark { font-size: 1.15rem; max-width: 62ch; color: var(--muted-l); margin-top: -.3em; }
.crumb { font-size: .9rem; color: var(--muted-d); margin-bottom: .6rem; }
.crumb a { color: var(--muted-d); }
.btn { display: inline-flex; align-items: center; gap: .5rem; font: 700 1rem var(--body); background: var(--lantern); color: var(--spruce) !important;
  border: 0; border-radius: 999px; padding: .7rem 1.25rem; text-decoration: none; cursor: pointer; }
.btn:hover { background: var(--lantern-2); }
.btn-ghost { background: transparent; color: var(--lichen) !important; box-shadow: inset 0 0 0 2px var(--lichen); }
.btn-ghost:hover { background: var(--spruce-2); }

/* map hero */
.hero-map { position: relative; height: calc(100svh - 58px); min-height: 520px; background: #0E1D18; }
.hero-map.full { height: calc(100svh - 58px); }
.hero-map .map { position: absolute; inset: 0; }
.map-panel { position: absolute; left: clamp(12px, 3vw, 32px); bottom: clamp(12px, 4vw, 40px); max-width: 430px;
  background: rgba(19, 38, 31, .9); backdrop-filter: blur(6px); border: 1px solid var(--spruce-3); border-radius: var(--r-md);
  padding: 1.2rem 1.3rem 1.3rem; box-shadow: 0 18px 50px rgba(0, 0, 0, .45); }
.map-panel h1 { font-size: clamp(1.7rem, 4.2vw, 2.4rem); color: #F3F1DA; }
.map-panel p { color: var(--lichen); margin-bottom: .9rem; }
.map-panel.compact h1 { font-size: 1.5rem; }
.map-actions { display: flex; flex-wrap: wrap; gap: .6rem; }
@media (max-width: 720px) {
  .hero-map { height: calc(100svh - 96px); }
  .map-panel { right: 12px; left: 12px; bottom: 12px; max-width: none; padding: 1rem; }
  .map-panel h1 { font-size: 1.55rem; }
}
.maplibregl-popup-content { background: var(--spruce); color: var(--lichen); border: 1px solid var(--spruce-3); border-radius: var(--r-md);
  font: 400 .95rem/1.45 var(--body); padding: .8rem 1rem; box-shadow: 0 10px 30px rgba(0,0,0,.5); }
.maplibregl-popup-tip { border-top-color: var(--spruce) !important; border-bottom-color: var(--spruce) !important; }
.maplibregl-popup-close-button { color: var(--lichen); font-size: 1.3rem; padding: 0 6px; }
.pop-h { font: 700 1.05rem var(--display); color: #F3F1DA; margin: 0 0 .15rem; }
.pop-kind { display: flex; align-items: center; gap: .4rem; font-size: .8rem; color: var(--muted-d); margin-bottom: .4rem; }
.pop-kind .ico { width: 18px; height: 18px; color: var(--c-ufo); --eye: var(--lantern); }
.pop a { font-weight: 600; }
.pop .approx { font-size: .8rem; color: var(--muted-d); }
.map-layers { position: absolute; top: 12px; right: 12px; display: flex; flex-direction: column; align-items: flex-end; gap: .4rem; z-index: 2; }
.layer-chip { display: inline-flex; align-items: center; gap: .5rem; font: 600 .85rem var(--body); color: var(--lichen);
  background: rgba(19,38,31,.92); border: 1px solid var(--spruce-3); border-radius: 999px; padding: .4rem .8rem; cursor: pointer; }
.layer-chip .swatch { width: .8rem; height: .8rem; border-radius: 50%; box-shadow: 0 0 8px currentColor; }
.layer-chip[aria-pressed="false"] { opacity: .55; }
.layer-chip[aria-pressed="false"] .swatch { background: transparent !important; box-shadow: inset 0 0 0 2px var(--muted-d); }
.pop-meta { margin: 0 0 .4rem; }
.me-dot { width: 16px; height: 16px; border-radius: 50%; background: #7FD3FF; border: 3px solid #fff; box-shadow: 0 0 0 6px rgba(127,211,255,.3); }
@media (max-width: 720px) { .map-layers { top: 8px; right: 8px; } .layer-chip { font-size: .78rem; padding: .3rem .6rem; } }
.maplibregl-ctrl-attrib { font-size: 11px; }

/* creature badges */
.ico { width: 100%; height: 100%; display: block; }
.art-ico { background: currentColor; -webkit-mask: var(--m) center / contain no-repeat; mask: var(--m) center / contain no-repeat; }
.ico-inline { display: inline-block; width: 1.3em; height: 1.3em; vertical-align: -.3em; margin-right: .2em; color: var(--c-ufo); }
.ico-lg { width: 64px; height: 64px; color: var(--lichen); --bg: var(--spruce); --eye: var(--lantern); margin-bottom: .6rem; }
.badge { display: inline-grid; place-items: center; border-radius: 50%; background: var(--spruce); flex: none;
  --bg: var(--spruce); --eye: var(--lantern); --eye-red: #FF5A44; }
.badge .ico { width: 70%; height: 70%; }
.badge-md { width: 64px; height: 64px; }
.badge-xl { width: clamp(110px, 18vw, 168px); height: clamp(110px, 18vw, 168px); box-shadow: 0 0 0 6px var(--spruce-2), 0 0 60px rgba(242,179,61,.18); }
.cat-hominid .ico, .badge.cat-hominid { color: var(--c-hominid); }
.cat-canid .ico, .badge.cat-canid { color: var(--c-canid); }
.cat-winged .ico, .badge.cat-winged { color: var(--c-winged); }
.cat-aquatic .ico, .badge.cat-aquatic { color: var(--c-aquatic); }
.cat-entity .ico, .badge.cat-entity { color: var(--c-entity); }
.cat-fae .ico, .badge.cat-fae { color: var(--c-fae); }
.cat-ufo .ico, .badge.cat-ufo { color: var(--c-ufo); }
.cat-other .ico, .badge.cat-other { color: var(--c-other); }
.dot { display: inline-block; width: .7em; height: .7em; border-radius: 50%; margin-right: .45em; vertical-align: .05em; }
.dot.cat-hominid { background: var(--c-hominid); } .dot.cat-canid { background: var(--c-canid); } .dot.cat-winged { background: var(--c-winged); }
.dot.cat-aquatic { background: var(--c-aquatic); } .dot.cat-entity { background: var(--c-entity); } .dot.cat-fae { background: var(--c-fae); } .dot.cat-ufo { background: var(--c-ufo); }
.dot.cat-other { background: var(--c-other); }

/* creature list */
/* Home featured: 9 cards fill 3 or 1 columns evenly; at 2 columns drop the 9th so no card sits alone */
.home-crits { container-type: inline-size; }
@container (min-width: 600px) and (max-width: 929px) { .home-crits > .crit:nth-child(9) { display: none; } }
.crit-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: .9rem; margin: 1rem 0 1.4rem; }
.crit[hidden], .cat-group[hidden] { display: none; } /* filters on /creatures/ hide cards; .crit is flex */
.crit { display: flex; gap: 1rem; align-items: flex-start; padding: .9rem 1rem; background: #fff; border-radius: var(--r-md);
  color: var(--ink) !important; text-decoration: none; border: 1px solid var(--mist-2); transition: border-color .15s, transform .15s; }
.crit:hover { border-color: var(--spruce); transform: translateY(-2px); }
.crit-txt { display: flex; flex-direction: column; min-width: 0; }
.crit-name { font: 700 1.2rem/1.2 var(--display); color: var(--spruce); }
.aka { font-size: .82rem; color: var(--muted-l); font-style: italic; margin: .1rem 0 .3rem; }
.crit-sum { font-size: .93rem; line-height: 1.45; }
.band-dark .crit { background: var(--spruce-2); border-color: var(--spruce-3); color: var(--lichen) !important; }
.band-dark .crit-name { color: #F3F1DA; }
.cat-h { display: flex; align-items: center; margin-bottom: .15em; }
.cat-blurb { color: var(--muted-l); margin-bottom: .2rem; }
.index-head .lede { margin-bottom: 1.2rem; }
.search-row input { width: 100%; max-width: 560px; font: 400 1.1rem var(--body); padding: .85rem 1.1rem; border-radius: 999px;
  border: 2px solid var(--spruce-3); background: var(--spruce-2); color: #F3F1DA; }
.search-row input::placeholder { color: var(--muted-d); }
.search-row input:focus { outline: none; border-color: var(--lantern); }
.chips { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: 1rem; }
.chip { font: 600 .9rem var(--body); color: var(--lichen); background: var(--spruce-2); border: 1px solid var(--spruce-3);
  border-radius: 999px; padding: .4rem .85rem; cursor: pointer; }
.chip[aria-pressed="true"] { background: var(--lichen); color: var(--spruce); border-color: var(--lichen); }
.empty { font-size: 1.1rem; padding: 2rem 0; }

/* creature page */
.creature-head-in { display: flex; gap: clamp(1.2rem, 4vw, 2.6rem); align-items: center; }
.creature-head h1 { font-size: clamp(2.3rem, 6vw, 4rem); color: #F3F1DA; margin-bottom: .25rem; }
.aka-line { font-style: italic; color: var(--lantern-2); margin-bottom: .7rem; }
@media (max-width: 600px) { .creature-head-in { flex-direction: column; align-items: flex-start; } }
.creature-body { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: clamp(1.5rem, 4vw, 3.5rem); }
@media (max-width: 860px) { .creature-body { grid-template-columns: 1fr; } .facts { order: -1; } }
.prose { max-width: 68ch; font-size: 1.075rem; line-height: 1.7; }
.prose h2:first-child { margin-top: 0; }
.facts { background: #fff; border-radius: var(--r-md); padding: 1.1rem 1.2rem; align-self: start; border: 1px solid var(--mist-2); position: sticky; top: 76px; }
.facts dl { margin: 0; }
.facts div { padding: .55rem 0; border-bottom: 1px solid var(--mist); }
.facts div:last-child { border-bottom: 0; }
.facts dt { font-size: .82rem; font-weight: 700; color: var(--muted-l); }
.facts dd { margin: .1rem 0 0; font-size: .97rem; line-height: 1.45; }
.facts .more { margin: .8rem 0 0; font-weight: 600; }
.signs { list-style: none; padding: 0; margin: 0 0 1em; }
.signs li { position: relative; padding: .45rem 0 .45rem 1.9rem; border-bottom: 1px dashed var(--mist-2); }
.signs li::before { content: ""; position: absolute; left: .2rem; top: .95rem; width: .75rem; height: .75rem; border-radius: 50%;
  background: var(--lantern); box-shadow: 0 0 0 3px rgba(242, 179, 61, .25); }
.timeline { list-style: none; padding: 0; margin: 0 0 1em; border-left: 3px solid var(--mist-2); }
.timeline li { display: grid; grid-template-columns: 5.5rem 1fr; gap: .8rem; padding: .55rem 0 .55rem 1rem; position: relative; }
.timeline li::before { content: ""; position: absolute; left: -7px; top: 1rem; width: 11px; height: 11px; border-radius: 50%; background: var(--spruce); }
.timeline .yr { font: 700 1rem var(--display); color: var(--spruce); }
.timeline.cases li { grid-template-columns: 9rem 1fr; padding-top: .35rem; padding-bottom: .35rem; }
.timeline.cases .yr { font: 600 .92rem var(--body); color: var(--muted-l); }
.callout { background: #fff; border-left: 4px solid var(--c-ufo); padding: .8rem 1rem; border-radius: 0 var(--r-sm) var(--r-sm) 0; }
.rel-h { margin-top: 0; padding-top: 1rem; }

/* UFO files */
.bars { display: flex; align-items: flex-end; gap: 3px; height: 220px; padding: 1.4rem 0 1.6rem; margin: .5rem 0 1rem; }
.bar { flex: 1; height: var(--h); min-height: 2px; background: var(--spruce); border-radius: 3px 3px 0 0; position: relative; }
.bar:hover { background: #7A4E00; }
.bar-n { position: absolute; bottom: 100%; left: 50%; transform: translateX(-50%); font-size: .7rem; color: var(--muted-l); padding-bottom: 2px; white-space: nowrap; }
.bar-y { position: absolute; top: 100%; left: 50%; transform: translateX(-50%); font-size: .72rem; color: var(--muted-l); padding-top: 4px; }
@media (max-width: 720px) { .bar-n { display: none; } .bar:nth-child(even) .bar-y { display: none; } }
.cols { columns: 4 200px; padding: 0; list-style: none; margin: 0 0 1.5rem; }
.cols li { padding: .2rem 0; break-inside: avoid; }
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem, 5vw, 4rem); }
.split h2 { margin-top: 0; color: #F3F1DA; }
@media (max-width: 760px) { .split { grid-template-columns: 1fr; } }

/* military */
.mil-list li { grid-template-columns: 4.5rem 1fr; }
.mil h3 { margin: 0 0 .1rem; color: var(--spruce); }
.mil p { margin: .2rem 0 .5rem; max-width: 70ch; }
.src { font-size: .85rem; }
.src a { margin-right: .7rem; }

/* footer */
.foot { background: #0E1D18; color: var(--muted-d); padding: 2.5rem 0 3rem; font-size: .95rem; }
.foot-in { max-width: 1120px; margin: 0 auto; padding: 0 clamp(16px, 3vw, 28px); }
.foot-brand { display: flex; align-items: center; gap: .5rem; font: 700 1.15rem var(--display); color: var(--lichen); }
.foot p { max-width: 70ch; }
.foot-links a { margin-right: 1.1rem; display: inline-block; }

@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }
.band .wrap > :first-child, .band .wrap > .cat-group:first-child > h2 { margin-top: 0; }

/* Home: search-first hero, browse tiles, framed map */
.home-hero { padding: clamp(2rem, 6vw, 4rem) 0 1.5rem; background: radial-gradient(120% 90% at 85% 0%, #1E3A2F 0%, var(--spruce) 60%); }
.home-hero h1 { font-size: clamp(2.1rem, 6vw, 3.6rem); color: #F3F1E4; max-width: 18ch; }
.search { position: relative; max-width: 40rem; margin: 1.4rem 0 1.6rem; }
.search input { width: 100%; box-sizing: border-box; font: 500 1.1rem var(--body); padding: .95rem 1.1rem .95rem 3rem; border-radius: 14px; border: 2px solid #3A5A4C;
  background: #0E1D18 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23C9D3A4' stroke-width='2.4' stroke-linecap='round'%3E%3Ccircle cx='10.5' cy='10.5' r='6.5'/%3E%3Cpath d='m15.5 15.5 5 5'/%3E%3C/svg%3E") no-repeat 1rem center / 1.3rem;
  color: #F3F1E4; }
.search input:focus { border-color: var(--lantern); outline: none; }
.search input::placeholder { color: #8FA394; }
.search-results { position: absolute; z-index: 20; left: 0; right: 0; top: calc(100% + 6px); list-style: none; margin: 0; padding: .35rem; background: #F3F1E4; border-radius: 14px; box-shadow: 0 18px 40px rgba(0,0,0,.45); max-height: 60vh; overflow: auto; }
.search-results a { display: flex; align-items: center; gap: .75rem; padding: .55rem .7rem; border-radius: 10px; color: var(--spruce); text-decoration: none; }
.search-results a:hover, .search-results a.on { background: var(--mist-2); }
.search-results b { display: block; font-weight: 700; }
.search-results small { color: #5A6B61; }
.search-results .none { padding: .8rem; color: #3D4A43; }
.mask-ico { flex: none; width: 30px; height: 30px; background: currentColor; -webkit-mask: var(--m) center / contain no-repeat; mask: var(--m) center / contain no-repeat; }
.search-results .cat-hominid .mask-ico { color: #A86A1E; } .search-results .cat-canid .mask-ico { color: #B4472A; }
.search-results .cat-winged .mask-ico { color: #8A5C9E; } .search-results .cat-aquatic .mask-ico { color: #23827A; }
.search-results .cat-entity .mask-ico { color: #5D8A2E; } .search-results .cat-fae .mask-ico { color: #B04F7A; } .search-results .cat-ufo .mask-ico { color: #5B58C9; }
.search-results .cat-other .mask-ico { color: #9A7E1C; }
.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(9.5rem, 1fr)); gap: .6rem; }
.tile { display: flex; align-items: center; gap: .6rem; padding: .75rem .85rem; border-radius: 12px; background: #1A3229; color: #F3F1E4 !important; text-decoration: none; font-weight: 600; line-height: 1.2; border: 1px solid #2B4A3D; }
.tile .ico { width: 40px; height: 40px; flex: none; }
.tile .art-ico { -webkit-mask-size: var(--ms, contain); mask-size: var(--ms, contain); -webkit-mask-position: var(--mx, 50%) var(--my, 50%); mask-position: var(--mx, 50%) var(--my, 50%); }
.tile:hover { background: #22402F; border-color: var(--lantern); }
.tile-mil .ico { color: #7FD3FF; }

.map-block { padding: 1.5rem 0 0; background: var(--spruce); }
.map-block-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: .6rem; }
.map-block-head h2 { margin: 0; color: #F3F1E4; }
.map-block-actions { display: flex; gap: .5rem; }
.btn-sm { font-size: .9rem; padding: .45rem .9rem; }
.map-frame { position: relative; height: min(68vh, 640px); min-height: 380px; margin-top: .8rem; }
.map-frame .map { position: absolute; inset: 0; }
.map-full { display: flex; flex-direction: column; height: calc(100svh - 58px); }
.map-full-bar { padding: .6rem 1rem; display: flex; gap: .6rem; align-items: flex-start; background: var(--spruce); }
.map-full-bar .filters { flex: 1; min-width: 0; }
.map-frame.full { flex: 1; height: auto; min-height: 0; margin: 0; }

.filters { margin-top: .9rem; }
.tchips { display: flex; flex-wrap: wrap; gap: .4rem; }
.tchip { font: 600 .92rem var(--body); padding: .4rem .85rem; border-radius: 999px; border: 1.5px solid #3A5A4C; background: transparent; color: var(--lichen); cursor: pointer; }
.tchip[aria-pressed="true"] { background: var(--lichen); color: var(--spruce); border-color: var(--lichen); }
.cchips { display: flex; flex-wrap: wrap; gap: .4rem; padding: .55rem 0 .2rem; max-height: 11rem; overflow-y: auto; }
.cchips[hidden] { display: none; }
.cchip { flex: none; scroll-snap-align: start; display: flex; align-items: center; gap: .4rem; font: 600 .88rem var(--body); padding: .3rem .75rem .3rem .35rem; border-radius: 999px; border: 1.5px solid #2B4A3D; background: #1A3229; color: #E8ECDD; cursor: pointer; white-space: nowrap; }
.cchip .ico { width: 26px; height: 26px; }
.cchip[aria-pressed="true"] { border-color: var(--lantern); background: #2A3A22; }
.cchip.dim { opacity: .55; }
.cchip:hover { border-color: var(--lichen); }

.near, .this-month { margin-bottom: 2.2rem; }
.near small { color: var(--muted-l); }
@media (max-width: 600px) {
  .tiles { grid-template-columns: 1fr 1fr; }
  .tile { font-size: .92rem; padding: .6rem .65rem; }
  .map-frame { height: 65vh; }
  .map-full-bar { padding: .5rem .6rem; }
  .timeline.cases li { grid-template-columns: 6.5rem 1fr; }
  /* Phones: year above the entry, so the text gets the full width */
  .timeline:not(.cases) li { grid-template-columns: 1fr; gap: .15rem; }
}
@media (min-width: 1000px) { .tiles { grid-template-columns: repeat(8, 1fr); } .tile { flex-direction: column; align-items: flex-start; } }
/* Columns never narrower than an icon + "encounters" (four at 640px pushed the page sideways). */
@media (min-width: 601px) and (max-width: 999px) { .tiles { grid-template-columns: repeat(auto-fill, minmax(10.5rem, 1fr)); } }
@media (max-width: 360px) { .tiles { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: .5rem; } .tile { min-width: 0; hyphens: auto; overflow-wrap: break-word; } }
@media (max-width: 600px) { .map-frame { max-height: 560px; } .search input { font-size: 1rem; } }

/* Creature pages: what-next sidebar and the "Seen one?" panel */
.side { align-self: start; display: grid; gap: 1rem; }
.side .facts { position: static; }
.next-card { display: flex; gap: .8rem; align-items: center; padding: .9rem 1rem; border-radius: var(--r-md); background: var(--spruce); color: #F3F1E4 !important; text-decoration: none; }
.next-card .ico { width: 44px; height: 44px; flex: none; }
.next-card b { display: block; font: 700 1.05rem var(--display); }
.next-card small { color: var(--lichen); font-size: .85rem; }
.next-card:hover { outline: 2px solid var(--lantern); }
.next-block { background: #fff; border: 1px solid var(--mist-2); border-radius: var(--r-md); padding: .9rem 1.1rem; }
.next-block h3 { font-size: 1.05rem; margin: 0 0 .4rem; color: var(--spruce); }
.next-list { list-style: none; margin: 0; padding: 0; }
.next-list li { padding: .45rem 0; border-top: 1px solid var(--mist); }
.next-more { margin: .5rem 0 0; font-weight: 600; }
.next-list li:first-child { border-top: 0; }
.next-list a { font-weight: 600; }
.next-list small { display: block; color: var(--muted-l); font-size: .84rem; }
.seen-box { display: flex; gap: 1.1rem; align-items: flex-start; margin-top: 2.2rem; padding: 1.3rem 1.4rem; border-radius: var(--r-md); background: var(--spruce); color: var(--lichen); }
.seen-box > .ico { width: 64px; height: 64px; flex: none; }
.seen-box h2 { color: #F3F1E4 !important; margin: 0 0 .3rem; }
.seen-box p { margin: 0 0 .8rem; }
.seen-box a:not(.btn) { color: var(--lantern); }
.seen-actions { display: flex; flex-wrap: wrap; gap: .5rem; }
@media (max-width: 600px) { .seen-box { flex-direction: column; } .seen-box > .ico { width: 48px; height: 48px; } }
.brand, .foot-brand { align-items: center; gap: 12px; }
/* The Dogman poster tile sits square to the left of the name */
.brand .mark { height: 42px; width: 42px; flex: none; }
.foot-brand { display: flex; } .foot-brand .mark { height: 36px; width: 36px; flex: none; }

/* Map popups: maplibre-gl.css loads after this file, so beat its white defaults with higher specificity */
.maplibregl-map .maplibregl-popup-content { background: var(--spruce); color: var(--lichen); border: 1px solid #3A5A4C; border-radius: 12px;
  font: 400 .95rem/1.45 var(--body); padding: .85rem 2.2rem .85rem 1rem; box-shadow: 0 12px 32px rgba(0,0,0,.55); }
.maplibregl-map .maplibregl-popup-anchor-bottom .maplibregl-popup-tip, .maplibregl-map .maplibregl-popup-anchor-bottom-left .maplibregl-popup-tip,
.maplibregl-map .maplibregl-popup-anchor-bottom-right .maplibregl-popup-tip { border-top-color: var(--spruce); }
.maplibregl-map .maplibregl-popup-anchor-top .maplibregl-popup-tip, .maplibregl-map .maplibregl-popup-anchor-top-left .maplibregl-popup-tip,
.maplibregl-map .maplibregl-popup-anchor-top-right .maplibregl-popup-tip { border-bottom-color: var(--spruce); }
.maplibregl-map .maplibregl-popup-anchor-left .maplibregl-popup-tip { border-right-color: var(--spruce); }
.maplibregl-map .maplibregl-popup-anchor-right .maplibregl-popup-tip { border-left-color: var(--spruce); }
.maplibregl-map .maplibregl-popup-close-button { color: #F3F1E4; font-size: 1.5rem; line-height: 1; width: 36px; height: 36px; top: 2px; right: 2px; border-radius: 8px; }
.maplibregl-map .maplibregl-popup-close-button:hover { background: #22402F; color: var(--lantern); }
.maplibregl-map .pop-h { color: #F3F1E4; font-size: 1.1rem; }
.maplibregl-map .pop-kind { color: #B7C6B9; font-weight: 600; }
.maplibregl-map .pop-meta { color: #D5DEC9; }
.maplibregl-map .pop a { color: var(--lantern); }
/* Phones: popup becomes a bottom sheet so it doesn't cover the pin */
@media (max-width: 600px) {
  .maplibregl-map .maplibregl-popup { transform: none !important; top: auto !important; left: 8px !important; right: 8px; bottom: 8px; max-width: none !important; }
  .maplibregl-map .maplibregl-popup-tip { display: none; }
  .maplibregl-map .maplibregl-popup-content { border-radius: 14px; padding-bottom: 1rem; }
}



/* Full-screen map page: header + filter bar + map exactly fill the screen, so nothing scrolls under the sticky header */
body.mapper { height: 100vh; height: 100dvh; display: flex; flex-direction: column; overflow: hidden; }
body.mapper main { flex: 1; min-height: 0; display: flex; }
body.mapper .foot { display: none; }
body.mapper .map-full { flex: 1; height: auto; min-height: 0; width: 100%; }
.map-full-bar { position: relative; display: block; box-shadow: 0 6px 14px rgba(0,0,0,.35); z-index: 3; }
.map-full-bar .tchips { padding-right: 7.5rem; }
.map-full-bar [data-locate] { position: absolute; top: .6rem; right: 1rem; }
@media (max-width: 600px) {
  .map-full-bar [data-locate] { right: .6rem; top: .5rem; }
  .map-full-bar .tchips { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; padding-right: 0; margin-right: 6.6rem;
    -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent); }
  .map-full-bar .tchips::-webkit-scrollbar { display: none; }
  .map-full-bar .tchip { flex: none; }
  .maplibregl-map .maplibregl-popup { bottom: 34px; }
}

.map-frame.full { max-height: none; }
.ufo-more { margin: 1.4rem 0 1.4rem; grid-template-columns: repeat(auto-fill, minmax(13rem, 1fr)) !important; }
/* Header: the wordmark never shrinks; with 9 nav items the nav drops to its own row below ~1100px */
.brand { flex: none; }
.nav { min-width: 0; }
/* Report an encounter: on every page, top right, the brightest thing in the header */
.report-btn { position: relative; flex: none; display: inline-flex; align-items: center; gap: .5rem; padding: .6rem 1.05rem; border-radius: 999px;
  background: var(--lantern); color: #13261F !important; font: 800 .98rem "Public Sans", sans-serif; text-decoration: none; white-space: nowrap;
  box-shadow: 0 0 0 3px rgba(242, 179, 61, .22), 0 6px 18px rgba(0, 0, 0, .35); }
.report-btn:hover { background: #FFC85A; }
.report-btn:focus-visible { outline: 3px solid #fff; outline-offset: 3px; }
.report-btn[aria-current] { box-shadow: 0 0 0 3px #fff; }
.rb-dot { width: 9px; height: 9px; border-radius: 50%; background: #C0301F; box-shadow: 0 0 0 3px rgba(192, 48, 31, .25); }
@media (prefers-reduced-motion: no-preference) { .rb-dot { animation: rb-pulse 2.4s ease-in-out infinite; } }
@keyframes rb-pulse { 50% { box-shadow: 0 0 0 6px rgba(192, 48, 31, 0); } }
.top .nav { margin-left: auto; }
.rb-short { display: none; }
/* Up to 640px the header holds logo + search + Report + Menu on one row, so the short label is needed (the long one pushed the Menu button off screen at 480-560px). */
@media (max-width: 640px) { .rb-long { position: absolute; left: 0; top: 0; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; } .rb-short { display: inline; } }
@media (min-width: 1221px) and (max-width: 1440px) {
  .top { gap: .6rem; }
  .brand { font-size: 1.15rem; }
  .nav a, .nav-dd summary { font-size: .88rem; padding: .4rem .5rem; }
  .report-btn { padding: .5rem .85rem; font-size: .9rem; }
}
@media (min-width: 901px) and (max-width: 1220px) {
  .top { gap: .4rem; }
  .brand { font-size: 1.05rem; }
  .nav a, .nav-dd summary { font-size: .86rem; padding: .4rem .45rem; }
  .nav { gap: 0; }
  .report-btn { padding: .5rem .8rem; font-size: .88rem; }
  .rb-long { position: absolute; left: 0; top: 0; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; } .rb-short { display: inline; }
}
@media (max-width: 900px) {
  .top { flex-wrap: wrap; padding-bottom: .4rem; row-gap: .3rem; }
  .top .nav { order: 3; margin-left: 0; }
  .report-btn { order: 2; margin-left: auto; padding: .5rem .85rem; font-size: .9rem; }
  .nav { width: 100%; margin: 0 -6px; -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent); padding-right: 28px; }
}

/* Park-poster creature art: dark silhouette on a disc of the category colour */
.badge.art { background: var(--c-other); box-shadow: inset 0 0 0 3px rgba(19,38,31,.35); }
.badge.art img, .mini.art img { width: 82%; height: 82%; object-fit: contain; display: block; }
.mini.art { display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; flex: none; background: var(--c-other); }
.badge.art.cat-hominid, .mini.art.cat-hominid { background: var(--c-hominid); }
.badge.art.cat-canid, .mini.art.cat-canid { background: var(--c-canid); }
.badge.art.cat-winged, .mini.art.cat-winged { background: var(--c-winged); }
.badge.art.cat-aquatic, .mini.art.cat-aquatic { background: var(--c-aquatic); }
.badge.art.cat-entity, .mini.art.cat-entity { background: var(--c-entity); }
.badge.art.cat-fae, .mini.art.cat-fae { background: var(--c-fae); }
.badge.art.cat-ufo, .mini.art.cat-ufo { background: var(--c-ufo); }
.badge-xl.art { box-shadow: 0 0 0 6px var(--spruce-2), 0 0 60px rgba(242,179,61,.18); }
.poster { width: clamp(150px, 24vw, 230px); height: auto; flex: none; filter: drop-shadow(0 12px 30px rgba(0,0,0,.45)); }

/* "Show everything" appears on the map once it's filtered to one creature, category or type */
.map-reset { position: absolute; top: 10px; right: 10px; z-index: 2; font: 700 .95rem "Public Sans", sans-serif; padding: .6rem 1rem;
  border-radius: 999px; border: 0; background: var(--lantern); color: #13261F; cursor: pointer; box-shadow: 0 4px 14px rgba(0,0,0,.35); }
.map-reset:hover { background: #FFC85A; }
.map-reset:focus-visible { outline: 3px solid #fff; outline-offset: 2px; }
.map-reset[hidden] { display: none; }

/* Map creature finder: category chips + search; the chosen group's creature chips wrap underneath */
.cfind { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem .6rem; margin-top: .55rem; }
.catchips { display: flex; flex-wrap: wrap; gap: .4rem; }
.catchip { display: inline-flex; align-items: center; gap: .4rem; font: 600 .88rem var(--body); padding: .3rem .7rem .3rem .4rem; border-radius: 999px;
  border: 1.5px solid #2B4A3D; background: #1A3229; color: #E8ECDD; cursor: pointer; white-space: nowrap; }
.catchip .ico { width: 24px; height: 24px; }
.catchip small { font-size: .78rem; opacity: .6; }
.catchip:hover { border-color: var(--lichen); }
.catchip[aria-pressed="true"] { border-color: var(--lantern); background: #2A3A22; }
.catchip:focus-visible, .cchip:focus-visible { outline: 3px solid var(--lantern); outline-offset: 2px; }
.cfind-in { flex: 1 1 12rem; max-width: 16rem; font: 500 .92rem var(--body); padding: .45rem .9rem; border-radius: 999px; border: 1.5px solid #2B4A3D;
  background: #0E1D18; color: #E8ECDD; }
.cfind-in::placeholder { color: #8FA394; }
.cfind-in:focus { outline: 3px solid var(--lantern); outline-offset: 1px; border-color: transparent; }
.cfind-none { margin: .5rem 0 0; font-size: .9rem; color: var(--muted-l, #9FB3A3); }
.cchip[hidden] { display: none; }
@media (max-width: 600px) {
  .catchip { font-size: .8rem; padding: .25rem .6rem .25rem .3rem; gap: .3rem; } .catchip .ico { width: 20px; height: 20px; } .catchip small { display: none; }
  .tchip { font-size: .85rem; } .cfind-in { max-width: none; }
}
/* Creature pages: full-story link under the summary, case summaries and sources, guide band, related groups */
.lede-story { margin: .4rem 0 1.5rem; } .lede-story a { color: var(--lantern); font-weight: 700; }
.case-sum { margin: .45rem 0 .3rem; font-size: .98rem; line-height: 1.55; color: var(--ink); }
.case-links { display: flex; flex-wrap: wrap; gap: .3rem 1rem; margin: .2rem 0 0; font-size: .92rem; }
.case-links .full-story { font-weight: 700; }
.case-src { color: var(--muted-d) !important; }
.cg-band { padding: 2.4rem 0 2.2rem; }
.cg-band h2 { margin: 0 0 .3rem; }
.cg-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 19rem), 1fr)); gap: .9rem; margin-top: 1.1rem; }
.cg-card { display: flex; gap: 1rem; align-items: flex-start; padding: 1.1rem 1.2rem; border-radius: var(--r-md); background: var(--spruce-2);
  border: 1px solid var(--spruce-3); color: var(--lichen) !important; text-decoration: none; }
.cg-card:hover { border-color: var(--lantern); }
.cg-card:focus-visible { outline: 3px solid var(--lantern); outline-offset: 2px; }
.cg-card b { display: block; font: 700 1.2rem/1.25 var(--display); color: #F3F1E4; margin: .15rem 0 .3rem; }
.cg-card small { display: block; font-size: .93rem; line-height: 1.45; }
.cg-kick { font-size: .78rem; font-weight: 700; color: var(--lantern); }
.cg-go { display: inline-block; margin-top: .55rem; font-weight: 700; color: var(--lantern); font-size: .92rem; }
.cg-ico { flex: none; width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; background: #0E1D18; color: var(--tone, var(--lantern)); }
.cg-ico .ico { width: 64%; height: 64%; }
.cg-all { margin: 1rem 0 0; } .cg-all a { color: var(--lichen); }
.rel-wrap { padding-top: 1rem; padding-bottom: 2rem; }  /* keep .wrap's side padding */
.rel-why { margin: -.4rem 0 .4rem; color: var(--muted-d); }
.tone-hominid { --tone: var(--c-hominid); } .tone-canid { --tone: var(--c-canid); } .tone-winged { --tone: var(--c-winged); }
.tone-entity { --tone: var(--c-entity); } .tone-fae { --tone: var(--c-fae); } .tone-ufo { --tone: var(--c-ufo); } .tone-other { --tone: var(--c-other); }
.cg-band h2 { color: #F3F1E4; } .cg-band .lede-dark { color: var(--lichen); }
/* Printables carry the brand: a header on the first page and a footer on every page */
.print-brand, .print-foot { display: none; }
@media print {
  .print-brand { display: flex !important; align-items: center; gap: 10px; border-bottom: 2px solid #13261F; padding-bottom: 6px; margin-bottom: 10px; }
  .print-brand img { width: 40px; height: 40px; }
  .print-brand b { display: block; font: 700 17pt "Zilla Slab", Georgia, serif; color: #13261F; }
  .print-brand span { font-size: 9pt; color: #333; }
  .print-brand .pb-url { margin-left: auto; font: 700 11pt "Public Sans", sans-serif; color: #13261F; }
  .print-foot { display: block !important; position: fixed; bottom: 0; left: 0; right: 0; font-size: 8pt; color: #444; text-align: center; }
  .report-btn { display: none !important; }
}
@media print {
  @page { margin: 12mm; }
  body { background: #fff !important; color: #000 !important; }
  .top, .foot, .skip { display: none !important; }
}

/* Nav dropdowns (UFOs, Resources): <details>, so they work without JS */
.nav { overflow: visible; align-items: center; }
.nav-dd { display: block; }
.nav-dd { position: relative; }
.nav-dd summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: .35rem; color: var(--lichen); font-weight: 600;
  line-height: inherit; border-radius: 999px; white-space: nowrap; }
.nav-dd summary::-webkit-details-marker { display: none; }
.nav-dd summary:hover, .nav-dd[open] summary { background: var(--spruce-2); color: #fff; }
.nav-dd.on summary { color: var(--spruce); background: var(--lichen); }
.nav-dd summary svg { transition: transform .15s; }
.nav-dd[open] summary svg { transform: rotate(180deg); }
.nav-dd summary:focus-visible { outline: 3px solid var(--lantern); outline-offset: 2px; }
.dd-menu { position: absolute; z-index: 60; top: calc(100% + .35rem); left: 0; min-width: 14rem; display: flex; flex-direction: column; gap: .1rem;
  padding: .4rem; background: #13261F; border: 1px solid var(--spruce-3); border-radius: 14px; box-shadow: 0 14px 34px rgba(0,0,0,.45); }
.dd-menu a { border-radius: 10px !important; padding: .6rem .8rem !important; }
@media (max-width: 900px) {
  .nav { flex-wrap: wrap; overflow: visible; -webkit-mask-image: none; mask-image: none; padding-right: 0; row-gap: .15rem; }

}
@media (max-width: 520px) { .dd-menu { position: fixed; left: 16px; right: 16px; top: auto; min-width: 0; } }

/* Creature index: sort control and per-card meta line */
.sort-row { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem .8rem; margin-top: 1rem; color: var(--lichen); font-weight: 600; }
.sort-row select { font: 600 .95rem "Public Sans", sans-serif; padding: .5rem 2rem .5rem .8rem; border-radius: 999px; border: 1px solid var(--spruce-3);
  background: var(--spruce-2) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%23C9D3A4' stroke-width='1.6'/%3E%3C/svg%3E") no-repeat right .8rem center / 10px;
  color: #F3F1DA; appearance: none; cursor: pointer; }
.sort-row select:focus-visible { outline: 3px solid var(--lantern); outline-offset: 2px; }
.sort-note { font-weight: 400; font-size: .85rem; opacity: .75; }
.crit-meta { display: flex; flex-wrap: wrap; gap: .25rem .7rem; margin-top: .45rem; font-size: .8rem; color: var(--muted-d); }
.cm-n { font-weight: 700; color: #7A4E00; }
.cm-loc { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 100%; }

/* Full map page: always-visible way out */
.map-exit { position: absolute; z-index: 5; top: 10px; right: 10px; display: inline-flex; align-items: center; gap: .45rem; padding: .55rem .9rem;
  border-radius: 999px; background: #F3F1DA; color: #13261F !important; font: 700 .9rem "Public Sans", sans-serif; text-decoration: none;
  box-shadow: 0 4px 14px rgba(0,0,0,.4); }
.map-exit:hover { background: #fff; }
.map-exit:focus-visible { outline: 3px solid var(--lantern); outline-offset: 2px; }

/* Read, watch and gear up (creature pages; Amazon Associates links) */
.md-band { padding: 2.2rem 0 1.6rem; border-top: 1px solid var(--mist-2); }
.md-band h2 { margin: 0 0 .4rem; color: var(--spruce); }
.md-band h3 { font: 700 1.15rem/1.3 var(--display); color: var(--spruce); margin: 1.4rem 0 .6rem; }
.md-note { color: var(--muted-l); margin: -.2rem 0 .7rem; }
.md-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: .8rem; }
.md-book, .md-doc { display: flex; gap: .85rem; background: #fff; border-radius: var(--r-md); padding: .9rem 1rem; color: var(--ink);
  text-decoration: none; box-shadow: 0 1px 0 var(--mist-2); min-width: 0; }
a.md-book:hover { box-shadow: 0 0 0 2px var(--lantern); color: var(--ink); }
.md-spine { flex: none; width: 14px; border-radius: 3px; background: var(--c-hominid); box-shadow: inset -3px 0 0 rgba(0,0,0,.15); }
.tone-1 .md-spine { background: var(--c-aquatic); } .tone-2 .md-spine { background: var(--c-ufo); }
.tone-3 .md-spine { background: var(--c-canid); } .tone-4 .md-spine { background: var(--c-fae); }
.md-txt { display: flex; flex-direction: column; gap: .15rem; min-width: 0; }
.md-txt b { font: 700 1rem/1.3 var(--display); color: var(--spruce); overflow-wrap: anywhere; }
.md-txt small { color: var(--muted-l); font-size: .9rem; }
.md-go { margin-top: auto; padding-top: .35rem; font-weight: 700; font-size: .92rem; color: #7A4E00; }
.md-ico { flex: none; width: 40px; height: 40px; border-radius: 50%; background: var(--c-ufo); display: grid; place-items: center; color: var(--spruce); }
.md-ico .ico { width: 24px; height: 24px; }
.md-links { display: flex; flex-wrap: wrap; gap: .3rem .9rem; padding-top: .35rem; font-size: .92rem; font-weight: 700; }
.md-links a { color: #7A4E00; }
.md-chips { display: flex; flex-wrap: wrap; gap: .5rem; }
.md-chip { display: inline-flex; align-items: center; min-height: 44px; padding: .45rem 1rem; border-radius: 999px; background: #fff; color: var(--spruce);
  font-weight: 700; text-decoration: none; border: 2px solid var(--mist-2); }
.md-chip:hover { border-color: var(--lantern); color: var(--spruce); }
.md-merch { background: var(--lantern); border-color: var(--lantern); }
.md-disc { margin: 1.4rem 0 0; font-size: .88rem; color: var(--muted-l); }
.md-disc a { color: #7A4E00; }

/* Field gear hub */
.gr-toc { margin: 0 0 1rem; }
.gr-sec { padding: 1.2rem 0 .4rem; scroll-margin-top: 80px; }
.gr-sec h2 { display: flex; align-items: center; gap: .6rem; }
.gr-ico { flex: none; width: 42px; height: 42px; border-radius: 50%; background: var(--spruce); color: var(--lantern); display: grid; place-items: center; }
.gr-ico .ico { width: 26px; height: 26px; }
.gr-why { color: var(--muted-l); margin: 0 0 .8rem; max-width: 62ch; }
.gr-apps { margin: .9rem 0 0; color: var(--ink); }
.gr-apps a, .gr-page .gr-why a { color: #7A4E00; }
.g-gearlink { background: #fff; border-left: 4px solid var(--lantern); border-radius: 0 var(--r-sm) var(--r-sm) 0; padding: .6rem .9rem; color: var(--ink); }
.g-gearlink a { color: #7A4E00; font-weight: 700; }
.md-aff { font: 600 .8rem var(--body); color: var(--muted-l); vertical-align: middle; margin-left: .3rem; white-space: nowrap; }
.gr-aff { margin: -.4rem 0 .6rem; } .gr-aff .md-aff { color: var(--muted-d); margin: 0; }

/* Creature pages: "On this page" jump links under the summary */
.jump { display: flex; flex-wrap: wrap; gap: .4rem; margin-top: 1rem; }
.jump a { display: inline-flex; align-items: center; min-height: 36px; padding: .3rem .85rem; border-radius: 999px; font-size: .88rem; font-weight: 600;
  color: var(--muted-d); border: 1px solid var(--spruce-3); text-decoration: none; background: rgba(255,255,255,.03); }
.jump a:hover { color: var(--lantern-2); border-color: var(--lantern); }
[id] { scroll-margin-top: 1rem; }
@media (min-width: 761px) { .split-3 { grid-template-columns: repeat(3, 1fr); gap: clamp(1.5rem, 3vw, 2.5rem); } }
.md-listen { margin: .3rem 0 1.2rem; font-size: .95rem; }
.md-listen a { font-weight: 600; }
/* Phones: creature-type chips in one sideways-scrolling row, so the map keeps most of the screen */
@media (max-width: 600px) {
  .catchips { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; width: 100%; padding-bottom: .1rem;
    -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent); }
  .catchips::-webkit-scrollbar { display: none; }
  .catchip { flex: none; }
  .cfind { margin-top: .45rem; }
}
/* Outline button for light (mist) backgrounds */
.btn-ghost-l { background: transparent; color: var(--spruce) !important; box-shadow: inset 0 0 0 2px var(--spruce); }
.btn-ghost-l:hover { background: rgba(0,0,0,.05); }
/* Header search button and /search/ page */
.search-btn { flex: none; display: inline-grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; color: var(--lichen);
  border: 1.5px solid var(--spruce-3); text-decoration: none; }
.search-btn:hover, .search-btn[aria-current] { color: var(--lantern-2); border-color: var(--lantern); }
@media (max-width: 900px) { .search-btn { order: 2; margin-left: auto; width: 38px; height: 38px; } .search-btn + .report-btn { margin-left: .2rem; } }
.search-page { min-height: 60vh; }
.search-big input { font-size: 1.1rem; }
.search-big .search-results { position: static; max-height: none; margin-top: .6rem; }
.search-tips { color: var(--muted-d); margin: 1rem 0 1.6rem; }
@media (max-width: 440px) {
  .top { column-gap: .35rem; }
  .brand { font-size: 1.05rem; gap: .4rem; } .brand img, .brand svg { width: 34px; height: auto; }
  .search-btn { width: 34px; height: 34px; } .search-btn svg { width: 17px; height: 17px; }
  .report-btn { padding: .45rem .75rem; }
}
.also-links { list-style: none; padding: 0; margin: 0 0 1.2rem; display: grid; gap: .45rem; }
.also-links a { font-weight: 600; }

/* Accessibility pass (axe, Oct 2026): muted text on light cards uses the darker muted colour; no faded counts */
.band-mist .case-src { color: var(--muted-l) !important; }
.band-mist .ce-meta, .band-mist .ce-facts b, .band-mist .ce-facts small, .band-mist .ce-pn small,
.band-mist .my-fig small, .band-mist .my-gsub, .ua-body .ce-meta { color: var(--muted-l); }
.band-dark .aka, .cg-band .aka { color: var(--muted-d); }
.md-chip small { opacity: 1; color: var(--muted-l); }
.pl-n, .ce-chip span { opacity: 1 !important; }
.hd.is-empty .hd-y { opacity: 1 !important; }
.band-mist .rel-why, .band-mist .prev small, .band-mist .next small, .prev small, .next small { color: var(--muted-l); }
.md-merch { color: #3D2700 !important; }
.hc-dec-h .hc-n { opacity: 1; }
.pl-date-m { background: #B8452C !important; }
.pl-date.is-tba .pl-date-m { background: var(--muted-l) !important; }
.home-where { margin: -.6rem 0 1.4rem; color: var(--muted-d); font-size: .95rem; }
.home-where a { color: var(--lantern-2); font-weight: 600; }
/* 404 page: search box and trail chips */
.nf-search { display: flex; gap: .5rem; max-width: 520px; margin: 1.2rem 0; }
.nf-search input { flex: 1; min-width: 0; min-height: 44px; padding: .5rem .9rem; border-radius: 10px; border: 1px solid var(--spruce-3); background: rgba(255,255,255,.07); color: #E8ECDD; font: inherit; }
.nf-search input::placeholder { color: #A9B98F; }
.band-dark .md-chip { background: rgba(255,255,255,.06); color: #E8ECDD; border-color: var(--spruce-3); }
.home-explore { margin: .8rem 0 1.6rem; }
/* Full map page: filters live in a drawer over the map, so the map keeps the screen (Fold/phones/desktop alike) */
body.mapper .map-full-bar { display: flex; align-items: center; gap: .6rem; padding: .5rem 1rem; }
body.mapper .map-full-bar [data-locate] { position: static; flex: none; margin-left: auto; }
.mf-toggle { display: inline-flex; align-items: center; gap: .5rem; min-width: 0; min-height: 40px; padding: .4rem .95rem; border-radius: 999px;
  border: 1.5px solid #3A5A4C; background: #1A3229; color: #F3F1DA; font: 700 .95rem var(--body); cursor: pointer; }
.mf-toggle:hover, .mf-toggle[aria-expanded="true"] { border-color: var(--lantern); }
.mf-toggle:focus-visible { outline: 3px solid var(--lantern); outline-offset: 2px; }
.mf-toggle svg { flex: none; }
.mf-now { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; color: var(--lichen); }
.mf-now::before { content: "· "; }
.mf-panel { position: absolute; z-index: 6; top: 0; left: 0; right: 0; max-height: calc(100% - 64px); overflow-y: auto; overscroll-behavior: contain;
  padding: .7rem 1rem 1rem; background: var(--spruce); box-shadow: 0 10px 24px rgba(0,0,0,.5); border-radius: 0 0 16px 16px; }
.mf-panel[hidden] { display: none; }
.mf-panel .filters { margin-top: 0; }
.mf-panel .cchips { max-height: none; overflow: visible; }
.mf-done { margin-top: .8rem; }
.map-frame.full .map-reset { top: 58px; }
@media (min-width: 900px) { .mf-panel { top: 10px; left: 56px; right: auto; width: min(760px, calc(100% - 240px)); border-radius: 16px; } }
@media (max-width: 600px) { body.mapper .map-full-bar { padding: .45rem .6rem; } .mf-toggle { font-size: .9rem; padding: .35rem .8rem; } }
.mf-panel .tchips, .mf-panel .catchips { flex-wrap: wrap; overflow: visible; margin-right: 0; padding-right: 0; -webkit-mask-image: none; mask-image: none; }
.mf-done { position: sticky; bottom: 0; box-shadow: 0 -6px 14px var(--spruce), 0 4px 12px rgba(0,0,0,.35); }
/* About page: owner card */
.owner-card { display: flex; gap: 1.4rem; align-items: center; padding: 1.2rem 1.4rem; margin: 0 0 2rem; border-radius: 18px; background: #F6F0E2; border: 1px solid var(--mist-2); }
.owner-card img { display: block; width: 160px; height: 160px; border-radius: 50%; background: #E9DFC8; object-fit: cover; object-position: top; flex: none; }
.owner-card h2 { margin-top: 0; }
.owner-card p { margin-bottom: 0; }
@media (max-width: 560px) { .owner-card { flex-direction: column; text-align: center; } .owner-card img { width: 140px; height: 140px; } }
.owner-card picture { flex: none; display: block; }
.owner-contact { margin: -1rem 0 2.2rem; }
.owner-contact h2 { margin-top: 0; }
.contact-form.compact .step { margin: .4rem 0 .6rem; }
/* Official social accounts: round icon links (footer, About) */
.social { display: flex; flex-wrap: wrap; gap: .5rem; margin: 1rem 0; }
.social a { display: inline-grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; color: var(--lichen); border: 1px solid #2B4A3D; }
.social a:hover { color: #1185FE; border-color: currentColor; background: rgba(255,255,255,.04); }
.social a:focus-visible { outline: 3px solid var(--lantern); outline-offset: 2px; }
.owner-social { margin: .8rem 0 0; }
.owner-social a { color: var(--spruce); border-color: var(--mist-2); background: #fff; }
.owner-social a:hover { color: #1185FE; }
.social a[data-net="facebook"]:hover { color: #1877F2; }

/* Weekly email signup */
.signup { position: relative; display: grid; grid-template-columns: auto 1fr; gap: 1.4rem; align-items: start; background: var(--spruce);
  background-image: radial-gradient(circle at 92% 0%, rgba(242,179,61,.18), transparent 45%); color: #F3F1DA; border: 2px solid var(--lantern);
  border-radius: 18px; padding: 1.5rem 1.6rem; margin: 2rem 0 1rem; box-shadow: 0 10px 30px rgba(0,0,0,.18); }
.su-art { display: grid; grid-template-columns: 1fr 1fr; gap: .3rem; width: 132px; }
.su-art img { width: 64px; height: 64px; background: var(--spruce-3); border: 2px solid var(--lantern); border-radius: 50%; padding: 7px; }
.su-art img:first-child { grid-column: 1 / -1; justify-self: center; }
.signup h2 { margin: 0 0 .25rem; color: var(--lantern-2); font-size: clamp(1.4rem, 3vw, 1.8rem); }
.signup .su-lede { margin: 0 0 .8rem; color: var(--lichen); }
.su-list { list-style: none; padding: 0; margin: 0 0 1rem; display: grid; gap: .45rem; }
.su-list li { padding-left: 1.6rem; position: relative; line-height: 1.45; color: #DCE3C8; font-size: .96rem; }
.su-list li::before { content: ""; position: absolute; left: 0; top: .3rem; width: .9rem; height: .9rem; border-radius: 50%; background: var(--lantern); box-shadow: 0 0 0 3px rgba(242,179,61,.25); }
.su-list b { display: block; color: #F3F1DA; }
.signup form { display: flex; flex-wrap: wrap; gap: .5rem; max-width: 34rem; }
.signup input[type=email] { flex: 1 1 13rem; max-width: 20rem; min-width: 0; font: 1rem var(--body); padding: .7rem .9rem; border: 0; border-radius: 999px; background: #fff; color: var(--ink); }
.signup .btn { border: 0; cursor: pointer; }
.signup .su-fine { margin: .55rem 0 0; font-size: .82rem; color: var(--muted-d); }
@media (max-width: 640px) {
  .signup { grid-template-columns: 1fr; gap: .8rem; padding: 1.2rem; }
  .su-art { display: flex; width: auto; }
  .su-art img { width: 48px; height: 48px; padding: 6px; }
  .signup input[type=email] { max-width: none; }
}
.nl-band { padding-top: 0; }
.nl-band .signup { margin: 0 auto; max-width: 820px; }
.nl-state { font-size: 1.15rem; }

/* Under 900px the nav wraps onto extra rows (three with a phone's larger text setting), so a pinned header
   would cover a third of the screen. Let it scroll away there; it stays pinned on wider screens. */
@media (max-width: 900px) { .top { position: relative; } .facts { top: 12px; } }

/* Witness story cards (creature pages, /stories/) */
.ws-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: .9rem; margin: .8rem 0 1.6rem; }
.ws-card { display: flex; flex-direction: column; gap: .3rem; padding: 1rem 1.1rem; background: #fff; border: 1px solid var(--mist-2);
  border-top: 4px solid var(--lantern); border-radius: var(--r-md); color: var(--ink) !important; text-decoration: none; line-height: 1.4; }
.ws-card:hover { border-color: var(--spruce-3); box-shadow: 0 6px 18px rgba(19,38,31,.12); }
.ws-card b { font: 700 1.12rem/1.25 var(--display); }
.ws-meta { font-size: .85rem; color: var(--muted-l); }
.ws-dek { font-size: .95rem; }
.ws-go { margin-top: auto; padding-top: .3rem; font-weight: 700; font-size: .9rem; color: #7A4E00; }
.ws-crit { display: inline-flex; align-items: center; gap: .35rem; font-size: .8rem; font-weight: 700; color: var(--muted-l); }
.ws-crit .ico { width: 18px; height: 18px; }
.ws-intro { margin-top: -.3rem; }
.prose .ws-grid { max-width: none; font-size: 1rem; }
/* Creature header: links to the witness stories and reader reports for this creature */
.crit-reads { display: flex; flex-wrap: wrap; gap: .5rem; margin: .9rem 0 0; }
.crit-reads a { display: inline-block; padding: .4rem .85rem; border-radius: 999px; background: var(--lantern); color: var(--spruce); font-weight: 700; text-decoration: none; font-size: .95rem; }
.crit-reads a:hover { filter: brightness(1.05); text-decoration: underline; }
.crit-reads a[hidden] { display: none; }
.ws-more { margin: 1rem 0 0; }
.pop-story { margin: .2rem 0 .5rem; font-size: .92rem; line-height: 1.45; color: #DCE3D2; font-style: italic; }

/* Home: latest reader reports */
.new-reports { background: #1B3229; border-top: 1px solid rgba(242,179,61,.25); border-bottom: 1px solid rgba(242,179,61,.25); padding: 28px 0 32px; }
.nr-head { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.nr-head h2 { margin: 4px 0 0; color: #F3F1DA; }
.nr-pill { display: inline-flex; align-items: center; gap: 8px; margin: 0; background: #F2B33D; color: #13261F; font-weight: 700; font-size: .85rem; padding: 4px 12px; border-radius: 99px; text-transform: uppercase; letter-spacing: .04em; }
.nr-dot { width: 9px; height: 9px; border-radius: 50%; background: #D8352A; box-shadow: 0 0 0 0 rgba(216,53,42,.6); animation: nr-pulse 1.8s infinite; }
@keyframes nr-pulse { 70% { box-shadow: 0 0 0 9px rgba(216,53,42,0); } 100% { box-shadow: 0 0 0 0 rgba(216,53,42,0); } }
@media (prefers-reduced-motion: reduce) { .nr-dot { animation: none; } }
.nr-actions { margin: 0; display: flex; gap: 8px; flex-wrap: wrap; }
.nr-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 14px; }
.nr-card { display: flex; gap: 14px; background: #F6F0E2; color: #1F2A24; border-radius: 14px; padding: 12px; text-decoration: none; transition: transform .15s; }
.nr-card:hover { transform: translateY(-2px); }
.nr-art { position: relative; flex: none; width: 92px; height: 92px; }
.nr-art svg { width: 100%; height: 100%; display: block; }
.nr-new { position: absolute; top: -6px; left: -6px; background: #D8352A; color: #fff; font: 700 .7rem/1 var(--sans, system-ui); padding: 4px 7px; border-radius: 99px; text-transform: uppercase; letter-spacing: .05em; }
.nr-body { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.nr-what { font: 700 1.02rem/1.25 var(--display); color: #13261F; }
.nr-where { font-size: .85rem; color: #5D6B62; }
.nr-snip { font-size: .9rem; line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.nr-go { margin-top: auto; font-weight: 700; color: #8A5A00; text-decoration: underline; font-size: .9rem; }

/* Blue Book city pages: files grouped by year */
.file-years { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: .4rem 1.4rem; margin: .5rem 0 1rem; }
.fy h3 { font-size: 1rem; margin: .6rem 0 .25rem; }
.fy h3 .muted { font: 400 .85rem var(--sans, system-ui); }
.fchips { display: flex; flex-wrap: wrap; gap: .3rem; margin: 0; }
.fchips a { font-size: .85rem; padding: .15rem .55rem; border-radius: 99px; background: #fff; border: 1px solid var(--mist-2, #cfd9d3); text-decoration: none; }
.fchips a:hover { border-color: var(--spruce, #13261F); }
.cmp-links { display: flex; flex-wrap: wrap; gap: .5rem; list-style: none; padding: 0; margin: 0 0 1rem; }
.cmp-links a { display: inline-block; background: #fff; border: 1px solid var(--mist-2, #cfd9d3); border-radius: 99px; padding: .35rem .9rem; font-weight: 700; text-decoration: none; }

/* Weekly email: the hello bar above the header on every page, and the slide-in card (static/signup.js) */
.hello { position: relative; background: var(--lantern); color: var(--ink); padding: .45rem 2.6rem .45rem 1rem; }
.hello-in { display: flex; align-items: center; justify-content: center; gap: .5rem .7rem; flex-wrap: nowrap; max-width: 1180px; margin: 0 auto; }
.hello-txt { margin: 0; font-size: .95rem; line-height: 1.35; min-width: 0; }
@media (max-width: 1100px) { .hello-txt span { display: none; } }
.hello input[type=email] { width: 15rem; max-width: 16rem; font: .95rem var(--body); padding: .4rem .7rem; border: 1px solid rgba(19,38,31,.35); border-radius: 999px; background: #fff; color: var(--ink); }
.hello .btn { background: var(--spruce); color: #F3F1DA !important; border: 0; cursor: pointer; flex: none; }
.hello .btn:hover { background: var(--spruce-3); }
.hello-x { position: absolute; right: .4rem; top: 50%; transform: translateY(-50%); background: none; border: 0; font-size: 1.5rem; line-height: 1; padding: .3rem .5rem; color: var(--ink); cursor: pointer; }
.hello-done { margin: 0; font-weight: 700; text-align: center; }
@media (max-width: 760px) {
  .hello { padding: .45rem 2.4rem .5rem .8rem; }
  .hello-txt span { display: none; }
  .hello-in { justify-content: center; flex-wrap: wrap; }
  .hello-txt { flex: 1 0 100%; text-align: center; }
  .hello input[type=email] { flex: 1 1 9rem; width: auto; max-width: 16rem; }
}
.nl-slide { position: fixed; right: 1rem; bottom: 1rem; z-index: 30; width: min(360px, calc(100vw - 2rem)); background: var(--spruce); color: #F3F1DA;
  border: 2px solid var(--lantern); border-radius: 14px; padding: 1rem 1.1rem; box-shadow: 0 12px 34px rgba(0,0,0,.35);
  transform: translateY(130%); transition: transform .35s ease; }
.nl-slide.in { transform: none; }
.nl-slide h2 { margin: 0 1.6rem .3rem 0; font-size: 1.2rem; color: var(--lantern-2); }
.nl-slide p { margin: 0 0 .7rem; font-size: .92rem; line-height: 1.45; color: var(--lichen); }
.nl-slide form { display: flex; gap: .4rem; flex-wrap: wrap; }
.nl-slide input[type=email] { flex: 1 1 160px; min-width: 0; font: .95rem var(--body); padding: .5rem .7rem; border: 0; border-radius: 10px; }
.nl-slide .btn { border: 0; cursor: pointer; }
.nl-slide .hello-x { top: .9rem; transform: none; color: #F3F1DA; }
@media (max-width: 560px) { .nl-slide { right: .5rem; left: .5rem; bottom: .5rem; width: auto; } }
@media print { .hello, .nl-slide { display: none !important; } }

/* Main menu, 2026-10-18: six desktop items; under 960px one Menu button opens every group (build.py mobile_menu). */
.mm { display: none; }
@media (max-width: 960px) {
  .top { flex-wrap: nowrap !important; padding-bottom: 0 !important; }
  .top .nav { display: none !important; }
  .top .brand { margin-right: auto; order: 0; }
  .top .search-btn { order: 1; margin-left: auto; }
  .top .report-btn { order: 2; }
  .mm { display: block; position: static; order: 3; }
  .mm summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: .45rem; padding: .5rem .85rem; border-radius: 999px;
    color: #F3F1DA; font-weight: 700; font-size: .95rem; box-shadow: inset 0 0 0 2px var(--spruce-3); }
  .mm summary::-webkit-details-marker { display: none; }
  .mm[open] summary { background: var(--lichen); color: var(--spruce); box-shadow: none; }
  .mm-panel { position: absolute; left: 0; right: 0; top: 100%; z-index: 40; background: var(--spruce); border-top: 1px solid var(--spruce-3);
    border-bottom: 3px solid var(--lantern); padding: 1rem clamp(1rem, 4vw, 2rem) 1.4rem; max-height: calc(100vh - 70px); overflow-y: auto; box-shadow: 0 18px 40px rgba(0,0,0,.45); }
  .mm-top { display: grid; grid-template-columns: 1fr 1fr; gap: .5rem; margin-bottom: 1rem; }
  .mm-big { display: block; text-align: center; padding: .8rem; border-radius: 12px; background: var(--spruce-2); color: #F3F1DA; font-weight: 800; text-decoration: none; font-size: 1.05rem; }
  .mm-groups { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 1rem 1.4rem; }
  .mm-h { margin: 0 0 .3rem; font-size: .75rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--lantern); }
  .mm-group a { display: block; padding: .5rem 0; color: #F3F1DA; text-decoration: none; font-size: 1rem; border-bottom: 1px solid rgba(201,211,164,.12); }
  .mm a[aria-current] { color: var(--lantern-2); font-weight: 700; }
  .mm .mm-big[aria-current] { background: var(--lichen); color: var(--spruce); }
}
@media (max-width: 520px) {
  .mm summary span { display: none; }
  .mm summary { padding: .55rem .7rem; }
  .top .brand { font-size: 1rem; }
}
@media (max-width: 370px) {
  .top { gap: .35rem; padding-left: .6rem; padding-right: .6rem; }
  .top .brand { font-size: .9rem; gap: .4rem; }
  .top .brand .mark { width: 32px; height: 32px; }
  .top .report-btn { padding: .45rem .6rem; }
}
@media print { .mm { display: none !important; } }

/* Long option text (e.g. the creature index sort) must never widen the page on small phones. */
select { max-width: 100%; }
@media (max-width: 480px) { .md-aff { white-space: normal; } }
