/* Self-hosted so no visitor IP is sent to Google Fonts. Latin subset of Cormorant Garamond 600
   (the same file Google serves), OFL-licensed. */
@font-face {
  font-family: "Cormorant Garamond";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/fonts/cormorant-garamond-600-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --ink: #23271f; --muted: #6b7163; --line: #e2e5da; --bg: #fbfbf7;
  --leaf: #3b6d34; --leaf-bg: #eef3e7; --accent: #7a3b2e; --warn: #b8860b;
  --font: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-logo: "Cormorant Garamond", serif;
}
* { box-sizing: border-box; }
html { overflow-anchor: none; }
body { margin: 0; font-family: var(--font); color: var(--ink); background: var(--bg); line-height: 1.6; }
a { color: var(--leaf); text-decoration: none; }
a:hover { text-decoration: underline; }
main { max-width: 900px; margin: 0 auto; padding: 24px 20px 48px; }
main.wide { max-width: 1080px; }

header.site { position: sticky; top: 0; z-index: 50; background: var(--bg); border-bottom: 1px solid var(--line); }
.site-inner { max-width: 1080px; margin: 0 auto; padding: 18px 20px; display: flex; align-items: center; gap: 28px; flex-wrap: wrap; transition: padding .15s ease; }
header.site.scrolled .site-inner { padding: 6px 20px; }
.brand { font-family: var(--font-logo); font-size: 26px; font-weight: 600; color: var(--ink); transition: font-size .15s ease; }
header.site.scrolled .brand { font-size: 15px; }
/* Nav: Cormorant small caps, tying the navigation to the serif wordmark. */
.site-nav { display: flex; gap: 26px; }
.site-nav a { color: var(--muted); text-decoration: none; font-family: var(--font-logo); font-size: 19px; font-weight: 600; font-variant: small-caps; text-transform: lowercase; letter-spacing: .06em; line-height: 1; transition: color .15s ease; }
.site-nav a:hover, .site-nav a[aria-current="page"] { color: var(--leaf); }
.nav-search { margin-left: auto; position: relative; }
.nav-search input { font: inherit; font-size: 14px; padding: 6px 14px; border: 1px solid var(--line); border-radius: 20px; background: #fff; color: var(--ink); width: 12rem; max-width: 40vw; }
.typeahead { position: absolute; top: calc(100% + 6px); right: 0; width: 22rem; max-width: 80vw; margin: 0; padding: 4px; list-style: none; background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 6px 24px rgba(35,39,31,.14); z-index: 60; max-height: 60vh; overflow-y: auto; }
.ta-row { display: flex; align-items: center; gap: 10px; padding: 7px 10px; border-radius: 8px; cursor: pointer; }
.ta-row:hover, .ta-row.active { background: #f1f6ec; }
.ta-text { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.ta-name { font-size: 14px; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ta-sub { font-size: 12px; color: var(--muted); font-style: italic; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ta-label { flex: none; font-size: 10px; text-transform: uppercase; letter-spacing: .04em; font-weight: 600; padding: 2px 7px; border-radius: 10px; white-space: nowrap; }
.ta-common { background: #e7f0e0; color: #2f5127; }
.ta-scientific { background: #ece7f0; color: #574a63; }
.ta-pollinator { background: #fbe6cf; color: #8a5a1a; }
/* mobile-only nav controls (hamburger + search) — hidden on desktop */
.icon-btn { display: none; background: none; border: 0; padding: 6px; margin: 0; color: var(--ink); cursor: pointer; align-items: center; justify-content: center; border-radius: 8px; }
.icon-btn:hover { background: #f1f6ec; color: var(--leaf); }
header.site.search-open .nav-search-btn, header.site.nav-open .nav-menu-btn { color: var(--leaf); background: #f1f6ec; }
@media (max-width: 640px) {
  .site-inner { gap: 8px 12px; padding: 12px 16px; }
  header.site.scrolled .site-inner { padding: 8px 16px; }
  .icon-btn { display: inline-flex; }
  .nav-search-btn { margin-left: auto; }              /* push both icons to the right of the brand */
  .site-nav, .nav-search { display: none; }           /* collapsed until toggled */
  header.site.nav-open .site-nav { display: flex; flex-direction: column; width: 100%; order: 5; gap: 2px; padding-top: 8px; margin-top: 4px; border-top: 1px solid var(--line); }
  header.site.nav-open .site-nav a { padding: 8px 2px; font-size: 20px; }
  header.site.search-open .nav-search { display: block; width: 100%; order: 4; margin: 4px 0 0; }
  header.site.search-open .nav-search input { width: 100%; max-width: none; }
  .nav-search .typeahead { width: 100%; max-width: none; right: 0; left: 0; }
}
footer.site { max-width: 1080px; margin: 0 auto; padding: 24px 20px; border-top: 1px solid var(--line); color: var(--muted); font-size: 13px; display: flex; flex-direction: column; gap: 10px; }
.footer-nav { display: flex; gap: 16px; flex-wrap: wrap; }
.footer-nav a { color: var(--muted); font-weight: 600; }
.footer-nav a:hover, .footer-nav a[aria-current="page"] { color: var(--ink); text-decoration: none; }
.footer-nav-btn { border: 0; background: transparent; padding: 0; margin: 0; color: var(--muted); font-weight: 600; font-size: inherit; font-family: inherit; cursor: pointer; }
.footer-nav-btn:hover { color: var(--ink); }
.footer-copy { margin: 0; color: var(--muted); font-size: 12px; }

h1 { font-family: var(--font-logo); font-size: 40px; margin: 8px 0 4px; font-weight: 600; line-height: 1.1; letter-spacing: -0.01em; }
h2 { font-size: 19px; margin: 30px 0 12px; font-weight: 600; }
h3 { font-size: 13px; font-weight: 600; margin: 0 0 10px; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.lede { color: var(--muted); margin: 0 0 20px; }

/* ---------- index grid ---------- */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 16px; }
.card { display: flex; flex-direction: column; background: #fff; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; transition: border-color .15s; }
.card:hover { border-color: var(--leaf); text-decoration: none; }
/* Fixed card aspect (height/width = 0.82) so the crop frames identically at every breakpoint and
   matches the curate crop editor (CARD_HW). A fixed pixel height would change the aspect per column
   count, making a set --focal frame a different slice on mobile than on desktop. */
.thumb { aspect-ratio: 50 / 41; display: block; position: relative; overflow: hidden; }
/* The pager/img fills an absolutely-positioned layer so a loaded image's natural height can't stretch
   the box past its aspect-ratio (which is what made the crop drift once images loaded). */
.thumb > .pager, .thumb > img { position: absolute; inset: 0; width: 100%; height: 100%; }
/* Cards crop to a short band; blooms sit in the upper part of most plates/photos, so bias the crop up.
   --focal (a per-image % set inline where curated) overrides this default. */
.thumb img { width: 100%; height: 100%; object-fit: cover; object-position: center var(--focal, 0%); display: block; }
/* card image pager (global, for JS-built search cards + Astro ImagePager card variant) */
.pager-card { display: block; height: 100%; position: relative; }
.pager-card .pager-frame { position: relative; height: 100%; }
.pager-card .pager-img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: center var(--focal, 0%); }
.pager-card .pager-btn { position: absolute; top: 50%; transform: translateY(-50%); width: 26px; height: 26px; border-radius: 50%; border: none; cursor: pointer; background: rgba(255,255,255,.82); color: #23271f; font-size: 17px; line-height: 1; display: flex; align-items: center; justify-content: center; box-shadow: 0 1px 4px rgba(0,0,0,.18); opacity: 0; transition: opacity .15s; z-index: 2; }
.pager-card .pager-prev { left: 8px; } .pager-card .pager-next { right: 8px; }
.pager-card.pager-multi:hover .pager-btn { opacity: 1; }
/* Touch/mobile has no hover, and a tap focuses only one button (showing a lone arrow); show both. */
@media (max-width: 640px) { .pager-card.pager-multi .pager-btn { opacity: 1; } }
/* Persistent page counter ("1 of N"): always visible on cards since mobile has no hover arrows. */
.pager-card .pager-count { position: absolute; bottom: 6px; right: 6px; z-index: 2; background: rgba(35,39,31,.82); color: #fff; font-size: 11px; font-variant-numeric: tabular-nums; padding: 1px 7px; border-radius: 10px; opacity: 1; }
@media (max-width: 640px) { .pager-card .pager-count { font-size: 12px; padding: 2px 8px; bottom: 8px; right: 8px; } }
.card .name { font-weight: 600; margin: 10px 12px 0; }
.card .sci { color: var(--muted); font-style: italic; font-size: 13px; margin: 2px 12px 12px; }

/* ---------- multi-select filter dropdowns (hub + search) ---------- */
.filter-bar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.fdrop { position: relative; }
.fdrop-btn { display: inline-flex; align-items: center; gap: 7px; font: inherit; font-size: 14px; padding: 7px 12px; border: 1px solid var(--line, #e2e5da); border-radius: 8px; background: #fff; color: var(--ink, #23271f); cursor: pointer; }
.fdrop-btn:hover { border-color: var(--leaf, #3b6d34); }
.fdrop.has .fdrop-btn { border-color: var(--leaf, #3b6d34); background: var(--leaf-tint, #eef3e7); }
.fdrop-label { font-weight: 600; }
.fdrop-sum { color: var(--muted, #6b7163); }
.fdrop.has .fdrop-sum { color: var(--leaf, #3b6d34); font-weight: 600; }
.fdrop-chev { width: 11px; height: 11px; opacity: .55; transition: transform .15s; flex: none; }
.fdrop.open .fdrop-chev { transform: rotate(180deg); }
.fdrop-menu { position: absolute; top: calc(100% + 4px); left: 0; z-index: 40; min-width: 190px; max-height: 340px; overflow-y: auto; background: #fff; border: 1px solid var(--line, #e2e5da); border-radius: 10px; box-shadow: 0 8px 28px rgba(0,0,0,.14); padding: 6px; }
.fdrop-opt { display: flex; align-items: center; gap: 9px; padding: 6px 9px; border-radius: 6px; font-size: 14px; cursor: pointer; white-space: nowrap; }
.fdrop-opt:hover { background: var(--leaf-tint, #eef3e7); }
.fdrop-opt input { accent-color: var(--leaf, #3b6d34); width: 15px; height: 15px; flex: none; }
.fdrop-menu-foot { display: flex; justify-content: flex-end; border-top: 1px solid var(--line, #e2e5da); margin-top: 4px; padding-top: 4px; }
.fdrop-clear { font: inherit; font-size: 13px; color: var(--leaf, #3b6d34); background: none; border: none; cursor: pointer; padding: 4px 8px; }
.fdrop-clear:disabled { color: var(--muted, #6b7163); opacity: .5; cursor: default; }
.filter-reset { font: inherit; font-size: 13px; color: var(--leaf, #3b6d34); background: none; border: none; cursor: pointer; padding: 6px 4px; text-decoration: underline; }

/* ---------- ad slots (placeholders) ---------- */
.ad { display: flex; align-items: center; justify-content: center; background:
    repeating-linear-gradient(45deg, #f6f6f0, #f6f6f0 10px, #f1f1ea 10px, #f1f1ea 20px);
  border: 1px dashed #cfd3c6; border-radius: 10px; color: #9a9e90; }
.ad-label { font-size: 10px; text-transform: uppercase; letter-spacing: .1em; text-align: center; }
.ad-label em { display: block; font-style: normal; opacity: .7; margin-top: 2px; }
.ad-rail { width: 300px; height: 600px; }
.ad-inline { height: 110px; margin: 8px 0 26px; }
.ad-footer { height: 110px; margin: 28px 0 0; }
.ad-anchor { display: none; }

/* ---------- HERO (full width) ---------- */
/* image left, name header top-right, facts below it; on mobile the header moves ABOVE the image */
.hero { display: grid; grid-template-columns: auto 1fr; grid-template-rows: auto 1fr; column-gap: 32px; row-gap: 10px; align-items: start; grid-template-areas: "plate head" "plate info"; }
.plate { margin: 0; grid-area: plate; }
.plant-head { grid-area: head; }
.info { grid-area: info; }
.plate img { display: block; max-height: 340px; width: auto; max-width: 320px; border-radius: 10px; background: var(--leaf-bg); }
.plate-caption { font-size: 11.5px; color: var(--muted); margin: 6px 0 0; width: 0; min-width: 100%; overflow-wrap: break-word; }
.type { text-transform: uppercase; letter-spacing: .07em; font-size: 12px; color: var(--muted); margin: 0 0 4px; }
/* desktop: scientific name to the right of the primary name (baseline-aligned), aliases below the pair */
.name-area { display: grid; align-items: baseline; column-gap: 12px; grid-template-columns: auto 1fr; grid-template-areas: "h1 sci" "aka aka"; }
.name-area h1 { grid-area: h1; margin: 0; }
.name-area .sci { grid-area: sci; margin: 0; color: var(--muted); font-style: italic; }
.name-area .aka { grid-area: aka; margin: 6px 0 0; }
.aka { color: var(--muted); font-size: 15px; line-height: 1.5; }
.native { display: inline-flex; align-items: center; gap: 7px; color: #2a2720; background: #f4f3ee; font-size: 14px; font-weight: 600; padding: 6px 13px; border-radius: 20px; margin: 4px 0; }
.native-pin { color: #7a3b2e; position: relative; top: 0; flex: none; }
/* the pill answers "where is it native"; this line under it carries the precise wording, so it stays
   quiet: muted, smaller, and measure-limited so it reads as a footnote rather than competing body copy. */
.native-block { margin: 4px 0; }
.native-block .native { margin: 0; }
.native-sub { color: var(--muted); font-size: 12.5px; line-height: 1.5; margin: 5px 0 0; max-width: 46rem; }
/* Visually hidden rather than [hidden], so the control stays keyboard-focusable and its label still works. */
.nd-toggle { position: absolute; width: 1px; height: 1px; opacity: 0; margin: 0; }
.nd-more { display: none; }
.nd-toggle:focus-visible ~ .nd-more { outline: 2px solid var(--leaf, #3b6d34); outline-offset: 2px; border-radius: 3px; }
/* On a phone the longer statements run ~5 lines and push the key facts below the fold, so clamp to two
   and let the reader open it. Desktop has the room and shows it whole. No JS: the checkbox drives it. */
@media (max-width: 640px) {
  .nd-clamp { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
  .nd-toggle:checked ~ .nd-clamp { -webkit-line-clamp: unset; overflow: visible; }
  .nd-more { display: inline-block; margin-top: 4px; font-size: 12.5px; font-weight: 600; color: var(--leaf, #3b6d34); cursor: pointer; }
  .nd-more::after { content: 'more'; }
  .nd-toggle:checked ~ .nd-more::after { content: 'less'; }
}

/* compact key-fact cells */
.keyfacts { list-style: none; padding: 0; margin: 20px 0 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.keyfacts li { background: #f4f3ee; border-radius: 10px; padding: 11px 12px; display: flex; flex-direction: column; }
.kf-h { display: flex; align-items: center; gap: 6px; margin-bottom: 5px; }
.kf-i { display: flex; }
.kf-k { font-size: 11px; text-transform: uppercase; letter-spacing: .04em; color: #6f6a5e; }
.kf-v { font-size: 15px; font-weight: 600; color: #2a2720; line-height: 1.2; }
.kf-c { font-size: 11px; color: #8a8474; margin-top: 2px; line-height: 1.35; }
.kf-more-link { display: inline-block; margin: 12px 0 0; font-size: 13px; font-weight: 600; color: var(--leaf, #3b6d34); }
.kf-more-link:hover { text-decoration: underline; }
.flag { color: var(--warn); cursor: help; margin-left: 4px; font-size: 12px; }
.tagnote { font-size: 11px; font-weight: 400; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); background: var(--leaf-bg); border-radius: 20px; padding: 2px 8px; vertical-align: middle; }

/* ---------- BODY layout: content + rail ---------- */
.crumbs { font-size: 13px; color: var(--muted); margin: 0 0 16px; display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.crumbs a { color: var(--muted); }
.crumbs a:hover { color: var(--leaf); }
.crumbs .crumb-sep { color: var(--line); }
.crumbs .crumb-here { color: var(--ink); }
.body-layout { display: grid; grid-template-columns: minmax(0, 1fr); gap: 40px; align-items: start; margin-top: 26px; }
.rail { position: sticky; top: 16px; }

/* ---------- visual band ---------- */
.viz { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; }
.viz-note { font-size: 12px; color: var(--muted); margin: 8px 0 0; }
.viz-note strong { color: var(--ink); }
.bhead { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 0; }
.bhead h2 { margin: 0; }
.bloom-copy { font-size: 14.5px; color: var(--muted); margin: 6px 0 0; }
.bdot { width: 11px; height: 11px; border-radius: 50%; display: inline-block; flex: none; }
.bwheel { display: flex; justify-content: center; margin-top: 18px; }
.bwheel-svg { width: 100%; max-width: 300px; }
.blegend { font-size: 13px; color: var(--muted); margin: 16px 0 0; display: flex; gap: 22px; flex-wrap: wrap; align-items: center; justify-content: center; }
.blegend strong { color: var(--ink); font-weight: 600; }
.blegend .bdot { vertical-align: -1px; margin-right: 6px; }
.bwheel-share { border: 0.5px solid var(--line); background: #f4f3ee; color: #2a2720; width: 40px; height: 40px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; cursor: pointer; }
.bwheel-share:hover { background: #ece7db; }
.zonebar { display: flex; gap: 2px; }
.zseg { flex: 1; text-align: center; font-size: 11px; padding: 8px 0; border-radius: 3px; background: #f0efe8; color: #b6b1a4; }
.zseg[data-in="true"] { background: var(--leaf); color: #fff; font-weight: 600; }

/* ---------- growing-condition meters ---------- */
.growing { margin-top: 8px; }
.bloomsec { margin-top: 30px; }
.meters { display: flex; flex-direction: column; gap: 22px; }
.meter { display: flex; flex-direction: column; gap: 9px; }
.mlabel { font-size: 13px; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.mrow { display: flex; align-items: flex-start; gap: 10px; }
.mend { color: #8a8d80; flex: none; display: flex; padding-top: 9px; }
.mtrack { flex: 1; display: flex; gap: 4px; }
.mcol { flex: 1; display: flex; flex-direction: column; }
.mcell { display: flex; align-items: center; justify-content: center; height: 36px; border-radius: 4px; }
.mcap { font-size: 11px; color: var(--ink); margin-top: 6px; text-align: center; line-height: 1.2; }
/* interactive zone finder */
.zonefinder { margin-top: 24px; }
.zf-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 11px; }
.zf-head h3 { margin: 0; }
.zf-summary { font-size: 13.5px; color: var(--muted); margin: 0; line-height: 1.5; }
.zf-summary strong { color: var(--ink); }
.zf-toggle { display: inline-flex; background: #f4f3ee; border-radius: 8px; padding: 2px; }
.zf-sys { border: 0; background: transparent; padding: 5px 14px; font-size: 12px; color: #8a8474; cursor: pointer; font-family: inherit; border-radius: 6px; }
.zf-sys.on { background: #fbfbf7; color: #2a2720; font-weight: 600; box-shadow: 0 1px 2px rgba(31, 29, 23, .07); }
.zf-hist { display: flex; align-items: flex-end; gap: 3px; padding-bottom: 34px; margin-top: 24px; }
.zcol { flex: 1; min-width: 0; display: flex; flex-direction: column; align-items: center; position: relative; }
.zcol-out:not(.zcol-you) { opacity: 0.28; }
.zbarwrap { width: 100%; height: 48px; display: flex; align-items: flex-end; }
.zbar { width: 100%; border-radius: 3px 3px 0 0; }
.znum { font-size: 10px; color: var(--muted); margin-top: 4px; }
.zcol-you .zbar { outline: 3px solid var(--ink); outline-offset: 1px; box-shadow: 0 0 0 1.5px #fbfbf7; }
.zcol-you .znum { color: var(--ink); font-weight: 700; }
.zyou { position: absolute; top: 100%; left: 50%; transform: translateX(-50%); margin-top: 8px; white-space: nowrap; font-size: 10px; font-weight: 700; letter-spacing: .02em; color: #fff; background: var(--ink); padding: 3px 9px; border-radius: 10px; line-height: 1.1; }
.zyou::before { content: ''; position: absolute; top: -3px; left: 50%; transform: translateX(-50%) rotate(45deg); width: 7px; height: 7px; background: var(--ink); border-radius: 1px; }
.zf-find { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 14px; }
.zf-find-l { font-size: 13px; font-weight: 600; }
.zf-zip { width: 120px; padding: 6px 10px; border: 0.5px solid var(--line); border-radius: 7px; font-size: 13px; font-family: inherit; background: #fff; text-transform: uppercase; }
.zf-zip::placeholder { text-transform: none; }
.zf-zip.zf-miss { border-color: #c0603f; background: #fbf0ea; }
.zf-go { border: 0.5px solid var(--line); background: #f4f3ee; color: #2a2720; font-weight: 600; font-size: 13px; padding: 6px 14px; border-radius: 7px; cursor: pointer; font-family: inherit; }
.zf-go:hover { background: #ece7db; }
.zf-or { font-size: 12px; color: var(--muted); }
.zf-clear { border: 0; background: transparent; color: var(--muted); font-size: 12px; cursor: pointer; text-decoration: underline; font-family: inherit; }
.zf-verdict { font-size: 14px; font-weight: 600; margin: 12px 0 0; line-height: 1.4; }
.zf-verdict[data-v="yes"] { color: #3b6d34; }
.zf-verdict[data-v="no"] { color: #8a4b2e; }

/* ---------- guidance / pollinators ---------- */
.guidance { margin-top: 0; }
.poll { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; list-style: none; padding: 0; margin: 0; }
.pcard { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 7px; background: #f4f3ee; border-radius: 16px; padding: 20px 15px 18px; }
.poll-i { width: 62px; height: 62px; flex: none; margin-bottom: 4px; background: #7a3b2e; -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat; -webkit-mask-position: center; mask-position: center; -webkit-mask-size: contain; mask-size: contain; }
.pcat { font-size: 11.5px; text-transform: uppercase; letter-spacing: .05em; color: #8a8474; }
.phero { font-size: 15px; font-weight: 600; line-height: 1.22; color: #2a2720; }
.palso { font-size: 12.5px; line-height: 1.35; color: #6f6a5e; }
.pcard em, .pmore em { font-style: italic; }
/* reverse links: butterflies that use this plant (host/nectar), linking to their pollinator guides */
.bfly-guides { margin-top: 22px; }
.bfly-guides h3 { font-size: 15px; margin: 0 0 2px; }
.bfly-sub { font-size: 12.5px; color: var(--muted, #6b7163); margin: 0 0 10px; }
.bfly-list { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.bfly-list li { display: inline-flex; align-items: baseline; gap: 6px; background: #f4f3ee; border-radius: 20px; padding: 5px 13px; font-size: 13.5px; }
.bfly-list a { color: var(--leaf, #3b6d34); font-weight: 600; }
.bfly-role { font-size: 11px; color: var(--muted, #6b7163); }
.bfly-role.role-host, .bfly-role.role-both { color: #7a5b17; }
/* expand toggle (native <details>) */
.pexp { display: block; }
.pexp > summary { display: block; cursor: pointer; list-style: none; font-size: 12.5px; line-height: 1.35; }
.pexp > summary::-webkit-details-marker { display: none; }
.pexp > summary::marker { content: ''; }
.pexp-cue { color: #7a3b2e; font-weight: 500; font-size: 12px; white-space: nowrap; }
.pexp-list { display: block; margin-top: 5px; }
/* "also visited by" card: one row per remaining category, names + expand */
.pmore { justify-content: flex-start; text-align: left; gap: 10px; }
.pmore .pcat { align-self: flex-start; }
.pmore-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 9px; width: 100%; }
.pmore-cat { font-size: 13px; line-height: 1.4; color: #6f6a5e; }
.pmore-label { font-weight: 600; color: #2a2720; }
.pmore-cat .pexp { display: inline; }
.pmore-cat .pexp > summary { display: inline; font-size: 13px; line-height: 1.4; }
.pnote { font-size: 12px; color: #8a8474; margin: 6px 0 0; }

/* ---------- full specs ---------- */
.specgroup { margin-bottom: 22px; }
.spectable { margin: 0; }
.specrow { display: grid; grid-template-columns: 210px 1fr; gap: 4px 22px; padding: 9px 0; border-top: 1px solid var(--line); }
.specrow dt { color: var(--muted); font-size: 13.5px; }
.specrow dd { margin: 0; font-size: 14px; }
.specrow .sn { display: block; color: var(--muted); font-size: 12px; line-height: 1.4; margin-top: 3px; white-space: pre-line; }

.back { margin-top: 28px; }

/* ---------- responsive: mobile = centered single column, no rail, inline ads (Option C) ---------- */
@media (max-width: 900px) {
  .body-layout { grid-template-columns: 1fr; gap: 0; }
  .rail { display: none; }
  .ad-inline, .ad-footer { height: 250px; }
  .ad-anchor { display: flex; position: fixed; bottom: 0; left: 0; right: 0; height: 52px; z-index: 60; border-radius: 0; border: 0; border-top: 1px solid var(--line); background: #f4f4ee; }
  .content { padding-bottom: 60px; }
}
@media (max-width: 680px) {
  /* header (type + name + aliases + scientific) above the image, then facts */
  .hero { grid-template-columns: 1fr; grid-template-rows: none; grid-template-areas: "head" "plate" "info"; gap: 16px; text-align: center; }
  .name-area { grid-template-columns: 1fr; grid-template-areas: "h1" "aka" "sci"; justify-items: center; row-gap: 4px; }
  .plate { max-width: 300px; margin: 0 auto; }
  .plate img { max-width: 100%; max-height: none; }
  .keyfacts { grid-template-columns: repeat(2, 1fr); text-align: left; }
  .viz { grid-template-columns: 1fr; gap: 22px; }
  .specrow { grid-template-columns: 1fr; gap: 2px; }
  .specrow dt { font-weight: 600; color: var(--ink); }
}

/* ---------- cookie consent banner ---------- */
.cookie-banner { position: fixed; left: 0; right: 0; bottom: 0; z-index: 60; background: var(--bg); border-top: 1px solid var(--line); box-shadow: 0 -4px 12px -4px rgba(35, 39, 31, .1); }
.cookie-banner-inner { max-width: 1080px; margin: 0 auto; padding: 16px 20px; }
.cookie-view { display: flex; flex-direction: column; gap: 14px; }
.cookie-view[hidden] { display: none; }
.cookie-title { font-weight: 600; margin: 0 0 4px; }
.cookie-copy p { margin: 0; font-size: 13.5px; color: var(--muted); }
.cookie-copy .cookie-title { color: var(--ink); font-size: 14.5px; }
.cookie-actions { display: flex; gap: 10px; flex-wrap: wrap; justify-content: flex-end; }
.consent-btn { border: 0.5px solid var(--line); border-radius: 7px; padding: 8px 16px; font-size: 13px; font-weight: 600; cursor: pointer; font-family: inherit; background: transparent; color: var(--ink); }
.consent-btn.ghost:hover { background: #f4f3ee; }
.consent-btn.primary { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.consent-btn.primary:hover { background: #34392c; }
.cookie-categories { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.cookie-cat { background: #f4f3ee; border-radius: 10px; padding: 12px 14px; }
.cookie-cat-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 5px; }
.cookie-cat-title { font-weight: 600; font-size: 13.5px; margin: 0; color: var(--ink); }
.cookie-cat-body { font-size: 12px; color: var(--muted); margin: 0; }
.cookie-always-on { font-size: 11px; color: var(--muted); font-weight: 600; }
.consent-toggle { position: relative; display: inline-flex; align-items: center; width: 34px; height: 19px; border-radius: 10px; background: #d8d5c8; border: 0; cursor: pointer; padding: 0; flex: none; }
.consent-toggle.on { background: var(--ink); }
.consent-toggle-thumb { position: absolute; left: 2px; top: 2px; width: 15px; height: 15px; border-radius: 50%; background: #fff; transition: transform .15s ease; }
.consent-toggle.on .consent-toggle-thumb { transform: translateX(15px); }
@media (max-width: 680px) {
  .cookie-categories { grid-template-columns: 1fr; }
  .cookie-actions { justify-content: stretch; }
  .cookie-actions .consent-btn { flex: 1; }
}
