/* IBM Plex Sans (SIL Open Font Licence), a variable font: one file per alphabet range covers 400 to 700.
   optional: on a slow first visit the system font stays rather than the page re-flowing when Plex arrives. */
@font-face { font-family: "IBM Plex Sans"; font-style: normal; font-weight: 100 700; font-display: optional; src: url(/fonts/ibm-plex-sans-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; }
@font-face { font-family: "IBM Plex Sans"; font-style: normal; font-weight: 100 700; font-display: optional; src: url(/fonts/ibm-plex-sans-latin-ext.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
/* Plant Wiki styles. Tokens first; light and dark share every rule below them. */
:root {
  --bg: #F3F5F8; --surface: #FFFFFF; --surface-2: #F6F8FA; --ink: #0F1B2D; --text: #24324A; --muted: #526072; --line: #DDE3EA; --line-2: #C2CBD6;
  --leaf: #1F7A4D; --leaf-600: #17603C; --leaf-soft: #E5F1EA; --on-leaf: #FFFFFF;
  --warn: #B42318; --warn-soft: #FBEAE7; --gold: #8A5A0C; --gold-soft: #FBF3E2;
  --nav: #0F1B2D; --nav-ink: #FFFFFF; --nav-muted: #AEB9C8; --nav-field: rgb(255 255 255 / .08); --nav-line: rgb(255 255 255 / .14);
  --accent: var(--leaf); --accent-ink: var(--on-leaf); --danger: var(--warn); /* the family's token names (WIKI-HARMONY) */
  --r-sm: 6px; --r: 8px; --r-lg: 10px;
  --sh-1: 0 1px 2px rgb(15 27 45 / .06); --sh-2: 0 8px 24px rgb(15 27 45 / .10);
  --sans: "IBM Plex Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --wrap: 1200px; --gut: 24px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0B121C; --surface: #111A27; --surface-2: #16212F; --ink: #E6ECF2; --text: #C9D3DE; --muted: #9AA6B4; --line: #233042; --line-2: #34445A;
    --leaf: #3FA36B; --leaf-600: #5BBE86; --leaf-soft: #15291F; --on-leaf: #0B121C;
    --warn: #F97066; --warn-soft: #3A1E1B; --gold: #E3B34F; --gold-soft: #33280F;
    --nav: #070C14; --nav-muted: #9AA6B4;
    --sh-1: 0 1px 2px rgb(0 0 0 / .3); --sh-2: 0 8px 24px rgb(0 0 0 / .35); color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0B121C; --surface: #111A27; --surface-2: #16212F; --ink: #E6ECF2; --text: #C9D3DE; --muted: #9AA6B4; --line: #233042; --line-2: #34445A;
  --leaf: #3FA36B; --leaf-600: #5BBE86; --leaf-soft: #15291F; --on-leaf: #0B121C;
  --warn: #F97066; --warn-soft: #3A1E1B; --gold: #E3B34F; --gold-soft: #33280F;
  --nav: #070C14; --nav-muted: #9AA6B4;
  --sh-1: 0 1px 2px rgb(0 0 0 / .3); --sh-2: 0 8px 24px rgb(0 0 0 / .35); color-scheme: dark;
}

/* ---------- Base ---------- */
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
/* Component display rules (buttons are inline-flex) must never beat the hidden attribute. */
[hidden] { display: none !important; }
/* The footer sits at the bottom of short pages. */
body { min-height: 100vh; display: flex; flex-direction: column; }
body > main { flex: 1 0 auto; width: 100%; }
body { margin: 0; background: var(--bg); color: var(--text); font: 15px/1.55 var(--sans); -webkit-font-smoothing: antialiased; }
h1, h2, h3 { color: var(--ink); font-family: var(--sans); font-weight: 600; letter-spacing: -.015em; line-height: 1.2; }
h1 { font-size: clamp(26px, 3vw, 34px); margin: 0 0 6px; }
h3, h2.h3 { font-size: 18px; }
a { color: var(--leaf); text-underline-offset: 3px; }
a:hover { color: var(--leaf-600); }
img { max-width: 100%; }
.muted { color: var(--muted); }
.small { font-size: 12px; }
.i { width: 18px; height: 18px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; vertical-align: -3px; }
:focus-visible { outline: 2px solid var(--leaf); outline-offset: 2px; }
::selection { background: var(--leaf-soft); }

/* Controls */
button, select, input, textarea { font: inherit; color: inherit; }
button, .btn, .upload {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 40px; padding: 0 16px;
  border: 1px solid var(--line-2); border-radius: var(--r-sm); background: var(--surface); color: var(--ink);
  font-weight: 600; font-size: 14px; line-height: 1; cursor: pointer; text-decoration: none; white-space: nowrap;
  transition: background .15s, border-color .15s, color .15s, box-shadow .15s;
}
button:hover, .btn:hover, .upload:hover { border-color: var(--muted); }
button.primary, .btn.primary { background: var(--leaf); border-color: var(--leaf); color: var(--on-leaf); }
button.primary:hover, .btn.primary:hover { background: var(--leaf-600); border-color: var(--leaf-600); }
button:disabled { opacity: .55; cursor: default; }
select, input[type=text], input[type=search], input[type=date], textarea {
  border: 1px solid var(--line-2); border-radius: var(--r-sm); background: var(--surface); padding: 9px 12px; min-height: 40px;
}
textarea { width: 100%; line-height: 1.5; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--leaf); box-shadow: 0 0 0 3px var(--leaf-soft); }

/* ---------- Header ---------- */
.top { position: sticky; top: 0; z-index: 20; background: var(--nav); color: var(--nav-ink); border-bottom: 1px solid var(--nav-line); }
.top-in { max-width: var(--wrap); margin: 0 auto; padding: 8px var(--gut); display: flex; gap: 20px; align-items: center; min-height: 58px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--nav-ink); text-decoration: none; font: 600 18px/1 var(--sans); letter-spacing: -.01em; white-space: nowrap; }
.brand img { border-radius: 8px; box-shadow: var(--sh-1); }
.brand em { color: #5BBE86; font-style: normal; }
.site-foot .brand { color: var(--ink); } /* the footer sits on the page background, not the dark header */
.site-foot .brand em { color: var(--leaf); }
.search { flex: 1; min-width: 0; max-width: 560px; position: relative; transition: opacity .2s; }
.search > .i { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--nav-muted); pointer-events: none; }
#q { width: 100%; padding: 8px 46px 8px 38px; min-height: 38px; border-radius: var(--r-sm); background: var(--nav-field); border-color: var(--nav-line); color: var(--nav-ink); }
#q::placeholder { color: var(--nav-muted); }
#q:focus { border-color: #5BBE86; box-shadow: none; }
body.intro-visible .top .search { opacity: 0; pointer-events: none; }
.camsearch { position: absolute; right: 4px; top: 50%; transform: translateY(-50%); min-height: 30px; width: 30px; padding: 0; border: 0; border-radius: var(--r-sm); background: transparent; color: var(--nav-muted); }
.sharebtn { flex: none; min-height: 38px; width: 38px; padding: 0; border-color: var(--nav-line); background: var(--nav-field); color: var(--nav-ink); }
.sharebtn:hover { border-color: var(--nav-muted); }
.shares { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; margin-top: 16px; }
.shares a, .shares button { justify-content: center; text-decoration: none; }
.shares .wa { background: #1DA851; border-color: #1DA851; color: #fff; }
.shares .li { background: #0A66C2; border-color: #0A66C2; color: #fff; }
.shares .tg { background: #229ED9; border-color: #229ED9; color: #fff; }
.shares .x { background: #0F1419; border-color: #0F1419; color: #fff; }
:root[data-theme="dark"] .shares .x { border-color: var(--line-2); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .shares .x { border-color: var(--line-2); } }
.sharecard { display: flex; justify-content: center; margin-top: 12px; }
.sharecard canvas { width: min(220px, 60vw); height: auto; aspect-ratio: 1; border-radius: var(--r); box-shadow: var(--sh-2); }
.streak button { margin-top: 8px; }
.invite .actions { margin-top: 8px; }
.welcome { background: var(--leaf-soft); border-bottom: 1px solid var(--line); }
.welcome-in { max-width: var(--wrap); margin: 0 auto; padding: 10px var(--gut); display: flex; align-items: center; gap: 12px; color: var(--ink); font-size: 14px; }
.welcome-in span { flex: 1; }
.welcome-x { flex: none; min-height: 32px; width: 32px; padding: 0; border: 0; background: transparent; color: var(--muted); font-size: 22px; }
@media (max-width: 560px) { .welcome-in { flex-wrap: wrap; } .welcome-in span { flex-basis: calc(100% - 44px); } .welcome-in .primary { order: 3; } }
#shareWeek { margin-top: 10px; width: 100%; }
.remind { margin: 8px 0; }
.remind:empty { display: none; }
.streak .geo { display: flex; gap: 6px; margin-top: 8px; }
.camsearch:hover { background: var(--nav-field); color: var(--nav-ink); }
.nav { display: flex; align-items: center; gap: 4px; margin-left: auto; }
.navlink { color: var(--nav-muted); text-decoration: none; font-weight: 600; font-size: 14px; padding: 8px 10px; border-radius: var(--r-sm); white-space: nowrap; }
.navlink:hover { background: var(--nav-field); color: var(--nav-ink); }
.navlink.on { color: var(--nav-ink); background: var(--nav-field); }
.nav-sep { width: 1px; height: 22px; background: var(--nav-line); margin: 0 6px; flex: none; } /* between this wiki's own features and the family's shared menu */

/* ---------- Layout ---------- */
main { max-width: var(--wrap); margin: 0 auto; padding: 28px var(--gut) 72px; }
.eyebrow { margin: 0 0 10px; font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--leaf); }
.section-title { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin: 40px 0 14px; }
.section-title h2 { margin: 0; font-size: 24px; }

/* ---------- Home intro ---------- */
.intro { padding: 36px 0 8px; display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: 48px; align-items: center; }
.intro h1 { font-size: clamp(34px, 4.6vw, 54px); line-height: 1.05; margin: 0 0 14px; }
.intro h1 span { color: var(--leaf); }
.lede { font-size: 17px; color: var(--text); max-width: 540px; margin: 0 0 24px; }
.bigsearch { display: flex; gap: 8px; align-items: center; padding: 6px; background: var(--surface); border: 1px solid var(--line-2); border-radius: 14px; box-shadow: var(--sh-2); max-width: 600px; }
.bigsearch .i { margin-left: 10px; color: var(--muted); }
.bigsearch input { flex: 1; min-width: 0; border: 0; box-shadow: none !important; background: transparent; font-size: 16px; padding: 10px 4px; }
.stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin: 18px 0 0; padding: 0; list-style: none; font-size: 13px; line-height: 1.3; color: var(--muted); max-width: 540px; }
.stats li { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; min-width: 0; }
.stats b { display: block; font: 600 22px/1.15 var(--sans); color: var(--ink); font-variant-numeric: tabular-nums; }
@media (max-width: 560px) { .stats { gap: 6px; } .stats li { padding: 8px; text-align: center; font-size: 12px; } .stats b { font-size: 19px; } }
/* Narrow screens and larger text: a third of the screen can't hold "365,000+", so one stat a line, the number then its words. */
@media (max-width: 360px) { .stats { grid-template-columns: minmax(0, 1fr); } .stats li { display: flex; align-items: baseline; gap: 8px; text-align: left; } .stats b { flex: none; } }
/* The origins globe (globe.js) */
.globe-card { background: var(--surface); border: 1px solid var(--line); border-radius: 22px; box-shadow: var(--sh-2); padding: 16px; min-width: 0; max-width: 460px; width: 100%; justify-self: end; }
.globe-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.globe-head h2 { font-size: 18px; font-weight: 600; margin: 0; color: var(--ink); }
.globe-head span { color: var(--muted); font-size: 13px; }
.globe { position: relative; width: min(100%, 400px); aspect-ratio: 1; margin: 6px auto 4px; }
.globe canvas { display: block; }
.globe:empty::before { content: ''; position: absolute; inset: 6px; border-radius: 50%; background: radial-gradient(circle at 35% 35%, var(--surface-2), var(--line)); }
.globe.off::after { content: 'The globe could not load.'; position: absolute; inset: 0; display: grid; place-items: center; color: var(--muted); font-size: 14px; }
.globe-tip { position: absolute; transform: translate(-50%, calc(-100% - 12px)); pointer-events: none; white-space: nowrap; color: var(--ink);
  background: var(--surface); border: 1px solid var(--line); border-radius: 8px; padding: 4px 9px; font-size: 13px; box-shadow: var(--sh-2); }
.chips.globe-chips { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; margin: 0 -16px; padding: 8px 16px 2px; }
.globe-chips .chip { flex: none; display: inline-flex; align-items: center; gap: 6px; }
.globe-chips .dot { width: 8px; height: 8px; border-radius: 50%; }
.globe-cap { color: var(--muted); font-size: 14px; margin: 10px 0 0; min-height: 2.9em; }
.globe-cap b { color: var(--ink); }

/* Scenario cards */
.scenarios { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.scenario { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; text-align: left; white-space: normal; height: auto; min-height: 0;
  padding: 16px; border-radius: var(--r); background: var(--surface); border: 1px solid var(--line); line-height: 1.4; }
.scenario:hover { border-color: var(--leaf); box-shadow: var(--sh-2); }
.scenario .i { width: 22px; height: 22px; color: var(--leaf); margin-bottom: 2px; }
.scenario b { font-size: 15px; color: var(--ink); }
.scenario span { font-size: 13px; color: var(--muted); font-weight: 400; }

/* ---------- Browse ---------- */
.browse-panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 4px 18px 16px; }
.lenses { display: flex; gap: 2px; overflow-x: auto; border-bottom: 1px solid var(--line); scrollbar-width: none; margin: 0 -2px; }
.lenses button { border: 0; border-radius: 0; background: none; min-height: 44px; padding: 0 12px; color: var(--muted); border-bottom: 2px solid transparent; margin-bottom: -1px; }
.lenses button:hover { color: var(--ink); }
.lenses button.on { color: var(--ink); border-bottom-color: var(--leaf); font-weight: 600; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; padding: 14px 0 2px; }
.chips.grouped { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 16px 24px; }
.cgroup :is(h2, h4) { margin: 0 0 8px; font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.cgroup > div { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { min-height: 30px; padding: 0 11px; border-radius: var(--r-sm); font-size: 13px; font-weight: 500; background: var(--surface-2); border-color: transparent; color: var(--text); }
.chip:hover { border-color: var(--line-2); color: var(--ink); }
.chip small { color: var(--muted); font-weight: 400; margin-left: 2px; font-size: 12px; }
.chip.on { background: var(--leaf-soft); border-color: var(--leaf); color: var(--leaf); }
.bar { display: flex; flex-wrap: wrap; gap: 10px 16px; align-items: center; margin: 18px 0 14px; color: var(--muted); font-size: 14px; }
#count { color: var(--ink); font-weight: 600; }
.bar .active { flex: 1; display: flex; flex-wrap: wrap; gap: 6px; }
.bar .active button { min-height: 28px; font-size: 12px; padding: 0 10px; border-radius: 999px; background: var(--leaf-soft); border-color: transparent; color: var(--leaf); }
.bar select { min-height: 34px; padding: 4px 10px; font-size: 14px; }
.toggle { display: inline-flex; gap: 8px; align-items: center; cursor: pointer; }
.toggle input { accent-color: var(--leaf); width: 16px; height: 16px; }

/* Cards */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 16px; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; text-decoration: none; color: inherit;
  display: flex; flex-direction: column; transition: box-shadow .2s, border-color .2s, transform .2s; }
.card:hover { border-color: var(--line-2); box-shadow: var(--sh-2); transform: translateY(-2px); color: inherit; }
.card .ph { aspect-ratio: 4/3; background: var(--surface-2) center/cover no-repeat; position: relative; }
.card .ph > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.card .ph .noimg { position: absolute; inset: 0; display: grid; place-items: center; color: var(--line-2); }
.card .ph .noimg .i { width: 40px; height: 40px; stroke-width: 1.2; }
.card .body { padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 2px; flex: 1; }
.card b { color: var(--ink); font-weight: 600; font-size: 15px; line-height: 1.3; }
.card i { color: var(--muted); font-size: 13px; }
.card .note { font-size: 13px; color: var(--muted); margin-top: 4px; }
.badge { position: absolute; top: 10px; right: 10px; display: inline-flex; align-items: center; gap: 4px; padding: 3px 8px; border-radius: 999px; font-size: 11px; font-weight: 600;
  background: color-mix(in srgb, var(--surface) 92%, transparent); color: var(--leaf); box-shadow: var(--sh-1); }
.badge .i { width: 13px; height: 13px; }
.tags { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 8px; }
.tag { font-size: 11px; font-weight: 500; padding: 2px 8px; border-radius: 999px; background: var(--leaf-soft); color: var(--leaf); }
.tag.warn { background: var(--warn-soft); color: var(--warn); }
.tag.gold { background: var(--gold-soft); color: var(--gold); }
#more { padding: 28px; text-align: center; color: var(--muted); }
#further h3 { font-size: 20px; margin: 36px 0 4px; }
#further .grid .ph { aspect-ratio: 5/2; }
.clist { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(320px, 100%), 1fr)); gap: 6px 12px; margin-bottom: 8px; }
.clist .result { width: 100%; text-align: left; justify-content: flex-start; min-height: 0; padding: 8px 12px; white-space: normal; background: var(--surface); }
.clist a.result { display: flex; color: inherit; text-decoration: none; border: 1px solid var(--line); border-radius: var(--r); }
.worldwide { margin: 32px 0; padding: 20px; background: var(--surface); border: 1px dashed var(--line-2); border-radius: var(--r-lg); }
.worldwide p { margin: 0 0 12px; }

/* ---------- Plant page ---------- */
.back { display: inline-flex; align-items: center; gap: 6px; margin-bottom: 16px; color: var(--muted); text-decoration: none; font-size: 14px; }
.back:hover { color: var(--ink); }
.hero { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 40px; align-items: start; }
.hero > * { min-width: 0; }
.viewer { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; position: sticky; top: 84px; box-shadow: var(--sh-1); }
.stage { aspect-ratio: 1; background: radial-gradient(circle at 50% 38%, var(--surface), var(--surface-2)); }
.stage model-viewer, .stage iframe, .stage img { width: 100%; height: 100%; border: 0; display: block; object-fit: cover; }
.stage .empty { height: 100%; display: grid; place-items: center; text-align: center; padding: 24px; color: var(--muted); }
.stage:has(> .empty) { aspect-ratio: auto; }
.stage .empty { min-height: 88px; }
.stage-poster { position: relative; width: 100%; height: 100%; padding: 0; border: 0; background: none; cursor: pointer; display: block; }
.stage-go { position: absolute; left: 50%; bottom: 16px; transform: translateX(-50%); display: inline-flex; align-items: center; gap: 8px; padding: 10px 16px; border-radius: 999px; background: var(--leaf); color: var(--on-leaf); font: 600 15px/1 var(--sans); box-shadow: var(--sh-2); white-space: nowrap; }
.stage-poster:hover .stage-go, .stage-poster:focus-visible .stage-go { background: var(--leaf-600); }
.mtabs { display: flex; gap: 6px; padding: 10px; overflow-x: auto; border-top: 1px solid var(--line); scrollbar-width: thin; }
.mtabs button { flex: none; min-height: 44px; gap: 6px; padding: 3px 10px 3px 3px; font-size: 13px; border-radius: 10px; }
.mtabs button img { flex: none; width: 36px; height: 36px; object-fit: cover; border-radius: 7px; background: var(--surface-2); }
.mtabs button.on { border-color: var(--leaf); background: var(--leaf-soft); color: var(--leaf); }
.credit { padding: 0 14px 14px; font-size: 12px; color: var(--muted); line-height: 1.5; }
.info h1 { font-size: clamp(30px, 3.4vw, 40px); margin: 0; }
.info .sci { font-style: italic; color: var(--muted); margin: 6px 0 4px; font-size: 17px; }
.info .aka { font-size: 14px; color: var(--muted); }
/* Cells draw their own right and bottom rules, so a half-empty last row stays clean. */
.facts { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); margin: 22px 0; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; }
.fact { background: var(--surface); padding: 12px 14px; color: var(--ink); font-size: 14px; font-weight: 500; box-shadow: 1px 0 0 var(--line), 0 1px 0 var(--line); }
.fact-wide { grid-column: 1 / -1; }
.bloom + .bloom { margin-top: 10px; }
.bloom-head { font-weight: 500; }
.bloom-head small { display: inline; color: var(--muted); }
.bloom-bar { display: grid; grid-template-columns: repeat(12, 1fr); gap: 2px; margin-top: 4px; }
.bloom-bar i { font-style: normal; font-size: 11px; text-align: center; padding: 3px 0; border-radius: 3px; background: var(--line); color: var(--muted); }
.bloom-bar i.on { background: var(--accent); color: var(--accent-ink); font-weight: 600; }
.bloom-bar.est i.on { opacity: .55; }
.fact span { display: block; font-size: 11px; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: .07em; margin-bottom: 3px; }
.fact span i { font-style: normal; }
.fact.warn { background: var(--warn-soft); color: var(--warn); }
.fact.ok { background: var(--leaf-soft); color: var(--leaf); }
.fact a.small { margin-left: 4px; font-weight: 400; }
.fact .big { display: block; font: 600 26px/1.15 var(--sans); color: var(--ink); }
.fact small { display: block; font-size: 11px; font-weight: 400; line-height: 1.35; margin-top: 3px; }
.actions { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 8px; }
section.txt { border-top: 1px solid var(--line); padding: 22px 0 6px; }
section.txt h3, section.txt h2.h3 { margin: 0 0 10px; }
section.txt p { margin: 0 0 12px; white-space: pre-line; }
.photo { width: 100%; border-radius: var(--r); margin: 10px 0; }
.sources { font-size: 12px; line-height: 1.6; color: var(--muted); border-top: 1px solid var(--line); padding-top: 16px; margin-top: 16px; }
.sources p { margin: 0 0 6px; }
.notice { background: var(--leaf-soft); color: var(--ink); border-radius: var(--r); padding: 12px 14px; margin: 12px 0; font-size: 14px; overflow-wrap: anywhere; } /* long links wrap instead of widening the page */
.notice.warn { background: var(--warn-soft); color: var(--warn); }
.danger-zone { margin-top: 40px; padding-top: 16px; border-top: 1px solid var(--warn-soft); }
button.danger { background: transparent; border-color: var(--warn); color: var(--warn); }
button.danger:hover { background: var(--warn-soft); }
.progress { height: 6px; border-radius: 3px; background: color-mix(in srgb, var(--leaf) 18%, transparent); overflow: hidden; margin: 10px 0 2px; }
.progress div { height: 100%; background: var(--leaf); transition: width .4s; }
.makecta { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-top: 12px; padding: 12px 14px; border-radius: var(--r); background: var(--leaf-soft); color: var(--ink); font-size: 13px; }
.makecta button { margin-left: auto; }

/* Maps */
.map { height: 380px; border-radius: var(--r); border: 1px solid var(--line); overflow: hidden; z-index: 0; }
.gview a { display: inline-block; width: auto !important; padding: 0 10px; font: 12px/30px var(--sans); color: #333 !important; background: #fff; }
.gview a + a { border-left: 1px solid #ccc; }
/* On a phone the map credit can wrap to two lines along the bottom; the Google buttons sit above it, not under it. */
@media (max-width: 520px) { .leaflet-bottom .leaflet-control.gview { margin-bottom: 40px; } }
.countries { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin: 12px 0 0; }
.countries .muted { font-size: 13px; margin-right: 4px; }
/* A plant page keeps the room for its map and for the countries row under it from the start: the map library and
   GBIF's counts arrive while people are already reading, and used to push everything below down by a screen's worth. */
#plantMap { min-height: 380px; }
#plantMap:empty { border-radius: var(--r); border: 1px solid var(--line); background: var(--surface-2); }
.countries { min-height: 26px; }
@media (max-width: 640px) {
  .countries { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
  .countries::-webkit-scrollbar { display: none; }
  .countries > * { flex: none; white-space: nowrap; }
}
.leaflet-popup-content { font: 13px/1.4 var(--sans); }
.leaflet-popup-content img { width: 160px; border-radius: 8px; display: block; margin-bottom: 4px; }
.geo { font-size: 13px; color: var(--muted); display: flex; gap: 8px; align-items: flex-start; margin-top: 10px; }

/* Community */
.tip { border-left: 3px solid var(--leaf); padding: 2px 0 2px 14px; margin: 14px 0; }
.tip p { margin: 4px 0 0; }
.tip .chip, .gallery .chip, section.txt .chip { min-height: 24px; font-size: 12px; margin-left: 6px; }
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 12px; margin: 14px 0; }
.gallery figure { margin: 0; }
.gallery img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 10px; }
.gallery figcaption { font-size: 12px; margin-top: 4px; }

/* ---------- Dialogs ---------- */
dialog { border: 1px solid var(--line); border-radius: 18px; padding: 0; width: min(560px, calc(100vw - 32px)); background: var(--surface); color: var(--text); box-shadow: 0 24px 70px rgb(0 0 0 / .28); }
dialog::backdrop { background: rgb(10 14 12 / .5); backdrop-filter: blur(2px); }
.dlg { padding: 24px; max-height: calc(100vh - 40px); max-height: calc(100dvh - 40px); overflow-y: auto; }
.dlg h2 { margin: 0 0 6px; font-size: 24px; }
.dlg h3 { margin: 20px 0 8px; font-size: 16px; }
.dlg select { margin-bottom: 8px; }
.dlg input[type=text] { width: 100%; }
.row { display: flex; justify-content: flex-end; gap: 8px; margin-top: 18px; }
.result { display: flex; gap: 12px; align-items: center; padding: 10px; border: 1px solid var(--line); border-radius: var(--r); margin: 8px 0; }
.result img { width: 56px; height: 56px; object-fit: cover; border-radius: 8px; background: var(--surface-2); }
.result .grow { flex: 1; min-width: 0; }
.result b { color: var(--ink); }
.result .score { font-size: 13px; color: var(--muted); }
.traits { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px; }
.trait { display: flex; flex-direction: column; gap: 4px; font-size: 13px; color: var(--muted); }
.trait select, .trait input { margin: 0; color: var(--ink); }
.cam { position: relative; aspect-ratio: 4/3; border-radius: var(--r); overflow: hidden; background: #0b0e0c; margin: 14px 0; }
.cam video, .cam img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.cam img { display: none; }
.cam.snapped img { display: block; }
.cam.snapped video { display: none; }
/* Live view | Photo (app.js camModes), as on Landmark Wiki */
.cam-modes { display: flex; gap: 4px; width: max-content; margin: 10px auto 0; padding: 4px; border-radius: 999px; background: var(--surface, #fff); border: 1px solid var(--line, #ddd); }
.cam-modes button { padding: 7px 16px; border: 0; border-radius: 999px; background: transparent; font-weight: 600; font-size: 14px; color: var(--muted); cursor: pointer; }
.cam-modes button[aria-pressed="true"] { background: var(--accent); color: #fff; }
/* The camera window, kept to one job (owner, 20 Nov 2026): in Photo mode the phone's own camera frames the shot, so
   there is no viewfinder box, shutter or Retake, only the button that opens it; the mode switch is one quiet button
   beside Close; the other matches open under one line. */
#identify[data-mode="photo"] #camBox:not(.snapped), #identify[data-mode="photo"] :is(#shutter, #retake, #flip) { display: none !important; }
#identify[data-mode="photo"] .camctl .upload { flex: 1 1 100%; justify-content: center; }
#identify .camctl .upload.primary { background: var(--leaf); border-color: var(--leaf); color: var(--on-leaf); }
#identify .row .cam-modes { margin: 0 auto 0 0; padding: 0; border: 0; background: none; }
#identify .row .cam-modes button { padding: 8px 0; min-height: 0; background: none; color: var(--muted); font-weight: 500; text-decoration: underline; }
#identify .row .cam-modes button[aria-pressed="true"] { display: none; }
.more-matches { margin: 10px 0 0; } .more-matches > summary { cursor: pointer; padding: 8px 0; color: var(--muted); font-size: 14px; } .more-matches[open] > summary { margin-bottom: 6px; }
.camhint { position: absolute; inset: 0; display: grid; place-items: center; text-align: center; padding: 24px; color: #e7ece8; font-size: 14px; }
.camctl { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.upload input { display: none; }
.geo input { accent-color: var(--leaf); margin-top: 3px; }

/* ---------- My plants, account, admin ---------- */
.mine-head { display: flex; flex-wrap: wrap; gap: 16px; align-items: flex-end; justify-content: space-between; margin-bottom: 20px; }
.mine-head h1 { margin: 0; }
.mine-head p { margin: 4px 0 0; }
.addname { display: flex; gap: 8px; }
.addname input { min-width: 0; width: 260px; }
#mineMap { margin-bottom: 20px; }
#account .facts, #admin .facts { margin-top: 12px; }
.series { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.series .fact { border: 1px solid var(--line); border-radius: var(--r); }
.spark { display: flex; align-items: flex-end; gap: 2px; height: 64px; margin-top: 10px; }
.spark span { flex: 1; background: var(--leaf); border-radius: 2px 2px 0 0; min-height: 2px; opacity: .85; }
table.nums { width: 100%; border-collapse: collapse; font-size: 14px; }
table.nums td { padding: 7px 0; border-bottom: 1px solid var(--line); }
table.nums td:last-child { text-align: right; font-variant-numeric: tabular-nums; color: var(--ink); font-weight: 500; }
.mailpreview { width: 100%; height: 900px; border: 1px solid var(--line); border-radius: var(--r); background: #fff; }
#about { max-width: 820px; }
#about ul { padding-left: 20px; }
#about li { margin-bottom: 10px; }

/* ---------- Footer ---------- */
.site-foot { border-top: 1px solid var(--line); background: var(--surface); margin-top: 40px; }
.foot-in { max-width: var(--wrap); margin: 0 auto; padding: 40px var(--gut) 24px; display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 32px; }
.foot-in p { margin: 12px 0 0; font-size: 14px; color: var(--muted); max-width: 360px; }
.foot-in h4, .foot-in .foot-h { margin: 0 0 10px; font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.foot-in nav a { display: block; color: var(--text); text-decoration: none; font-size: 14px; padding: 4px 0; }
.foot-in nav a:hover { color: var(--leaf); }
.legal { max-width: var(--wrap); margin: 0 auto; padding: 16px var(--gut) 28px; border-top: 1px solid var(--line); font-size: 12px; color: var(--muted); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; }

/* ---------- Small screens ---------- */
@media (max-width: 900px) {
  .intro { grid-template-columns: 1fr; gap: 24px; padding-top: 16px; }
  .globe-card { justify-self: stretch; max-width: none; }
  .globe { width: min(100%, 340px); }
  .hero { grid-template-columns: 1fr; gap: 24px; }
  .viewer { position: static; }
}
@media (max-width: 760px) {
  :root { --gut: 16px; }
  .top-in { flex-wrap: wrap; gap: 8px 12px; padding: 8px var(--gut); min-height: 56px; }
  .search { order: 3; flex-basis: 100%; max-width: none; }
  body.intro-visible .top .search { display: none; }
  .brand { font-size: 18px; gap: 8px; }
  .brand img { width: 28px; height: 28px; }
  .nav { gap: 0; flex-wrap: nowrap; }
  .navlink { padding: 8px 7px; font-size: 13px; }
  #install { display: none; }
  #snap .label, #install .label { display: none; }
  #snap { width: 40px; padding: 0; }
  main { padding: 18px var(--gut) 56px; }
  .bigsearch { flex-wrap: wrap; }
  .bigsearch input { flex-basis: calc(100% - 40px); }
  .bigsearch button { flex: 1; }
  .browse-panel { padding: 2px 12px 12px; }
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .card .body { padding: 10px 11px 12px; }
  .scenarios { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .scenario { padding: 12px; }
  .foot-in { grid-template-columns: 1fr 1fr; }
  .foot-in > :first-child { grid-column: 1 / -1; }
  .addname input { width: auto; flex: 1; }
}
/* Installed app: respect the phone's notch and home bar. */
@media (display-mode: standalone) {
  .top-in { padding-top: max(10px, env(safe-area-inset-top)); }
  main { padding-bottom: max(72px, env(safe-area-inset-bottom)); }
}

/* Home sections and rows */
.home-sec { margin-top: 8px; }
.home-sec .section-title a { font-size: 14px; font-weight: 500; text-decoration: none; white-space: nowrap; }
.sec-sub { margin: -6px 0 14px; font-size: 14px; }
.grid.shelf { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.inline-select { field-sizing: content; font: inherit; color: var(--leaf); border: 0; border-bottom: 2px dashed var(--line-2); border-radius: 0; background: transparent; padding: 0 4px; min-height: 0; cursor: pointer; max-width: 60vw; }
.inline-select:focus { box-shadow: none; border-bottom-color: var(--leaf); }
.page-head { margin: 4px 0 18px; }
.page-head p { margin: 0; }
.country-pick { display: flex; flex-wrap: wrap; gap: 12px 20px; align-items: center; width: 100%; }
.country-pick label { display: inline-flex; gap: 10px; align-items: center; font-size: 14px; color: var(--muted); }
.country-pick p { flex-basis: 100%; margin: 0; }
.seg { display: inline-flex; border: 1px solid var(--line-2); border-radius: 10px; overflow: hidden; }
.seg button { border: 0; border-radius: 0; min-height: 44px; font-size: 13px; background: var(--surface); }
.seg button + button { border-left: 1px solid var(--line-2); }
.seg button.on { background: var(--leaf-soft); color: var(--leaf); }
@media (max-width: 760px) {
  .grid.shelf { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid.shelf > :nth-child(n+5) { display: none; }
  .home-sec .section-title { flex-wrap: wrap; }
}

/* Identify results and the "Saved" sheet */
.result-acts { display: flex; gap: 6px; }
.result-acts button { min-height: 34px; padding: 0 12px; }
.result .rname, .result .rsci { display: block; overflow-wrap: anywhere; line-height: 1.3; }
.result .rsci { color: var(--muted); font-size: 14px; }
.result .score { margin-top: 2px; }
.result .pct { font-weight: 600; color: var(--leaf); }
.ask-chips button { white-space: normal; text-align: left; }
/* Sign-in card, the same in every wiki of the family (WIKI-HARMONY 4a) */
.signin-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 16px; margin: 12px 0; max-width: 560px; }
.signin-card p { margin: 0 0 12px; }
.signin-card .gbtn { display: inline-flex; align-items: center; gap: 10px; }
/* The email box (email-signin.js) is added under the Google button a moment after the card is drawn, and again after each
   redraw: its room is kept so the page below does not jump (heights of the finished card). */
.signin-card:not(:has(.email-signin)) { min-height: 224px; }
@media (max-width: 580px) { .signin-card:not(:has(.email-signin)) { min-height: 251px; } }
@media (max-width: 415px) { .signin-card:not(:has(.email-signin)) { min-height: 303px; } }
.gmark { width: 18px; height: 18px; flex: none; background: #fff; border-radius: 50%; padding: 2px; box-sizing: content-box; } /* Google's mark sits on white */
.signin-status { margin: 8px 0 4px !important; color: var(--danger); min-height: 1em; }
.signin-status:empty { min-height: 0; margin: 0 !important; }
.signedin { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
.signedin .muted { overflow-wrap: anywhere; }
@media (max-width: 560px) {
  dialog { width: 100%; max-width: 100%; max-height: 100dvh; margin: auto 0 0; border-radius: 18px 18px 0 0; border-width: 1px 0 0; }
  .dlg { padding: 16px; max-height: 92dvh; }
  .dlg h2 { font-size: 21px; }
  .cam { margin: 10px 0; }
  .cam.snapped { aspect-ratio: auto; height: 140px; }
  .camctl > * { flex: 1 1 auto; justify-content: center; }
  .result { flex-wrap: wrap; align-items: flex-start; gap: 10px; }
  .result img { width: 52px; height: 52px; }
  .result .grow { flex: 1 1 calc(100% - 62px); }
  .result-acts { flex: 1 1 100%; }
  .result-acts button { flex: 1; min-height: 40px; justify-content: center; }
}
.saved-head { display: flex; gap: 12px; align-items: center; margin-bottom: 8px; }
.saved-head > .i { width: 36px; height: 36px; padding: 8px; border-radius: 999px; background: var(--leaf-soft); color: var(--leaf); }
.saved-head h2 { margin: 0; }
.saved-head p { margin: 0; }
.eggs h3 { display: flex; gap: 8px; align-items: center; font-size: 16px; margin: 16px 0 8px; }
blockquote { margin: 8px 0; padding: 10px 14px; border-left: 3px solid var(--gold); background: var(--gold-soft); border-radius: 0 10px 10px 0; color: var(--ink); }
blockquote footer { font-size: 12px; color: var(--muted); margin-top: 4px; }
.hide-note { margin-top: 14px; border-top: 1px solid var(--line); padding-top: 12px; }
.hide-note summary { cursor: pointer; font-weight: 500; color: var(--ink); }
.hide-note .seg { margin: 10px 0 4px; }
.hide-note textarea { margin: 6px 0 8px; }

/* Plant Quest */
.hunt { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 20px; align-items: start; }
.hunt-filters { padding-top: 0; margin-bottom: 10px; }
#huntMap .map { height: min(72vh, 720px); }
/* Plant Quest: a world-map preview (Esri, the same basemap) behind the map until its tiles cover it, so the page has its
   picture at first paint (index.html preloads it). */
#huntMap .map { background: var(--surface-2) url("https://server.arcgisonline.com/ArcGIS/rest/services/Canvas/World_Light_Gray_Base/MapServer/export?bbox=-180,-60,180,80&bboxSR=4326&size=800,420&format=jpg&f=image") center / cover no-repeat; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) #huntMap .map { background-image: url("https://server.arcgisonline.com/ArcGIS/rest/services/Canvas/World_Dark_Gray_Base/MapServer/export?bbox=-180,-60,180,80&bboxSR=4326&size=800,420&format=jpg&f=image"); } }
#huntMap .map.tiled { background-image: none !important; } /* beats the dark-scheme rule */
.hunt-side { display: flex; flex-direction: column; gap: 14px; position: sticky; top: 84px; max-height: calc(100vh - 100px); max-height: calc(100dvh - 100px); overflow-y: auto; }
.hcard { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 16px; }
.hcard :is(h2, h3) { margin: 0 0 6px; font-size: 18px; }
.hcard h3, .hcard h4 { margin: 14px 0 6px; font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.steps { list-style: none; padding: 0; margin: 8px 0; display: grid; gap: 8px; }
.steps li { display: flex; gap: 10px; align-items: center; font-size: 14px; color: var(--ink); }
.steps .i { color: var(--leaf); }
.quest { display: grid; grid-template-columns: 1fr auto; gap: 2px 8px; font-size: 13px; margin-bottom: 6px; }
.quest .progress { grid-column: 1 / -1; margin: 2px 0 0; }
.board { margin: 0; padding-left: 20px; font-size: 14px; }
.board li { display: flex; justify-content: space-between; padding: 3px 0; }
ul.plain { list-style: none; padding: 0; margin: 0; font-size: 13px; display: grid; gap: 6px; }
.linkish { min-height: 0; padding: 0; border: 0; background: none; color: var(--leaf); font-size: 12px; text-decoration: underline; }
.hpop { min-width: 180px; }
.hpop img { width: 200px; height: 140px; object-fit: cover; border-radius: 8px; display: block; margin-bottom: 6px; }
.hacts { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.hacts button { min-height: 28px; padding: 0 10px; font-size: 12px; }
.lm-icon span { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 999px; background: #2f6b47; color: #fff; border: 2px solid #fff; box-shadow: 0 2px 6px rgb(0 0 0 / .3); }
.lm-icon span.adopted { background: #b7791f; }
.lm-icon span.heritage { background: #7a4a1d; }
.my-plant .my-photos { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; margin: 4px 0 10px; }
.my-plant .my-photos img { height: 140px; width: auto; border-radius: 12px; display: block; }
.my-plant .my-list li { padding: 4px 0; }
#myPlantMap .map { height: 260px; margin-top: 8px; }
.mine-tools { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin: 4px 0 14px; }
.mine-tools select { flex: 1 1 200px; min-width: 0; max-width: 360px; }
#mineMap .map { height: min(70vh, 640px); }
fieldset.where { border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; margin: 12px 0; display: grid; gap: 8px; }
fieldset.where legend { padding: 0 6px; font-size: 14px; color: var(--muted); }
fieldset.where label { display: flex; gap: 8px; align-items: center; min-height: 32px; }
#pickMap .map, #spotMap .map { height: 260px; }
.lm-icon span.shop { background: #2563eb; }
.lm-icon .i { width: 16px; height: 16px; }
.timeline { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 10px; }
.timeline figure { margin: 0; }
.timeline img, .timeline .noimg { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 10px; background: var(--surface-2); display: grid; place-items: center; }
.timeline figcaption { font-size: 12px; color: var(--muted); margin-top: 4px; }
@media (max-width: 900px) {
  .hunt { grid-template-columns: 1fr; }
  .hunt-side { position: static; max-height: none; }
  #huntMap .map { height: 64vh; }
}

/* Near me */
.near-btn { min-height: 30px; padding: 0 12px; font-size: 13px; border-radius: var(--r-sm); }
.near-link { margin: 14px 0 0; font-size: 14px; display: flex; flex-wrap: wrap; gap: 6px 18px; }
.near-link a { display: inline-flex; gap: 6px; align-items: center; font-weight: 500; text-decoration: none; }
ul.near li { display: grid; grid-template-columns: 1fr auto; gap: 0 8px; }
ul.near li span { color: var(--muted); font-size: 12px; }
ul.near li small { grid-column: 1 / -1; color: var(--muted); font-size: 11px; }
.near-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.near-grid a { display: flex; flex-direction: column; gap: 4px; text-decoration: none; color: var(--ink); font-size: 11px; line-height: 1.25; }
.near-grid img, .near-grid .noimg { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 8px; background: var(--surface-2); display: grid; place-items: center; }

/* Quick answers */
.ask-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.ask-answer:not(:empty) { margin-top: 12px; padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); }
.ask-answer p { margin: 0 0 8px; white-space: normal; }
.ask-answer blockquote { margin: 8px 0 0; }
.ask-top { margin-top: 14px; border-top: 1px solid var(--line); padding-top: 12px; }
.ask-top h3 { font-size: 16px; margin: 0 0 8px; }
.web-answer:not(:empty) { margin-top: 10px; }
.web-answer .ai { border-top: 1px dashed var(--line-2); padding-top: 10px; }
.web-answer .ai p { margin: 0 0 6px; }
.web-answer .linkish { display: inline-flex; gap: 6px; align-items: center; font-size: 13px; }

/* Plans */
.plans-wrap { overflow-x: auto; }
table.plans { width: 100%; border-collapse: collapse; font-size: 14px; min-width: 520px; }
table.plans th, table.plans td { padding: 10px 12px; border-bottom: 1px solid var(--line); text-align: center; vertical-align: middle; }
table.plans th:first-child, table.plans td:first-child { text-align: left; color: var(--text); }
table.plans th { font-weight: 600; color: var(--ink); }
table.plans th small { display: block; font-weight: 400; color: var(--muted); font-size: 12px; }
table.plans .cur { background: var(--leaf-soft); }
table.plans .i { color: var(--leaf); }
.plan-cards { display: none; }
.plan-card { border: 1px solid var(--line); border-radius: 14px; padding: 14px; background: var(--surface); display: flex; flex-direction: column; gap: 10px; }
.plan-card.cur { border-color: var(--leaf); background: var(--leaf-soft); }
.plan-top { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.plan-top b { font-size: 17px; color: var(--ink); }
.plan-top span { color: var(--muted); font-size: 13px; }
.plan-top em { font-style: normal; color: var(--leaf); font-weight: 600; }
.plan-card ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; font-size: 14px; }
.plan-card li { display: flex; gap: 8px; align-items: flex-start; }
.plan-card li .i { flex: none; width: 16px; height: 16px; margin-top: 2px; color: var(--leaf); }
.plan-card button { margin-top: auto; justify-content: center; }
details.support > summary { cursor: pointer; list-style: none; }
details.support > summary::-webkit-details-marker { display: none; }
details.support > summary h3 { display: inline; }
details.support > summary::after { content: ' +'; color: var(--muted); font-size: 20px; }
details.support[open] > summary::after { content: ' −'; }
/* Phones: swipe between plan cards instead of a sideways-scrolling table. */
@media (max-width: 560px) {
  .plans-wrap { display: none; }
  .plan-cards { display: flex; align-items: flex-start; gap: 10px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none;
    margin: 0 calc(-1 * var(--gut)); padding: 2px var(--gut) 6px; }
  .plan-cards::-webkit-scrollbar { display: none; }
  .plan-card { flex: 0 0 82%; scroll-snap-align: center; }
}

/* Admin pages (same layout as Global DC Wiki's) */
.stathead { display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-end; justify-content: space-between; margin-bottom: 8px; }
.statctl { display: flex; gap: 8px; align-items: center; }
.kpis { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 12px; margin: 10px 0 24px; }
.kpi { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 14px 16px; }
.kpi .k { font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: .07em; color: var(--muted); }
.kpi .v { font: 600 28px/1.2 var(--sans); color: var(--ink); margin: 4px 0 2px; }
.kpi .s { font-size: 12px; color: var(--muted); line-height: 1.4; }
.statcharts { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(360px, 100%), 1fr)); gap: 16px; margin-bottom: 24px; }
.statcharts section { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 14px 16px; }
.statcharts h2 { font-size: 15px; margin: 0 0 8px; }
.schart { width: 100%; height: auto; display: block; }
.schart text { font: 10px var(--sans); fill: var(--muted); }
.tblwrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); margin-bottom: 12px; }
.tbl { width: 100%; border-collapse: collapse; font-size: 14px; }
.tbl th, .tbl td { padding: 9px 12px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.tbl th { font-size: 12px; font-weight: 600; color: var(--muted); background: var(--surface-2); }
.tbl tr:last-child td { border-bottom: 0; }
.tbl .num { text-align: right; font-variant-numeric: tabular-nums; }
.tbl.compact td, .tbl.compact th { padding: 7px 10px; }
.tbl .sub { display: block; font-size: 12px; color: var(--muted); }
.tbl select { min-height: 30px; padding: 2px 8px; font-size: 13px; }
.tbl tr.paused td { opacity: .6; }
button.xs { min-height: 26px; padding: 0 8px; font-size: 12px; }
.modimg { width: 64px; height: 64px; object-fit: cover; border-radius: 6px; display: block; margin-bottom: 4px; }
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 14px 16px; }
.toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%) translateY(20px); background: var(--ink); color: var(--bg); padding: 10px 16px; border-radius: 10px; font-size: 14px; opacity: 0; transition: .2s; pointer-events: none; z-index: 50; }
.toast.show { opacity: 1; transform: translateX(-50%); }

.subnav { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 18px; }
.subnav a { padding: 10px 14px; text-decoration: none; color: var(--muted); border-bottom: 2px solid transparent; margin-bottom: -1px; font-weight: 500; }
.subnav a.on { color: var(--ink); border-bottom-color: var(--leaf); }
.subnav a.console { margin-left: auto; color: var(--leaf); font-size: 14px; }
@media (max-width: 520px) { .subnav { flex-wrap: wrap; } .subnav a.console { margin-left: 0; } }
/* Mid-width screens: keep the header on one line by letting the search shrink first. */
@media (max-width: 1100px) and (min-width: 761px) { .search { min-width: 150px; } .navlink { padding: 8px 7px; } #snap .label { display: none; } #snap { width: 40px; padding: 0; } }
/* Phones and small tablets (up to 900 px, as Flight Wiki; the same in every wiki of the family): brand and search share one slim top row; the menu is a tab bar at the bottom, in thumb reach,
   with Identify as the big middle button. Admin and Sign out live on the Account page there. */
.nav-i { display: none; }
@media (max-width: 900px) {
  .toast { bottom: calc(84px + env(safe-area-inset-bottom)); }
  .top { backdrop-filter: none; -webkit-backdrop-filter: none; } /* a blur here would trap the fixed tab bar */
  .top-in { flex-wrap: nowrap; gap: 10px; padding-top: 8px; padding-bottom: 8px; min-height: 0; }
  .brand { flex: none; }
  .search { order: 0; flex: 1 1 0; min-width: 0; }
  .sharebtn { margin-left: auto; } /* at the right edge, also on the home page where the search is hidden (as Coffee Wiki) */
  .nav { position: fixed; left: 0; right: 0; bottom: 0; z-index: 1100; /* above Leaflet's panes */ margin: 0; gap: 0; justify-content: space-around; align-items: flex-end;
    background: var(--nav); border-top: 1px solid var(--nav-line);
    padding: 4px 4px max(6px, env(safe-area-inset-bottom)); }
  .navlink { flex: 1 1 0; display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 6px 2px; font-size: 11px; min-width: 0; text-align: center; }
  .navlink span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
  .navlink .extra, .navlink.spec, .nav-sep, #adminLink, #install { display: none !important; } /* the tab bar is the shared menu only */
  .nav-i { display: block; width: 22px; height: 22px; }
  #browseLink { order: 1; } #snap { order: 2; } #mineLink { order: 3; } #accountLink { display: none !important; } /* three tabs; Account is under the My plants heading */
  #snap { display: grid; place-items: center; flex: none; width: 54px; height: 54px; padding: 0; border-radius: 999px; margin: -20px 6px 2px; box-shadow: 0 4px 14px rgb(0 0 0 / .35); }
  #snap .i { width: 24px; height: 24px; }
  body { padding-bottom: calc(68px + env(safe-area-inset-bottom)); }
  .hunt-filters { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; margin-left: calc(-1 * var(--gut)); margin-right: calc(-1 * var(--gut)); padding-left: var(--gut); padding-right: var(--gut); }
  .hunt-main { min-width: 0; }
  .hunt-filters::-webkit-scrollbar { display: none; }
  .hunt-filters > * { flex: none; white-space: nowrap; }
}

/* ---------- Admin dashboard: the week at a glance ---------- */
.dash-top { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin: 4px 0 6px; }
.dash-line { margin: 0; font-size: 13px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; color: var(--leaf); }
.dash-top .statctl { display: flex; gap: 8px; margin: 0; flex-direction: row; }
.dash-sec .schart { display: block; width: 100%; max-height: 190px; }
.dash-top .statctl input, .dash-top .statctl button { min-height: 34px; font-size: 13px; }
.dash-title { font-size: clamp(26px, 3vw, 32px); margin: 6px 0 8px; }
.dash-pills { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.pill { display: inline-flex; align-items: center; min-height: 26px; padding: 0 10px; border-radius: 999px; font-size: 13px; font-weight: 600; text-decoration: none; }
.pill.good { background: var(--leaf-soft); color: var(--leaf); }
.pill.watch { background: var(--gold-soft); color: var(--gold); }
.pill.flat { background: var(--surface-2); color: var(--muted); }
.delta { display: inline-flex; align-items: center; min-height: 24px; padding: 0 9px; border-radius: 999px; font-size: 12px; font-weight: 600; white-space: nowrap; }
.delta.up { background: var(--leaf-soft); color: var(--leaf); }
.delta.down { background: var(--warn-soft); color: var(--warn); }
.delta.flat { background: var(--surface-2); color: var(--muted); }
.tiles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 20px; }
.tile { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 14px; display: grid; gap: 4px; justify-items: start; }
.tile .tv { font-size: 34px; font-weight: 700; line-height: 1.1; color: var(--ink); }
.tile .tl { font-size: 13px; color: var(--muted); }
.dash-sec { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 14px 16px; margin-bottom: 16px; }
.dash-sec h2 { font-size: 17px; margin: 0 0 10px; }
.dash-two { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.hbars { display: grid; gap: 8px; }
.hbar { display: grid; grid-template-columns: minmax(0, 220px) 1fr auto auto; gap: 10px; align-items: center; font-size: 14px; }
.hbar .hl { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.hbar .hb { height: 10px; background: var(--surface-2); border-radius: 999px; overflow: hidden; }
.hbar .hb i { display: block; height: 100%; background: var(--leaf); border-radius: 999px; }
.mini { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 16px; }
.mini b { display: block; font-size: 22px; color: var(--ink); line-height: 1.2; }
.mini span { font-size: 13px; color: var(--muted); }
.mini .spark { display: block; margin-top: 4px; max-width: 100%; }
.dash-sec .mini { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
.mini-more { grid-column: 1 / -1; }
.mini-more > summary { list-style: none; cursor: pointer; display: inline-block; }
.mini-more > summary::-webkit-details-marker { display: none; }
.mini-more > summary span::after { content: " ▾"; }
.mini-more[open] > .mini { margin-top: 10px; padding: 10px 12px; border: 1px solid var(--line); border-radius: var(--r); }
.dash-more { margin: 4px 0 16px; }
/* The admin pages' one accent is clay, light and dark. */
.adm { --leaf: #c6613f; --leaf-600: #a94f30; --leaf-soft: #F6E5DE; --on-leaf: #FFFFFF; --good: #1F7A4D; --good-soft: #E5F1EA; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .adm { --leaf: #d97757; --leaf-600: #e58f72; --leaf-soft: #3A2219; --on-leaf: #1A0F0A; --good: #3FA36B; --good-soft: #15291F; } }
:root[data-theme="dark"] .adm { --leaf: #d97757; --leaf-600: #e58f72; --leaf-soft: #3A2219; --on-leaf: #1A0F0A; --good: #3FA36B; --good-soft: #15291F; }
/* Green still means good: rises and all-clear pills keep the leaf green. */
.adm .delta.up, .adm .pill.good { background: var(--good-soft); color: var(--good); }
.dash-more > summary { cursor: pointer; font-weight: 600; color: var(--leaf); padding: 6px 0; }
@media (max-width: 760px) {
  .tiles { grid-template-columns: 1fr 1fr; }
  .dash-two { grid-template-columns: 1fr; }
  .hbar { grid-template-columns: 1fr auto; }
  .hbar .hb { grid-column: 1 / -1; grid-row: 2; }
  .hbar .delta { display: none; }
}

/* ---------- Engagement: sign-up nudge, watering, streaks ---------- */
.signup-nudge { display: grid; gap: 2px; margin: 10px 0 4px; padding: 10px 12px; border-radius: var(--r); background: var(--leaf-soft); color: var(--ink); font-size: 14px; }
.signup-nudge span { color: var(--muted); font-size: 13px; }
.water-due { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.water-due .i { color: var(--leaf); }
.note.water { color: var(--muted); }
.note.water.due { color: var(--gold); font-weight: 600; }
#mineLink { position: relative; }
#mineLink[data-badge]:not([data-badge=""])::after { content: attr(data-badge); position: absolute; top: 2px; right: 2px; min-width: 16px; height: 16px; padding: 0 4px; border-radius: 999px; background: var(--gold); color: #0B121C; font-size: 10px; font-weight: 700; line-height: 16px; text-align: center; }
.streak { display: grid; grid-template-columns: auto 1fr; gap: 0 10px; align-items: center; margin: 10px 0; padding: 10px 12px; border: 1px solid var(--line); border-radius: var(--r); }
.streak b { grid-row: span 2; font-size: 28px; color: var(--ink); }
.streak.on b { color: var(--leaf); }
.streak span { font-weight: 600; color: var(--ink); font-size: 14px; }
.streak small { color: var(--muted); font-size: 12px; }
.langpick { display: grid; gap: 4px; margin-top: 6px; font-size: 13px; color: var(--muted); }
.langpick select { min-height: 36px; max-width: 200px; }
.play-badge { display: block; width: max-content; margin: 14px 0 0 -10px; border-radius: 10px; }
.play-badge img { display: block; height: 58px; width: auto; }
.play-badge[hidden] { display: none; }
.foot-play { margin: 10px 0 0 -8px; }
.foot-play img { height: 52px; }
/* Found through the Google search fallback (api/google.mjs). */
.badge.google { top: auto; bottom: 10px; color: var(--muted); }
.gline { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 2px 0 8px; }
.gbadge, .gtag { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 600; color: var(--muted); text-decoration: none; }
.gbadge { padding: 3px 10px; border-radius: 999px; border: 1px solid var(--line, color-mix(in srgb, currentColor 20%, transparent)); background: var(--surface); }
.gbadge .i, .gtag .i { width: 14px; height: 14px; }

/* Plant Quest: details card over the bottom of the map for the place you tapped (as Coffee Wiki), and your labelled position */
.near-stage { position: relative; scroll-margin-top: 76px; }
.near-card { position: absolute; left: 10px; right: 10px; bottom: 10px; z-index: 1100; max-height: calc(100% - 20px); overflow: auto;
  border: 1px solid var(--line); border-radius: 14px; background: var(--surface); padding: 12px 14px 2px; box-shadow: 0 10px 30px rgb(0 0 0 / .35); }
.near-card[hidden] { display: none; }
.near-card-head { display: flex; align-items: flex-start; gap: 12px; }
.near-card-head > div { flex: 1; min-width: 0; }
.near-card-head img { width: 56px; height: 56px; object-fit: cover; border-radius: 10px; flex: none; }
.near-card-head h2 { font-size: 18px; margin: 2px 0 8px; }
.near-card .type { color: var(--muted); font-size: 13px; }
.near-card .near-x { flex: none; min-height: 32px; width: 32px; padding: 0; }
.near-facts { margin: 0 0 10px; display: grid; gap: 4px; }
.near-facts div { display: grid; grid-template-columns: 110px 1fr; gap: 8px; }
.near-facts dt { color: var(--muted); font-size: 13px; }
.near-facts dd { margin: 0; }
.near-card .actions { margin-bottom: 10px; gap: 6px; }
.lm-icon.picked span { transform: scale(1.35); box-shadow: 0 0 0 3px #b4541c, 0 2px 6px rgb(0 0 0 / .3); }
@media (max-width: 560px) {
  #huntMap .map { height: 64vh; }
  .near-card { left: 8px; right: 8px; bottom: 8px; max-height: 55%; padding: 10px 12px 0; }
  .near-card-head h2 { font-size: 17px; margin-bottom: 6px; }
  .near-facts div { grid-template-columns: 76px 1fr; }
  .near-facts dt { font-size: 11px; padding-top: 3px; }
  .near-card .actions .btn { min-height: 34px; padding: 6px 10px; font-size: 13px; }
}
.leaflet-tooltip.near-you { background: #2563eb; color: #fff; border: 0; font-weight: 600; box-shadow: 0 2px 8px rgba(0,0,0,.25); }
.leaflet-tooltip.near-you::before { border-top-color: #2563eb; }

/* ---------- Trips (My plants) ---------- */
.trip-hint { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.trip-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; flex-wrap: wrap; margin: 4px 0 14px; }
.trip-head h2 { margin: 0 0 4px; }
.trip-card { display: grid; grid-template-columns: 84px 1fr; gap: 12px; align-items: center; text-decoration: none; color: inherit; padding: 10px; }
.trip-card img, .trip-card .noimg { width: 84px; height: 84px; object-fit: cover; border-radius: 10px; display: grid; place-items: center; background: var(--surface-2); }
.trip-card h3 { margin: 0 0 4px; font-size: 16px; }
#tripMap .map { height: min(56vh, 520px); margin-bottom: 14px; }
.trip-num span { display: grid; place-items: center; width: 26px; height: 26px; border-radius: 999px; background: #2f6b47; color: #fff; font: 700 12px/1 var(--sans); border: 2px solid #fff; box-shadow: 0 2px 6px rgb(0 0 0 / .3); }
.trip-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.trip-list a { display: grid; grid-template-columns: 64px 26px 1fr; gap: 10px; align-items: center; padding: 8px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); color: inherit; text-decoration: none; }
.trip-list img, .trip-list .noimg { width: 64px; height: 64px; object-fit: cover; border-radius: 8px; display: grid; place-items: center; background: var(--surface-2); }
.trip-list .n { display: grid; place-items: center; width: 26px; height: 26px; border-radius: 999px; background: #2f6b47; color: #fff; font-weight: 700; font-size: 12px; }
.trip-list small, .trip-pick small { display: block; color: var(--muted); font-size: 13px; }
.trip-dlg { width: min(560px, calc(100vw - 24px)); }
.trip-days { max-height: 52vh; overflow: auto; margin: 0 0 12px; }
.trip-day { display: flex; justify-content: space-between; align-items: center; margin: 12px 0 6px; }
.trip-pick { display: grid; grid-template-columns: auto 44px 1fr; gap: 10px; align-items: center; padding: 6px 0; border-bottom: 1px solid var(--line); cursor: pointer; }
.trip-pick img, .trip-pick .noimg { width: 44px; height: 44px; object-fit: cover; border-radius: 8px; display: grid; place-items: center; background: var(--surface-2); }
.trip-pick input { width: 20px; height: 20px; }
.trip-dlg .field { display: grid; gap: 4px; margin: 12px 0 4px; }
.trip-dlg .field span { font-size: 13px; color: var(--muted); }
.trip-day .linkish { background: none; border: 0; min-height: 0; padding: 0; color: var(--leaf); text-decoration: underline; font-size: 13px; cursor: pointer; }
.dlg.saved .snap-next { width: 100%; min-height: 48px; margin: 12px 0 8px; font-size: 16px; justify-content: center; }

/* My plants → Globe (public/plantglobe.js) */
.mine-globe { height: min(70vh, 640px); border-radius: 16px; overflow: hidden; background: radial-gradient(circle at 50% 45%, #0f1b2d, #05080d 70%); margin: 4px 0 8px; position: relative; }
.pg-tip { background: rgb(7 12 20 / .9); color: #fff; padding: 6px 10px; border-radius: 8px; font: 13px/1.4 var(--sans); max-width: 240px; }
@media (max-width: 560px) { .mine-globe { height: 58vh; } }
.notice.upsell { display: grid; gap: 8px; } .notice.upsell p { margin: 0; } .notice.upsell .btn { justify-self: start; }

/* Each page is at least a screen tall, so the footer starts below the fold and isn't pushed down as content arrives. */
body > main:not([hidden]) { min-height: calc(100vh - 64px); }
/* The two personal pages are kept about as tall as they are once drawn (My plants and trips about 330px, Account longer than a screen), on a laptop too, so the footer neither jumps while they fill in nor sits a screen below a short list (O022). */
body > main#mine:not([hidden]) { min-height: 328px; }
body > main#account:not([hidden]) { min-height: 1435px; } /* At 1280 px wide the page ends about 1428px tall, so 1435px is held and the footer stays still (O022). */
/* On a phone the signed-out Account page is about 1645px tall (a little more is held, so a few pixels of font difference do not move it) once drawn (measured 19 Nov: the footer moved from 1461 to 1668 at 390px wide), so it holds that much from the start. */
@media (max-width: 700px) { body > main#account:not([hidden]) { min-height: 1652px; } }

/* Speed: the browser skips styling and laying out what is off screen until it scrolls near (sizes are a first guess,
   then remembered). Home sections below the introduction, Browse and row cards, the Hunt list and the footer. */
.home-sec { content-visibility: auto; contain-intrinsic-size: auto 600px; }
#grid > .card { content-visibility: auto; contain-intrinsic-size: auto 240px; }
.hunt-side { content-visibility: auto; contain-intrinsic-size: auto 1200px; }
.site-foot { content-visibility: auto; contain-intrinsic-size: auto 900px; }
#detail section.txt, #detail .sources { content-visibility: auto; contain-intrinsic-size: auto 360px; }

/* Adapting to each person (public/adaptive.js, public/home-adapt.js): reason lines, home cards, For you, Personalisation */
.why { display: inline-block; font-size: 12px; color: var(--muted); text-decoration: none; }
.why:hover { color: var(--accent); text-decoration: underline; }
.why-row { margin: 6px 0 0; min-height: 0; }
.why-row:empty { display: none; }
.why-line { display: block; font-size: 12px; color: var(--muted); margin-top: 4px; }
.card .notforme { margin-top: 6px; min-height: 26px; font-size: 12px; }
.home-cards:empty { display: none; }
.home-cards { display: grid; gap: 8px; margin: 12px 0 0; }
/* Today card (public/adaptive.js draws the frame; section 11.2) */
.today-slot { margin: 12px 0 0; } .today-slot:empty { display: none; } .today-slot .today-card { margin: 0; }
/* What to do next (public/adaptive.js draws it; section 12.4): first on home, and at the top of Account once signed in */
.steps-slot { margin: 12px 0 0; } .steps-slot:empty { display: none; } .steps-slot .pz-steps { margin: 0; }
/* The two cards under the globe hold their place until the app has drawn them, so the sections below do not move (layout shift, O019). Released in app.js. */
.steps-slot.is-wait { display: block; min-height: 316px; } .today-slot.is-wait, .today-slot.is-wait:empty { display: block; min-height: 252px; }
@media (max-width: 700px) { .steps-slot.is-wait { min-height: 376px; } .today-slot.is-wait, .today-slot.is-wait:empty { min-height: 202px; } }
.today-card .i, .pz-btn .i { width: 16px; height: 16px; vertical-align: -3px; margin-right: 4px; }
.home-card { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 0; }
.home-card > span { flex: 1 1 220px; }
.home-card .i { flex: none; }
.trip-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 12px 14px; display: block; }
.trip-card .section-title h2 { font-size: 18px; }
.bigsearch.cam-first #heroCam { order: -1; }
@media (max-width: 560px) { .bigsearch.cam-first { flex-wrap: wrap; } .bigsearch.cam-first #heroCam { flex-basis: 100%; } }
.pers-list { list-style: none; padding: 0; margin: 8px 0; display: grid; gap: 6px; }
.pers-list li { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 6px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
#personalisation h4 { margin: 14px 0 4px; font-size: 14px; color: var(--ink); }
#personalisation select { max-width: 100%; }
details.fold > summary { list-style: none; cursor: pointer; display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; }
details.fold > summary::-webkit-details-marker { display: none; }
details.fold > summary h3 { display: inline-flex; align-items: center; gap: 6px; margin: 0; }
details.fold > summary h3::after { content: "\25BE"; font-size: 12px; color: var(--muted); }
details.fold:not([open]) > summary h3::after { content: "\25B8"; }
.signin-offer { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.signin-offer span { flex: 1 1 200px; }
.save-top { display: none; }
#huntLink, #nearLink, #doctorNav, .nav .nav-sep { display: none !important; } /* the menu before 20 Nov 2026, still in plant pages built earlier */
.actions[hidden] { display: none; }
.today-slot[hidden] { display: none !important; }
.mine-links { display: flex; flex-wrap: wrap; gap: 4px 18px; margin: -8px 0 16px; font-size: 14px; flex-basis: 100%; } .mine-links a { padding: 12px 0; }
@media (max-width: 900px) { .actions #addMine { display: none; } } /* on phones the same button already sits under the photo (.save-top) */
@media (max-width: 900px) { .save-top { display: flex; width: 100%; justify-content: center; margin: 12px 0 0; } }
.card .notforme { align-self: flex-start; width: auto; }

/* ---- The home globe, as Flight Wiki's (10 Nov 2026): the same stage, size, colours and dots on all five wikis ----
   A frameless night-blue stage beside the introduction (Flight's .globe-wrap), always in the dark set like Flight's.
   globe.js sizes the Earth to 91.5% of the stage's shorter side, as Flight's overview camera does. */
:is(.intro, .home-hero, .hero) > .globe-card {
  --bg: #0B121C; --surface: #111A27; --surface-2: #16212F; --card: #111A27; --ink: #E6ECF2; --text: #E1E8F0; --muted: #9AA6B4;
  --line: #233042; --line-2: #34445A; --rule: #233042; --rule-strong: #34445A;
  position: relative; display: flex; flex-direction: column; justify-content: flex-end; align-self: stretch; justify-self: stretch;
  width: 100%; max-width: none; min-height: min(660px, max(460px, calc(100vh - 150px))); padding: 16px; overflow: hidden;
  color: var(--text); background: radial-gradient(ellipse at center, #152038 0%, #0B121C 70%); border: 1px solid #1A2638; border-radius: 22px; box-shadow: none;
}
:is(.intro, .home-hero, .hero) > .globe-card::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 140px; z-index: 1; pointer-events: none;
  background: linear-gradient(rgba(11, 18, 28, 0), rgba(11, 18, 28, 0.88)); }
:is(.intro, .home-hero, .hero) > .globe-card > :not(.sr-only) { position: relative; z-index: 2; }
:is(.intro, .home-hero, .hero) > .globe-card > .globe { position: absolute; inset: 0; z-index: 0; width: auto; height: auto; max-width: none; aspect-ratio: auto; margin: 0; }
:is(.intro, .home-hero, .hero) > .globe-card > .globe-head { position: absolute; top: 14px; left: 18px; right: 18px; }
:is(.intro, .home-hero, .hero) > .globe-card .globe-head h2 { color: var(--ink); text-shadow: 0 1px 3px #0B121C; }
:is(.intro, .home-hero, .hero) > .globe-card .globe-cap { font-size: 12px; line-height: 1.45; min-height: 0; margin: 8px 0 0; color: var(--muted); text-shadow: 0 1px 2px #0B121C; }
/* Until the 3D library loads: Flight Wiki's still Earth, the same size as the globe that replaces it. */
:is(.intro, .home-hero, .hero) > .globe-card > .globe:empty::before { content: ""; position: absolute; inset: auto; left: 50%; top: 50%;
  width: auto; height: min(91.5%, 91.5cqw); aspect-ratio: 1; transform: translate(-50%, -50%); border-radius: 50%; pointer-events: none;
  background: radial-gradient(circle at 50% 50%, transparent 66%, rgba(110, 168, 254, 0.28) 70.5%, transparent 71%),
    radial-gradient(circle at 65% 70%, rgba(0, 0, 0, 0.45) 0%, transparent 55%),
    radial-gradient(circle at 35% 30%, #2b5c9c 0%, #17345e 38%, #0b1a33 70%, #060d1a 100%); }
:is(.intro, .home-hero, .hero) > .globe-card > .globe { container-type: size; }
@media (min-width: 861px) {
  :is(.intro, .home-hero, .hero):has(> .globe-card) { grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); }
}
/* Phones: Flight Wiki's globe band (same height and camera), the title on it, the chips and caption under it. */
@media (max-width: 860px) {
  :is(.intro, .home-hero, .hero) > .globe-card { display: block; min-height: 0; padding: 0 16px 14px; }
  :is(.intro, .home-hero, .hero) > .globe-card::after { display: none; }
  :is(.intro, .home-hero, .hero) > .globe-card > .globe { position: relative; inset: auto; width: auto; height: clamp(280px, min(92vw, 46vh), 420px); margin: 0 -16px 6px; }
  :is(.intro, .home-hero, .hero) > .globe-card > .globe-head { top: 12px; left: 16px; right: 16px; }
}

/* Identify in the header is 38px tall, the same as Share and as the header button on the other four wikis. */
@media (min-width: 761px) { header #snap { min-height: 38px; height: 38px; } }

/* Card grids are 4 across on a wide screen with a 16px gap, as on the other wikis (Fish, Coffee, Landmark). */
@media (min-width: 761px) { .grid { grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); } }

/* Phones: a short gap between a page's last item and the footer (24px, was 96px). A trip page drops the screen-tall
   filler too (signed in, not indexed), so a short trip doesn't leave an empty screen above the footer. */
@media (max-width: 900px) {
  body > main { padding-bottom: 24px; }
  .site-foot { margin-top: 0; }
  body > main:not(#mine):not([hidden]):has(.tj) { min-height: 0; }
  .intro { padding-bottom: 0; }
  .foot-in { padding-top: 24px; }
  /* My plants and Account are personal pages that start empty and fill in when drawn: once they have content they
     drop the screen-tall filler, so a short list doesn't leave an empty screen above the footer (was 592px). */
  /* The footer is kept where the finished page puts it (My plants is about 330px tall, Account longer than a screen), so
     it does not jump while the page fills in. */
  body > main#mine:not([hidden]) { min-height: 328px; }
}

/* The answer to a photo checked after the camera window was closed (Carry on, I'll tell you). */
.idf-ready { position: fixed; left: 50%; bottom: calc(84px + env(safe-area-inset-bottom)); transform: translateX(-50%); z-index: 60; display: flex; gap: 8px; align-items: center; max-width: min(92vw, 440px); padding: 10px 12px; border-radius: 14px; background: var(--card, #fff); color: var(--text, #111); border: 1px solid var(--line, #ddd); box-shadow: 0 8px 28px rgb(0 0 0 / .3); }
.idf-ready span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* Laptops and desktops: about 64px between a page's last item and the footer (was 112px). */
@media (min-width: 901px) {
  body > main { padding-bottom: 40px; }
  .site-foot { margin-top: 24px; }
}

/* Nothing spills out of its box on narrow phones or with long labels (Tamil, Malay): button and chip labels wrap
   (they were nowrap, making the page up to 549px wide), the home intro column shrinks, section "See all" links
   wrap under their heading, long words break in scenario cards and plant tags, and the trip journal's sign-in
   button drops under its text when it can't get 100px beside it. break-word only acts when a word can't fit. */
body { overflow-wrap: break-word; }
button, .btn, .upload { white-space: normal; text-align: center; max-width: 100%; line-height: 1.2; padding-top: 4px; padding-bottom: 4px; }
@media (max-width: 900px) { .intro { grid-template-columns: minmax(0, 1fr); } }
.home-sec .section-title { flex-wrap: wrap; }
.home-sec .section-title a { white-space: normal; }
.scenario > * { max-width: 100%; overflow-wrap: anywhere; }
.card .tag { max-width: 100%; overflow-wrap: anywhere; }
body .tj-hub .tj-btn { min-width: min(100%, 100px); }
/* Horizontal scroll rows keep one-line labels (they scroll instead of wrapping). */
.globe-chips button, .lenses button, .mtabs button, .hunt-filters button, .plan-cards button, .tblwrap button { white-space: nowrap; }

/* Phones: every stand-alone link and button at least 32px tall (44px for the footer lists), form fields at 16px so
   iPhones don't zoom in, and reading text at 16px (QA 17 Nov 2026). */
@media (max-width: 600px) {
  footer nav a { display: flex; align-items: center; min-height: 44px; }
  .brand { min-height: 36px; display: inline-flex; align-items: center; }
  .camsearch { min-width: 36px; min-height: 36px; }
  .chip, .tip .chip, .gallery .chip, section.txt .chip { min-height: 36px; }
  .section-title a, .near-link a { display: inline-block; padding: 7px 0; }
  input, select, textarea { font-size: 16px; }
  main p, main li, .fact, .sec-sub { font-size: 16px; }
}
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; } /* read by screen readers, not shown */

/* Phones, second pass (QA 17 Nov 2026): pickers styled by id, the globe caption and map card notes at 16px, and the
   map's own buttons at least 34px. */
@media (max-width: 600px) {
  html body :is(#sort, #langPick, #unitsPick, select) { font-size: 16px; }
  html body :is(select, select.inline-select) { min-height: 36px; }
  html body :is(#globeCap, .globe-cap, .hcard p.muted.small, .hcard p.small) { font-size: 16px; }
  html body .leaflet-touch .leaflet-bar a, html body .leaflet-bar a { width: 34px; height: 34px; line-height: 34px; }
  html body .leaflet-bar.gview a, html body .gview a { min-height: 34px; display: inline-flex; align-items: center; }
}

/* Saved-plant window: the button row wraps instead of running off the left edge of a phone. */
.dlg.saved .row { flex-wrap: wrap; justify-content: center; }
.dlg.saved .row button { flex: 1 1 auto; }
/* Supporter buy buttons under the plans table (wide screens; phones have them on the Supporter card). */
.plans-buy { margin-top: 12px; }
@media (max-width: 560px) { .plans-buy { display: none; } }

/* QA 18 Nov 2026, round 2. Phones: the main controls are 44px tall (nothing under 32px), and a sentence of small grey
   text is read at 16px like the rest. */
@media (max-width: 600px) {
  html body :is(.brand, .sharebtn, .camsearch, #q, .back, .section-title a, .near-link a) { min-height: 44px; }
  html body :is(.sharebtn, .camsearch) { min-width: 44px; }
  html body :is(.chip, .tip .chip, .gallery .chip, section.txt .chip, main button.primary, main .btn, #improve) { min-height: 44px; }
  html body :is(details.small > summary, .hide-note summary, .dash-more > summary) { display: flex; align-items: center; min-height: 44px; }
  html body :is(select, select.inline-select) { min-height: 44px; }
  html body main p.small, html body main p.muted.small { font-size: 16px; }
}
/* Reading lines stop at about 75 characters on the Account and About pages, and the filler that keeps a short page a
   screen tall is dropped on Doctor and Stats (their footer sat 285px and 393px below the last item). */
#account p, #about p, #account li, #about li { max-width: 75ch; }
@media (max-width: 900px) { body > main#doctor:not([hidden]), body > main#stats:not([hidden]) { min-height: 0; } }
/* Until the page asked for has something drawn in it, the footer is not shown at all: it used to appear under the
   header and then jump down when a short page (Doctor, Stats) was drawn, a layout shift of 0.3 to 0.5 on a phone. */
body:not(:has(> main:not([hidden]):not(:empty))) > .site-foot { display: none; }

/* PC screens: text one size bigger (owner, 18 Nov 2026, as on nightingaley.com); phones and tablets unchanged.
   Under zoom, vh grows with the page, so heights tied to the window divide by the zoom (dialogs and the hunt side panel
   would otherwise run past the bottom). The globes and 3D models keep 1x: globe.gl and model-viewer map the pointer against their unzoomed size. */
@media (min-width: 1200px) {
  html { zoom: 1.1; }
  :focus-visible { outline-width: 3px; }
  .globe, .mine-globe, model-viewer { zoom: 0.9091; }
  body { min-height: calc(100vh / 1.1); }
  body > main:not([hidden]) { min-height: calc(100vh / 1.1 - 64px); }
  .dlg { max-height: calc(100dvh / 1.1 - 40px); }
  .hunt-side { max-height: calc(100dvh / 1.1 - 100px); }
  :is(.intro, .home-hero, .hero) > .globe-card { min-height: min(660px, max(460px, calc(100vh / 1.1 - 150px))); }
}
@media (min-width: 1600px) {
  html { zoom: 1.2; }
  .globe, .mine-globe, model-viewer { zoom: 0.8333; }
  body { min-height: calc(100vh / 1.2); }
  body > main:not([hidden]) { min-height: calc(100vh / 1.2 - 64px); }
  .dlg { max-height: calc(100dvh / 1.2 - 40px); }
  .hunt-side { max-height: calc(100dvh / 1.2 - 100px); }
  :is(.intro, .home-hero, .hero) > .globe-card { min-height: min(660px, max(460px, calc(100vh / 1.2 - 150px))); }
}
/* Footer columns never wider than the screen (3 px over with larger text in Safari's engine, 19 Nov 2026). */
.foot-in > * { min-width: 0; overflow-wrap: break-word; }
@media (max-width: 360px) { .foot-in { grid-template-columns: minmax(0, 1fr); } }

/* The photo answer's buttons (#idResults) start at the left, and on a phone the main one takes the whole row with the
   others sharing the row below on one line each. Before (19 Nov 2026, an iPhone Pro Max), three buttons in one row each
   wrapped onto two lines while a photo was checked, and the food answer's two sat pushed to the right. */
#idResults .row { justify-content: flex-start; flex-wrap: wrap; }
@media (max-width: 560px) {
  #idResults .row > .primary { flex: 1 1 100%; }
  #idResults .row > button:not(.primary) { flex: 1 1 0; white-space: nowrap; }
}

/* The camera window is the shared one (wiki-camera.js, 20 Nov 2026): Plant Wiki's results sit in it as they did in the old window. */
.wc #idResults .ask-top h3 { font-size: 16px; margin: 20px 0 8px; }
.wc #idResults .result:first-child { margin-top: 0; }
