/* Midstorey
   Palette: pale eucalypt page, deep bush green, wattle gold as the single accent.
   Type: Literata for headings and scientific names, Atkinson Hyperlegible for reading. */

/* Fonts are served from this site (SIL Open Font License; see static/fonts/), so
   visitors' browsers don't contact Google Fonts. */
@font-face { font-family: "Atkinson Hyperlegible"; font-style: normal; font-weight: 400; font-display: swap;
  src: url("../fonts/atkinson-hyperlegible-latin-400-normal.f1f8a8210104.woff2") format("woff2"); }
@font-face { font-family: "Atkinson Hyperlegible"; font-style: italic; font-weight: 400; font-display: swap;
  src: url("../fonts/atkinson-hyperlegible-latin-400-italic.de4c0c22fd4e.woff2") format("woff2"); }
@font-face { font-family: "Atkinson Hyperlegible"; font-style: normal; font-weight: 700; font-display: swap;
  src: url("../fonts/atkinson-hyperlegible-latin-700-normal.13a58e05dfd2.woff2") format("woff2"); }
@font-face { font-family: "Literata"; font-style: normal; font-weight: 200 900; font-display: swap;
  src: url("../fonts/literata-latin-opsz-normal.c0473b84f21c.woff2") format("woff2-variations"), url("../fonts/literata-latin-opsz-normal.c0473b84f21c.woff2") format("woff2"); }
@font-face { font-family: "Literata"; font-style: italic; font-weight: 200 900; font-display: swap;
  src: url("../fonts/literata-latin-opsz-italic.b62406718c0e.woff2") format("woff2-variations"), url("../fonts/literata-latin-opsz-italic.b62406718c0e.woff2") format("woff2"); }

:root {
  --gum-leaf: #e8eee7;     /* page */
  --paper: #fafcf8;        /* panels */
  --bark: #23241e;         /* text */
  --lichen: #5f6a5a;       /* secondary text */
  --bush: #23493b;         /* links, buttons */
  --bush-soft: #d6e3d9;
  --rule: #c9d4c8;
  --wattle: #e2b12f;       /* accent: focus, current month */
  --ochre: #9a4724;        /* warnings */
  --ochre-soft: #f6e6dc;

  --serif: "Literata", Georgia, "Times New Roman", serif;
  --sans: "Atkinson Hyperlegible", system-ui, -apple-system, "Segoe UI", sans-serif;

  --step--1: 0.875rem;
  --step-0: 1.0625rem;
  --step-1: 1.25rem;
  --step-2: 1.5625rem;
  --step-3: 2rem;
  --step-4: clamp(2.25rem, 1.6rem + 3vw, 3.5rem);

  --radius: 6px;
  --space: 1.5rem;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --gum-leaf: #161b17;
    --paper: #1e2520;
    --bark: #e7ece4;
    --lichen: #a3ae9e;
    --bush: #9fcfb6;
    --bush-soft: #2a3a31;
    --rule: #334037;
    --ochre: #e7a07c;
    --ochre-soft: #3a2a21;
    color-scheme: dark;
  }
}

*, *::before, *::after { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--gum-leaf);
  color: var(--bark);
  font: var(--step-0)/1.55 var(--sans);
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--bush); text-underline-offset: 0.18em; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }

:focus-visible { outline: 3px solid var(--wattle); outline-offset: 2px; border-radius: 2px; }

h1, h2, h3 { font-family: var(--serif); font-weight: 600; line-height: 1.15; margin: 0 0 0.5em; }
h2 { font-size: var(--step-2); margin-top: 1.75em; }

.wrap { width: min(72rem, 100% - 2.5rem); margin-inline: auto; }

.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}

.skip-link { position: absolute; left: -999px; }
.skip-link:focus { left: 1rem; top: 1rem; background: var(--paper); padding: 0.5rem 1rem; z-index: 10; }

.muted { color: var(--lichen); }
.sci { font-family: var(--serif); }
.sci i { font-style: italic; }

/* --- Header and footer ------------------------------------------------- */

.site-header { border-bottom: 1px solid var(--rule); background: var(--paper); }
.site-header__inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding-block: 0.9rem; }
.site-name { display: inline-flex; align-items: center; gap: 0.5rem; font-family: var(--serif); font-size: var(--step-2);
  font-weight: 600; letter-spacing: -0.01em; color: var(--bark); text-decoration: none; }
.site-name__mark { width: 1.9rem; height: 1.9rem; flex: none; }
.mark-canopy { fill: var(--bush); }
.mark-mid { fill: var(--wattle); }
.mark-ground { fill: #8a6a45; }
.site-header nav { display: flex; gap: 1.25rem; }
.site-header nav a { color: var(--bark); text-decoration: none; }
.site-header nav a[aria-current="page"], .site-header nav a:hover { color: var(--bush); text-decoration: underline; }

main { padding-block: 2rem 4rem; }

.site-footer { border-top: 1px solid var(--rule); color: var(--lichen); font-size: var(--step--1); padding-block: 1.5rem; }
.site-footer p { margin: 0.25rem 0; max-width: 65ch; }

/* --- Controls ---------------------------------------------------------- */

.button {
  font: inherit; font-weight: 700; cursor: pointer;
  background: var(--bush); color: var(--paper);
  border: 0; border-radius: var(--radius); padding: 0.7rem 1.2rem;
}
.button:hover { filter: brightness(1.1); }
.button--small { padding: 0.35rem 0.8rem; font-size: var(--step--1); }

input[type="search"], select {
  font: inherit; color: var(--bark); background: var(--paper);
  border: 1px solid var(--rule); border-radius: var(--radius); padding: 0.65rem 0.8rem;
}
input[type="search"] { width: 100%; }
select { width: 100%; padding-block: 0.5rem; }
input[type="checkbox"] { accent-color: var(--bush); width: 1.05rem; height: 1.05rem; margin: 0; }

.tag {
  display: inline-block; font-size: var(--step--1); line-height: 1.3;
  padding: 0.1rem 0.5rem; border-radius: 99px; background: var(--bush-soft); color: var(--bark); margin: 0;
}
.tag--warning { background: var(--ochre-soft); color: var(--ochre); }

/* --- Home -------------------------------------------------------------- */

.hero { padding-block: 2.5rem 2.5rem; display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr); gap: 2.5rem; align-items: center; }
.hero h1 { font-size: var(--step-3); font-weight: 500; letter-spacing: -0.01em; line-height: 1.15; }
.hero__sub { font-size: var(--step-1); color: var(--lichen); max-width: 38rem; }
.hero__search { display: flex; gap: 0.5rem; margin-block: 1.5rem 1rem; }
.hero__search input { font-size: var(--step-1); padding: 0.85rem 1rem; }
.hero__shortcuts { color: var(--lichen); }

.in-flower h2 { margin-top: 0; }

/* --- Browse ------------------------------------------------------------ */

.page-title { font-size: var(--step-3); }

.browse { display: grid; grid-template-columns: 15rem 1fr; gap: 1rem 2.5rem; align-items: start; }
.browse__form { display: contents; }
.browse__search { grid-column: 1 / -1; display: flex; gap: 0.5rem; max-width: 40rem; }

.filters > summary { font-weight: 700; cursor: pointer; padding-block: 0.4rem; }
.filters[open] > summary { margin-bottom: 0.5rem; }
.filter { border: 0; padding: 0; margin: 0 0 1.25rem; }
.filter legend, .filter__label { font-weight: 700; font-size: var(--step--1); margin-bottom: 0.35rem; display: block; padding: 0; }
.check { display: flex; align-items: center; gap: 0.5rem; padding-block: 0.15rem; cursor: pointer; }
.filter--month { display: grid; grid-template-columns: 1fr 1fr; column-gap: 0.75rem; }
.filter--month legend { grid-column: 1 / -1; }
.filter--state { display: grid; grid-template-columns: 1fr; }
.filter--toggle { margin-bottom: 0.5rem; }
.filters__more { border-top: 1px solid var(--rule); padding-top: 0.75rem; }
.filters__more > summary { font-weight: 700; cursor: pointer; margin-bottom: 0.75rem; color: var(--bush); }

.results.htmx-request { opacity: 0.55; transition: opacity 0.15s; }
.results__header { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; margin-bottom: 0.25rem; }
.results__count { margin: 0; color: var(--lichen); }

.empty { padding: 2rem 0; }

.pagination { display: flex; gap: 1.5rem; align-items: center; margin-top: 1.5rem; }

@media (max-width: 52rem) {
  .browse { grid-template-columns: 1fr; }
  .filters { border: 1px solid var(--rule); border-radius: var(--radius); padding: 0.4rem 0.9rem; background: var(--paper); }
}

/* --- Plant rows (results, home, cultivars) ------------------------------ */

.plant-list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--rule); }

.plant-row {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) auto;
  grid-template-areas: "link facts cal" "link tag cal";
  gap: 0.25rem 1.5rem; align-items: center;
  padding-block: 0.9rem; border-bottom: 1px solid var(--rule);
}
.plant-row__link { grid-area: link; display: flex; align-items: center; gap: 1rem; text-decoration: none; color: inherit; }
.plant-row__link:hover .plant-row__common { text-decoration: underline; }
.plant-row__thumb { width: 72px; height: 72px; border-radius: var(--radius); object-fit: cover; flex: none; }
.plant-row__thumb--empty {
  display: grid; place-items: center; background: var(--bush-soft); color: var(--bush);
  font: italic 600 2rem/1 var(--serif);
}
.plant-row__names { display: flex; flex-direction: column; min-width: 0; }
.plant-row__common { font-weight: 700; color: var(--bush); font-size: var(--step-1); line-height: 1.25; }
.plant-row__names .sci { color: var(--lichen); }
.plant-row__facts { grid-area: facts; margin: 0; font-size: var(--step--1); color: var(--lichen); }
.plant-row .tag { grid-area: tag; justify-self: start; }
.plant-row__calendar { grid-area: cal; }

@media (max-width: 40rem) {
  .plant-row {
    grid-template-columns: 1fr;
    grid-template-areas: "link" "facts" "cal" "tag";
  }
  .plant-row__facts, .plant-row__calendar, .plant-row .tag { margin-left: calc(72px + 1rem); }
}

/* --- Flowering calendar ------------------------------------------------- */

.calendar { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(12, 1fr); gap: 3px; }
.calendar__month {
  position: relative; aspect-ratio: 1 / 1.25; min-width: 0;
  border-radius: 3px; background: var(--bush-soft);
  display: grid; place-items: end center; padding-bottom: 0.25em;
  font-size: var(--step--1); color: var(--lichen);
}
.calendar__month.is-on { background: var(--flower); color: var(--ink); box-shadow: inset 0 0 0 1px rgb(0 0 0 / 0.12); }
.calendar__month.is-light { box-shadow: inset 0 0 0 1.5px var(--lichen); }
.calendar__month.is-now { outline: 3px solid var(--wattle); outline-offset: 1px; }
.calendar__month.is-now::after {
  content: "Now"; position: absolute; top: calc(100% + 6px); font-size: 0.75rem; color: var(--bark); font-weight: 700;
}

.calendar--compact { grid-template-columns: repeat(12, 0.8rem); gap: 2px; }
.calendar--compact .calendar__month { aspect-ratio: 1 / 1.6; border-radius: 2px; padding: 0; }
.calendar--compact .calendar__label { display: none; }

/* --- Plant page --------------------------------------------------------- */

.crumbs { font-size: var(--step--1); color: var(--lichen); margin: 0 0 1.25rem; }
.plant__header { margin-bottom: 2rem; }
.plant__header h1 { display: flex; flex-direction: column; gap: 0.35rem; margin-bottom: 0.75rem; }
.plant__common { font: 700 var(--step-1)/1.2 var(--sans); color: var(--bush); }
.plant__sci { font-size: var(--step-4); font-weight: 500; letter-spacing: -0.01em; line-height: 1.05; }
.plant__header p { margin: 0.2rem 0; }
.plant__header .crumbs { margin-bottom: 1.5rem; }

.warning {
  background: var(--ochre-soft); border-left: 4px solid var(--ochre);
  border-radius: 0 var(--radius) var(--radius) 0; padding: 1rem 1.25rem; margin-bottom: 2rem; max-width: 46rem;
}
.warning h2 { font-size: var(--step-1); color: var(--ochre); margin: 0 0 0.35rem; }
.warning p { margin: 0; }

.plant__flowering { margin-bottom: 3rem; }
.plant__flowering h2 { font-size: var(--step-1); margin-top: 0; }
.plant__flowering .calendar { max-width: 46rem; gap: 5px; }
.plant__flowering .calendar__month { font-size: var(--step-0); font-weight: 700; }

/* --- Plant page sections --------------------------------------------------- */

.plant-section { margin-top: 2.5rem; }
.plant-section > h2 { margin-top: 0; padding-top: 1.5rem; border-top: 1px solid var(--rule); }
.plant-section--warning > h2 { color: var(--ochre); }
.plant-section__notes { display: grid; grid-template-columns: repeat(auto-fit, minmax(18rem, 1fr)); gap: 0 2.5rem; }
.plant-section__note { margin-top: 1rem; max-width: 40rem; }
.plant-section__note h3 { font: 700 var(--step-0)/1.3 var(--sans); margin: 0 0 0.25rem; }
.plant-section__note p { margin: 0 0 0.6rem; }

.tags { list-style: none; padding: 0; margin: 0 0 1rem; display: flex; flex-wrap: wrap; gap: 0.4rem; }
.tags .tag { font-size: var(--step-0); padding: 0.2rem 0.7rem; }

.lede { font-family: var(--serif); font-size: var(--step-1); line-height: 1.5; margin-top: 0; }
/* --- Photo carousel ------------------------------------------------------ */

.gallery { margin: 0 0 2rem; }
.gallery__track {
  position: relative; display: flex; overflow-x: auto; scroll-snap-type: x mandatory;
  scrollbar-width: none; border-radius: var(--radius); background: var(--bush-soft);
}
.gallery__track::-webkit-scrollbar { display: none; }
.gallery__slide { flex: 0 0 100%; margin: 0; scroll-snap-align: start; }
.gallery__slide img { width: 100%; aspect-ratio: 16 / 10; max-height: 24rem; object-fit: contain; }
.gallery__slide figcaption { font-size: var(--step--1); color: var(--lichen); padding: 0.5rem 0.75rem; background: var(--gum-leaf); }

.gallery__bar { display: flex; align-items: center; justify-content: center; gap: 1rem; margin-top: 0.5rem; }
.gallery__count { margin: 0; min-width: 4.5rem; text-align: center; color: var(--lichen); font-size: var(--step--1); }
.gallery__nav {
  font: 600 1.6rem/1 var(--serif); width: 2.5rem; height: 2.5rem; border-radius: 50%; cursor: pointer;
  border: 1px solid var(--rule); background: var(--paper); color: var(--bush);
}
.gallery__nav:hover { background: var(--bush-soft); }

.gallery__thumbs { display: flex; gap: 0.5rem; overflow-x: auto; margin-top: 0.6rem; padding: 3px; }
.gallery__thumb { flex: none; padding: 0; border: 0; border-radius: 4px; cursor: pointer; background: none; opacity: 0.65; }
.gallery__thumb img { width: 4rem; height: 4rem; object-fit: cover; border-radius: 4px; }
.gallery__thumb[aria-current="true"] { opacity: 1; outline: 3px solid var(--wattle); outline-offset: 1px; }
.gallery__thumb:hover { opacity: 1; }

.facts { margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(13rem, 1fr)); gap: 1rem 1.5rem; }
.facts div { border-top: 1px solid var(--rule); padding-top: 0.5rem; }
.facts dt { font-size: var(--step--1); color: var(--lichen); }
.facts dd { margin: 0.1rem 0 0; font-weight: 700; }
.facts .is-long { grid-column: 1 / -1; }
.facts .is-long dd { font-weight: 400; max-width: 46rem; }


/* --- Intro: photos and description on the left, "at a glance" on the right ---
   Phones stack in source order: photos, description, frame. */

.plant__intro {
  display: grid; gap: 1.75rem 3rem; align-items: start; justify-content: start;
  grid-template-columns: minmax(0, 40rem) minmax(15rem, 19rem);
  grid-template-areas: "text glance";
}
.plant__intro--with-photos { grid-template-areas: "photos glance" "text glance"; }
.plant__intro .gallery { grid-area: photos; margin: 0; }
.plant__intro .glance { grid-area: glance; }
.plant__overview { grid-area: text; }
.plant__overview > p:first-child { margin-top: 0; }

@media (max-width: 52rem) {
  .plant__intro, .plant__intro--with-photos {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas: "text" "glance";
  }
  .plant__intro--with-photos { grid-template-areas: "photos" "text" "glance"; }
}

.glance { grid-area: glance; }
.plant__overview { grid-area: text; max-width: 42rem; }
.plant__overview > p:first-child { margin-top: 0; }

.glance { background: var(--paper); border: 1px solid var(--rule); border-radius: var(--radius); padding: 1rem 1.1rem; }
.glance__title { font-size: var(--step-1); margin: 0 0 0.5rem; }
.glance__facts { margin: 0; }
.glance__facts div { padding-block: 0.5rem; border-top: 1px solid var(--rule); }
.glance__facts dt { font-size: var(--step--1); color: var(--lichen); }
.glance__facts dd { margin: 0.05rem 0 0; font-weight: 700; line-height: 1.35; }
.glance__buy { margin: 0.5rem 0 0; padding-top: 0.75rem; border-top: 1px solid var(--rule); font-size: var(--step--1); }
.glance__buy a { font-weight: 700; display: inline-block; margin-top: 0.15rem; }

/* --- Where to buy --------------------------------------------------------- */

.buy__header { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 0.75rem 2rem;
  padding-top: 1.5rem; border-top: 1px solid var(--rule); margin-bottom: 0.75rem; }
.buy__header h2 { margin: 0; padding: 0; border: 0; }
.buy.plant-section > .buy__header h2 { border-top: 0; }
.buy__state { display: flex; align-items: center; gap: 0.6rem; }
.buy__state label { font-size: var(--step--1); font-weight: 700; white-space: nowrap; }
.buy__state select { width: auto; min-width: 12rem; }
.buy__availability { margin: 0 0 1rem; color: var(--lichen); }
.buy__list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(19rem, 1fr)); gap: 0.75rem; }
.listing {
  background: var(--paper); border: 1px solid var(--rule); border-radius: var(--radius); padding: 0.9rem 1rem;
  display: grid; grid-template-columns: 1fr auto; gap: 0.2rem 0.75rem; align-items: baseline;
}
.listing__link { font-weight: 700; }
.listing__price { font-weight: 700; font-size: var(--step-1); }
.listing__detail { grid-column: 1 / -1; color: var(--lichen); font-size: var(--step--1); }
.listing .tag { grid-column: 1 / -1; justify-self: start; margin-top: 0.3rem; }
.buy__elsewhere { margin-top: 1rem; }
.buy__elsewhere summary { cursor: pointer; color: var(--lichen); margin-bottom: 0.75rem; }
.buy__note { font-size: var(--step--1); color: var(--lichen); margin: 1rem 0 0; }

.refs { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.5rem; }

.prose { max-width: 40rem; }

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; }
}

/* --- Header account links -------------------------------------------------- */

.site-header nav { align-items: center; flex-wrap: wrap; }
.nav-form { display: inline; margin: 0; }
.link-button { font: inherit; color: var(--bush); background: none; border: 0; padding: 0; cursor: pointer; text-decoration: underline; text-underline-offset: 0.18em; }
.site-header .link-button { color: var(--bark); text-decoration: none; }
.site-header .link-button:hover { color: var(--bush); text-decoration: underline; }
.site-header nav a.nav-cta { background: var(--bush); color: var(--paper); padding: 0.35rem 0.8rem; border-radius: var(--radius); text-decoration: none; }
.site-header nav a.nav-cta:hover { filter: brightness(1.1); color: var(--paper); }

/* --- Mobile menu ------------------------------------------------------------ */
/* nav.js unhides the toggle and marks the header; without it the links just wrap. */

.nav-toggle { display: none; }

@media (max-width: 48rem) {
  .site-header--menu .site-header__inner { flex-wrap: wrap; }
  .site-header--menu .nav-toggle[hidden] { display: none; }
  .site-header--menu .nav-toggle {
    display: inline-flex; align-items: center; gap: 0.45rem;
    font: inherit; font-weight: 700; color: var(--bark); background: none; cursor: pointer;
    border: 1px solid var(--rule); border-radius: var(--radius); padding: 0.45rem 0.75rem;
  }
  .site-header--menu .nav-toggle:hover { border-color: var(--bush); color: var(--bush); }
  .nav-toggle__icon { width: 1.25rem; height: 1.25rem; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
  .nav-toggle__close, .nav-toggle[aria-expanded="true"] .nav-toggle__bars { display: none; }
  .nav-toggle[aria-expanded="true"] .nav-toggle__close { display: inline; }

  .site-header--menu nav { display: none; }
  .site-header--menu nav.is-open {
    display: flex; flex-direction: column; align-items: stretch; gap: 0;
    flex-basis: 100%; border-top: 1px solid var(--rule); padding-top: 0.5rem;
  }
  .site-header--menu nav.is-open > a,
  .site-header--menu nav.is-open .link-button { display: block; width: 100%; text-align: left; padding: 0.7rem 0.25rem; }
  .site-header--menu nav.is-open > a + a,
  .site-header--menu nav.is-open > .nav-form { border-top: 1px solid var(--rule); }
  .site-header--menu nav.is-open .nav-form { display: block; }
  .site-header--menu nav.is-open a.nav-cta { margin-top: 0.5rem; padding: 0.7rem 0.8rem; text-align: center; border-top: 0; }
}

/* --- Messages --------------------------------------------------------------- */

.messages { list-style: none; padding: 0; margin: 0 0 1.5rem; display: grid; gap: 0.5rem; }
.message, .notice { margin: 0; padding: 0.7rem 1rem; border-radius: var(--radius); background: var(--bush-soft); border-left: 4px solid var(--bush); }
.message--warning, .message--error, .notice { background: var(--ochre-soft); border-left-color: var(--ochre); }
.notice { margin-bottom: 1.5rem; }

/* --- Forms -------------------------------------------------------------------- */

.auth { max-width: 30rem; }
.auth--wide { max-width: 40rem; }
.form { display: grid; gap: 1rem; margin-bottom: 1.5rem; }
.field { display: grid; gap: 0.3rem; }
.field > label, .field legend { font-weight: 700; }
.field fieldset { border: 0; padding: 0; margin: 0; display: grid; gap: 0.35rem; }
.field input[type="text"], .field input[type="email"], .field input[type="password"], .field input[type="number"], .field textarea,
.inline-create input, .add-to-list input, .share-box input, .list-item__edit input {
  font: inherit; color: var(--bark); background: var(--paper);
  border: 1px solid var(--rule); border-radius: var(--radius); padding: 0.6rem 0.75rem; width: 100%;
}
.field--error input { border-color: var(--ochre); }
.field__help { margin: 0; font-size: var(--step--1); color: var(--lichen); }
.field__error { margin: 0; font-size: var(--step--1); color: var(--ochre); font-weight: 700; }
.form-errors { background: var(--ochre-soft); color: var(--ochre); border-radius: var(--radius); padding: 0.6rem 1rem; font-weight: 700; }
.form-errors p { margin: 0; }
.choice { display: flex; gap: 0.5rem; align-items: center; cursor: pointer; }
.form-row { display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; }
.honeypot { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.panel-block { padding-block: 1.25rem; border-top: 1px solid var(--rule); }
.panel-block h2 { font-size: var(--step-1); margin: 0 0 0.75rem; }
.button--secondary { background: var(--paper); color: var(--bush); border: 1px solid var(--bush); }
.button--secondary:hover { background: var(--bush-soft); filter: none; }
.button--danger { background: var(--ochre); }
a.button { display: inline-block; text-decoration: none; }
.danger-link { color: var(--ochre); }
.tag--accent { background: var(--wattle); color: var(--bark); }

/* --- My lists -------------------------------------------------------------- */

.lists-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: end; gap: 1rem; margin-bottom: 1.5rem; }
.lists-head .page-title { margin: 0; }
.inline-create { display: flex; gap: 0.5rem; flex: 1 1 22rem; max-width: 30rem; }
.list-cards { list-style: none; padding: 0; margin: 0 0 2rem; display: grid; grid-template-columns: repeat(auto-fill, minmax(16rem, 1fr)); gap: 1rem; }
.list-card { background: var(--paper); border: 1px solid var(--rule); border-radius: var(--radius); padding: 1rem 1.1rem; }
.list-card__title { font: 600 var(--step-1)/1.25 var(--serif); }
.list-card p { margin: 0.35rem 0 0; }

/* --- A list ------------------------------------------------------------------ */

.list-header { margin-bottom: 1.5rem; }
.list-header__desc { max-width: 42rem; }
.list-actions { display: flex; flex-wrap: wrap; gap: 0.6rem; margin: 1rem 0; }
.list-actions form { margin: 0; }
.share-box { max-width: 40rem; margin: 1rem 0; }
.share-box label { font-weight: 700; font-size: var(--step--1); }
.share-box__row { display: flex; gap: 0.5rem; margin-top: 0.3rem; }
.list-settings { max-width: 40rem; border: 1px solid var(--rule); border-radius: var(--radius); background: var(--paper); padding: 0.6rem 1rem; }
.list-settings summary { cursor: pointer; font-weight: 700; color: var(--bush); }
.list-settings .form { margin: 1rem 0 0.5rem; }

.list-items { list-style: none; padding: 0; margin: 0 0 2.5rem; border-top: 1px solid var(--rule); }
.list-item { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr) auto; gap: 0.5rem 1.25rem; align-items: center;
  padding-block: 0.75rem; border-bottom: 1px solid var(--rule); }
.list-item__plant { display: flex; gap: 0.9rem; align-items: center; text-decoration: none; color: inherit; min-width: 0; }
.list-item__plant > span { display: flex; flex-direction: column; min-width: 0; }
.list-item__plant:hover .list-item__common { text-decoration: underline; }
.list-item__thumb { width: 56px; height: 56px; border-radius: var(--radius); object-fit: cover; flex: none; }
.list-item__thumb--empty { display: grid; place-items: center; background: var(--bush-soft); color: var(--bush); font: italic 600 1.5rem/1 var(--serif); }
.list-item__common { font-weight: 700; color: var(--bush); }
.list-item__facts { font-size: var(--step--1); color: var(--lichen); }
.list-item__edit { display: grid; grid-template-columns: 5rem 1fr; gap: 0.5rem; margin: 0; }
.list-item__edit input { padding: 0.4rem 0.6rem; }
.list-item__edit .field__error { grid-column: 1 / -1; }
.list-item__remove { margin: 0; }
.list-item__remove .link-button { color: var(--lichen); font-size: var(--step--1); }
.list-item.htmx-request { opacity: 0.6; }
@media (max-width: 44rem) {
  .list-item { grid-template-columns: 1fr auto; }
  .list-item__edit { grid-column: 1 / -1; grid-row: 2; }
}

/* --- Buying guide ----------------------------------------------------------- */

.buying-guide { margin-top: 1rem; }
.buying-guide.htmx-request { opacity: 0.6; }
.buy-plan { background: var(--paper); border: 1px solid var(--rule); border-left: 4px solid var(--wattle);
  border-radius: 0 var(--radius) var(--radius) 0; padding: 0.9rem 1.2rem; margin: 0 0 1.5rem; max-width: 46rem; }
.buy-plan h3 { font-size: var(--step-1); margin: 0 0 0.5rem; }
.buy-plan ol { margin: 0; padding-left: 1.3rem; display: grid; gap: 0.3rem; }
.buy-subhead { font-size: var(--step-0); font-family: var(--sans); margin: 0 0 0.75rem; }
.offer { background: var(--paper); border: 1px solid var(--rule); border-radius: var(--radius); padding: 0.9rem 1rem; }
.offer--elsewhere { opacity: 0.7; }
.offer__head { display: flex; justify-content: space-between; gap: 0.75rem; align-items: baseline; }
.offer details { margin-top: 0.4rem; }
.offer summary { cursor: pointer; color: var(--bush); font-size: var(--step--1); }
.offer__lines { list-style: none; padding: 0; margin: 0.5rem 0 0; display: grid; gap: 0.35rem; font-size: var(--step--1); }

/* --- Add to list (plant page and result rows) ------------------------------- */

.add-to-list { margin-top: 0.75rem; padding-top: 0.75rem; border-top: 1px solid var(--rule); font-size: var(--step--1); }
.add-to-list__label { display: block; font-weight: 700; margin: 0 0 0.35rem; }
.add-to-list p.add-to-list__label { font-weight: 400; }
.add-to-list__row { display: flex; gap: 0.4rem; }
.add-to-list select { flex: 1; min-width: 0; padding: 0.4rem; }
.add-to-list input[type="number"] { width: 4rem; flex: none; padding: 0.4rem; }
.add-to-list input[type="text"] { padding: 0.4rem 0.6rem; }
.add-to-list__new { margin-top: 0.6rem; }
.add-to-list__new summary { cursor: pointer; color: var(--bush); margin-bottom: 0.4rem; }
.add-to-list__done { font-weight: 700; color: var(--bush); margin: 0 0 0.3rem; }
.add-to-list p { margin: 0; }

.plant-row { grid-template-areas: "link facts cal" "link tag add"; }
.row-add { grid-area: add; justify-self: end; position: relative; }
.row-add__menu > summary { list-style: none; cursor: pointer; }
.row-add__menu > summary::-webkit-details-marker { display: none; }
.row-add__panel { position: absolute; right: 0; top: calc(100% + 4px); z-index: 5; min-width: 13rem; max-height: 16rem; overflow-y: auto;
  background: var(--paper); border: 1px solid var(--rule); border-radius: var(--radius); box-shadow: 0 6px 18px rgb(0 0 0 / 0.12); padding: 0.3rem; }
.row-add__panel form { margin: 0; }
.row-add__option { display: block; width: 100%; text-align: left; font: inherit; font-size: var(--step--1); color: var(--bark);
  background: none; border: 0; border-radius: 4px; padding: 0.45rem 0.6rem; cursor: pointer; text-decoration: none; }
.row-add__option:hover, .row-add__option:focus-visible { background: var(--bush-soft); }
.row-add__option--new { color: var(--bush); border-top: 1px solid var(--rule); border-radius: 0; margin-top: 0.2rem; }
.row-add__done { font-size: var(--step--1); font-weight: 700; }
@media (max-width: 40rem) {
  .plant-row { grid-template-areas: "link" "facts" "cal" "tag" "add"; }
  .row-add { justify-self: start; margin-left: calc(72px + 1rem); }
  .row-add__panel { left: 0; right: auto; }
}

.list-item__print { display: none; }

/* --- Print -------------------------------------------------------------------- */

@media print {
  .site-header, .site-footer, .no-print, .messages, .notice, .row-add, .offer details summary { display: none !important; }
  body { background: #fff; color: #000; font-size: 11pt; }
  main { padding: 0; }
  .wrap { width: 100%; }
  .list-item { grid-template-columns: 1fr auto; break-inside: avoid; }
  .list-item__edit, .list-item__remove { display: none; }
  .list-item__print { display: block; margin: 0; font-weight: 700; }
  .list-item__thumb { display: none; }
  .offer, .buy-plan { border: 1px solid #999; break-inside: avoid; }
  .offer details > * { display: block !important; }
  a { color: #000; text-decoration: none; }
}

/* --- Contributions and moderation ----------------------------------------- */

.badge { display: inline-block; min-width: 1.4em; padding: 0 0.4em; border-radius: 99px; background: var(--wattle);
  color: var(--bark); font-size: 0.8em; font-weight: 700; text-align: center; }
.improve p { max-width: 46rem; }
.improve__links { display: flex; flex-wrap: wrap; gap: 0.6rem; align-items: center; }
.contribute { max-width: 52rem; }
.change-form { gap: 0.75rem; }
.change-group { border: 1px solid var(--rule); border-radius: var(--radius); background: var(--paper); padding: 0.6rem 1rem; }
.change-group > summary { cursor: pointer; font: 600 var(--step-1)/1.3 var(--serif); }
.change-group__fields { display: grid; grid-template-columns: repeat(auto-fill, minmax(20rem, 1fr)); gap: 1rem 1.5rem; padding: 0.9rem 0 0.4rem; }
.change-group__fields select { width: 100%; }
.field--checks .checks { display: flex; flex-wrap: wrap; gap: 0.25rem 1rem; }
.field--checks { border: 0; padding: 0; margin: 0; }
.field--checks legend { font-weight: 700; padding: 0; margin-bottom: 0.3rem; }
.choice--top { align-items: flex-start; }
.choice--top input { margin-top: 0.3rem; flex: none; }

.contrib-list { list-style: none; padding: 0; margin: 0 0 2rem; border-top: 1px solid var(--rule); }
.contrib { display: flex; flex-wrap: wrap; align-items: center; gap: 0.3rem 1rem; padding-block: 0.75rem; border-bottom: 1px solid var(--rule); }
.contrib__main { flex: 1 1 20rem; display: flex; flex-direction: column; }
.contrib__note { flex-basis: 100%; margin: 0; font-size: var(--step--1); }
.contrib__action { margin: 0; }
.status { font-size: var(--step--1); font-weight: 700; padding: 0.1rem 0.6rem; border-radius: 99px; background: var(--bush-soft); white-space: nowrap; }
.status--approved { background: #d4ead9; color: #1f5135; }
.status--rejected { background: var(--ochre-soft); color: var(--ochre); }
.status--pending { background: #f6eccb; color: #6b5300; }

.mod-layout { display: grid; grid-template-columns: minmax(0, 1fr) 17rem; gap: 2rem; align-items: start; }
.mod-author { background: var(--paper); border: 1px solid var(--rule); border-radius: var(--radius); padding: 1rem; font-size: var(--step--1); }
.mod-author h2 { font-size: var(--step-1); margin: 0 0 0.5rem; }
.mod-author p { margin: 0 0 0.5rem; }
.mod-comment { margin: 0 0 1rem; padding: 0.7rem 1rem; background: var(--paper); border-left: 4px solid var(--rule); }
.mod-actions { margin-top: 1rem; }
.mod-photo { max-height: 32rem; border-radius: var(--radius); margin-bottom: 1rem; background: var(--bush-soft); }
.table-scroll { overflow-x: auto; }
.diff { width: 100%; border-collapse: collapse; margin-bottom: 1rem; font-size: var(--step--1); }
.diff th, .diff td { text-align: left; vertical-align: top; padding: 0.55rem 0.6rem; border-bottom: 1px solid var(--rule); }
.diff thead th { font-weight: 700; color: var(--lichen); }
.diff tbody th { font-weight: 700; white-space: nowrap; }
.diff__old { color: var(--lichen); text-decoration: line-through; text-decoration-color: rgb(0 0 0 / 0.25); }
.diff__new { background: #e3f1e6; }
.diff__stale { background: var(--ochre-soft); }
.diff__warn { margin: 0.3rem 0 0; color: var(--ochre); text-decoration: none; display: block; }
.photo-queue { list-style: none; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(12rem, 1fr)); gap: 1rem; }
.photo-queue img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: var(--radius); }
.photo-queue p { margin: 0.4rem 0 0; font-size: var(--step--1); }
.history { list-style: none; padding: 0; border-top: 1px solid var(--rule); }
.history__entry { padding-block: 0.8rem; border-bottom: 1px solid var(--rule); }
.history__entry p { margin: 0.15rem 0; }
.inline-form { display: inline; margin-left: 0.75rem; }
@media (max-width: 52rem) { .mod-layout { grid-template-columns: 1fr; } }
.results__suggest { margin-top: 1rem; color: var(--lichen); }

/* --- Native to my area ------------------------------------------------------- */

.browse__local { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; max-width: 40rem; }
.browse__local label { font-weight: 700; font-size: var(--step--1); }
.browse__local input { width: 7rem; font: inherit; padding: 0.45rem 0.7rem; border: 1px solid var(--rule); border-radius: var(--radius); background: var(--paper); }
.browse__local select { width: auto; }
.browse__local-clear { font-size: var(--step--1); }
.local-note { background: var(--paper); border: 1px solid var(--rule); border-left: 4px solid var(--bush);
  border-radius: 0 var(--radius) var(--radius) 0; padding: 0.75rem 1rem; margin: 0 0 1rem; }
.local-note__source { display: block; font-size: var(--step--1); color: var(--lichen); margin-top: 0.3rem; }
.tag--local { background: #d4ead9; color: #1f5135; }
.hero__local { margin: 0 0 1rem; }
.hero__local label { font-weight: 700; display: block; margin-bottom: 0.35rem; }
.hero__local-row { display: flex; gap: 0.5rem; }
.hero__local input { width: 9rem; font: inherit; padding: 0.6rem 0.8rem; border: 1px solid var(--rule); border-radius: var(--radius); background: var(--paper); }

/* --- Nursery portal -------------------------------------------------------------- */

.portal { display: grid; grid-template-columns: 12rem minmax(0, 1fr); gap: 2rem; align-items: start; }
.portal__nav { display: flex; flex-direction: column; gap: 0.15rem; position: sticky; top: 1rem; }
.portal__name { font: 600 var(--step-1)/1.25 var(--serif); margin: 0 0 0.75rem; }
.portal__nav a { padding: 0.4rem 0.6rem; border-radius: var(--radius); text-decoration: none; color: var(--bark); }
.portal__nav a:hover { background: var(--bush-soft); }
.portal__nav a[aria-current="page"] { background: var(--bush); color: var(--paper); }
@media (max-width: 52rem) {
  .portal { grid-template-columns: 1fr; }
  .portal__nav { position: static; flex-direction: row; flex-wrap: wrap; }
  .portal__name { flex-basis: 100%; }
}
.portal-actions { display: flex; flex-wrap: wrap; gap: 0.5rem 1rem; align-items: center; margin: 0; }
.portal-actions a[aria-current="page"] { font-weight: 700; text-decoration: none; color: var(--bark); }
.stat-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(12rem, 1fr)); gap: 1rem; margin-bottom: 1.5rem; }
.stat { display: block; background: var(--paper); border: 1px solid var(--rule); border-radius: var(--radius); padding: 1rem 1.1rem; text-decoration: none; color: var(--bark); }
.stat:hover { border-color: var(--bush); }
.stat__n { font: 600 var(--step-3)/1.1 var(--serif); color: var(--bush); }
.stat__n--small { font-size: var(--step-1); }
.click-chart { margin: 1.5rem 0; max-width: 46rem; }
.click-chart figcaption { font-size: var(--step--1); color: var(--lichen); margin-bottom: 0.4rem; }
.click-chart__bars { display: flex; align-items: flex-end; gap: 2px; height: 8rem; border-bottom: 1px solid var(--rule); }
.click-chart__bar { flex: 1; background: var(--bush); border-radius: 2px 2px 0 0; min-height: 1px; }
.click-chart__axis { display: flex; justify-content: space-between; font-size: var(--step--1); color: var(--lichen); }
.report-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(18rem, 1fr)); gap: 2rem; }
.num { text-align: right; font-variant-numeric: tabular-nums; }
.add-listing { background: var(--paper); border: 1px solid var(--rule); border-radius: var(--radius); padding: 1rem 1.1rem; margin-bottom: 1.5rem; }
.add-listing h2 { font-size: var(--step-1); margin: 0 0 0.5rem; }
.plant-search-results { list-style: none; padding: 0; margin: 0.5rem 0 0; }
.plant-search-results li { padding-block: 0.6rem; border-top: 1px solid var(--rule); }
.plant-search-results p { margin: 0 0 0.35rem; }
.listing-edit { display: flex; flex-wrap: wrap; gap: 0.4rem 0.6rem; align-items: center; margin: 0; }
.listing-edit input[type="url"] { width: 16rem; }
.listing-edit input[type="number"] { width: 6rem; }
.listing-edit input[type="text"] { width: 8rem; }
.listing-edit input[type="url"], .listing-edit input[type="number"], .listing-edit input[type="text"] {
  font: inherit; font-size: var(--step--1); padding: 0.35rem 0.5rem; border: 1px solid var(--rule); border-radius: 4px; background: var(--paper); }
.listing-table { width: 100%; border-collapse: collapse; font-size: var(--step--1); }
.listing-table th, .listing-table td { text-align: left; padding: 0.55rem 0.5rem; border-bottom: 1px solid var(--rule); vertical-align: middle; }
.listing-table thead th { color: var(--lichen); }
.listing-table tr.is-out th a { color: var(--lichen); }
.saved { color: #1f5135; font-weight: 700; }
.listing--out { opacity: 0.7; }
.listing__about { grid-column: 1 / -1; display: block; font-size: var(--step--1); color: var(--lichen); }
.form--narrow { max-width: 34rem; }
.benefits { padding-left: 1.2rem; display: grid; gap: 0.4rem; max-width: 40rem; }
.footer-links { display: flex; flex-wrap: wrap; gap: 0.25rem 1.25rem; }

/* --- Legal pages ------------------------------------------------------------------ */
.legal { max-width: 42rem; }
.legal h2 { font-size: var(--step-2); margin-top: 2rem; }
.legal h3 { font: 700 var(--step-0)/1.3 var(--sans); margin: 1.25rem 0 0.4rem; }
.legal ul { padding-left: 1.2rem; display: grid; gap: 0.4rem; }
.legal__footer { margin-top: 2.5rem; padding-top: 1rem; border-top: 1px solid var(--rule); }

/* --- Layout planner ------------------------------------------------------------ */

.planner__head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 0.5rem 2rem; }
.planner__head .page-title { margin-bottom: 0.25rem; }
.planner__status { margin: 0; }
.planner__controls { display: flex; flex-wrap: wrap; gap: 0.75rem 1.25rem; align-items: center; margin: 1rem 0 1.5rem;
  padding: 0.75rem 1rem; background: var(--paper); border: 1px solid var(--rule); border-radius: var(--radius); }
.planner__controls label { font-weight: 700; font-size: var(--step--1); display: flex; align-items: center; gap: 0.4rem; }
.planner__controls input { width: 4.5rem; font: inherit; padding: 0.3rem 0.4rem; border: 1px solid var(--rule); border-radius: 4px; background: var(--paper); }
.planner__controls select { width: auto; padding: 0.3rem; }
.planner__body { display: grid; grid-template-columns: 17rem minmax(0, 1fr); gap: 2rem; align-items: start; }
.planner__side { position: sticky; top: 1rem; }
.planner__side h2, .planner__views h2 { font-size: var(--step-1); margin: 0 0 0.6rem; }
.planner__views section { margin-bottom: 2rem; }
.planner__note { font-size: var(--step--1); margin: 0.4rem 0 0; max-width: 46rem; }
@media (max-width: 56rem) {
  .planner__body { grid-template-columns: 1fr; }
  .planner__side { position: static; }
}

.palette { list-style: none; padding: 0; margin: 0; border-top: 1px solid var(--rule); max-height: 60vh; overflow-y: auto; }
.palette__item { display: grid; grid-template-columns: auto 1fr auto; gap: 0.6rem; align-items: center; padding: 0.55rem 0; border-bottom: 1px solid var(--rule); font-size: var(--step--1); }
.palette__swatch { width: 1.6rem; height: 1.6rem; border-radius: 50%; display: grid; place-items: center; }
.palette__swatch span { width: 0.8rem; height: 0.8rem; border-radius: 50%; box-shadow: 0 0 0 1px rgb(0 0 0 / 0.15); }
.palette__text a { font-weight: 700; }
.palette__meta { color: var(--lichen); }
.palette__over { color: var(--ochre); font-weight: 700; }
.selection { margin-top: 1rem; }
.selection p { margin: 0 0 0.4rem; }

.plan, .profile { width: 100%; height: auto; display: block; background: var(--paper); border: 1px solid var(--rule); border-radius: var(--radius); touch-action: none; }

.plan .bed { fill: #e8dcc6; stroke: #b9a37e; stroke-width: 0.03; }
.plan .grid, .profile .grid { stroke: rgb(0 0 0 / 0.1); stroke-width: 0.015; }
.plan .edge-label, .profile .edge-label { fill: var(--lichen); text-anchor: middle; font-family: var(--sans); }
.plan .empty-label { fill: var(--lichen); text-anchor: middle; font-family: var(--sans); }
.plan .spot { cursor: grab; outline: none; }
.plan .spot:active { cursor: grabbing; }
.plan .spot__leaf { fill-opacity: 0.85; stroke: rgb(0 0 0 / 0.25); stroke-width: 0.02; }
.plan .spot__flower { stroke: rgb(0 0 0 / 0.2); stroke-width: 0.015; }
.plan .spot__crowded { fill: none; stroke: var(--ochre); stroke-width: 0.04; stroke-dasharray: 0.12 0.08; }
.plan .spot__selected { fill: none; stroke: var(--wattle); stroke-width: 0.07; }
.plan .spot:focus-visible .spot__leaf { stroke: var(--wattle); stroke-width: 0.08; }
.plan .spot__label { fill: #fff; text-anchor: middle; font-family: var(--sans); font-weight: 700; paint-order: stroke; stroke: rgb(0 0 0 / 0.45); stroke-width: 0.03; pointer-events: none; }
.profile .sky { fill: var(--paper); }
.profile .ground { fill: #b9a37e; }
.profile .tick { fill: var(--lichen); text-anchor: end; font-family: var(--sans); }
.profile .flower-dot { stroke: rgb(0 0 0 / 0.2); stroke-width: 0.005; }
.profile .is-selected { filter: drop-shadow(0 0 0.05px var(--wattle)); }

.year { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 4px; max-width: 46rem; }
.year__month { display: flex; flex-direction: column; justify-content: flex-end; gap: 4px; min-height: 9rem; padding: 4px;
  background: var(--paper); border: 1px solid var(--rule); border-radius: 4px; cursor: pointer; font: inherit; }
.year__month:hover { border-color: var(--bush); }
.year__month.is-current { outline: 3px solid var(--wattle); outline-offset: 1px; }
.year__swatches { display: flex; flex-direction: column-reverse; gap: 2px; }
.year__swatch { height: 0.45rem; border-radius: 2px; box-shadow: inset 0 0 0 1px rgb(0 0 0 / 0.12); }
.year__more { font-size: 0.7rem; color: var(--lichen); text-align: center; }
.year__label { font-size: var(--step--1); font-weight: 700; color: var(--bark); text-align: center; }

@media print {
  .planner__body { grid-template-columns: 1fr; }
  .planner__side { display: none; }
  .year__month { min-height: 6rem; }
}
.fit-note { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem 1rem; }
.fit-note[hidden], .selection[hidden] { display: none; }

/* --- Home: how it works, and why "Midstorey" ------------------------------------ */
.hero__local-help { margin: -0.2rem 0 0.5rem; color: var(--lichen); font-size: var(--step--1); }
.steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0 2rem; margin: 0 0 3rem;
  padding-block: 1.5rem; border-block: 1px solid var(--rule); }
.step h2 { font-size: var(--step-1); margin: 0 0 0.4rem; display: flex; align-items: center; gap: 0.5rem; }
.step__n { display: inline-grid; place-items: center; width: 1.6rem; height: 1.6rem; border-radius: 50%;
  background: var(--wattle); color: var(--bark); font: 700 var(--step--1)/1 var(--sans); }
.step p { margin: 0; color: var(--lichen); }
@media (max-width: 44rem) { .steps { grid-template-columns: 1fr; gap: 1.25rem; } }
.why { display: grid; grid-template-columns: 5rem minmax(0, 40rem); gap: 1.5rem; align-items: start; margin-top: 3.5rem;
  padding: 1.75rem; background: var(--paper); border: 1px solid var(--rule); border-radius: var(--radius); }
.why__mark { width: 5rem; height: 5rem; }
.why h2 { margin-top: 0; }
.why__links { display: flex; flex-wrap: wrap; gap: 0.75rem 1.25rem; align-items: center; margin-bottom: 0; }
@media (max-width: 44rem) { .why { grid-template-columns: 1fr; } .why__mark { width: 3.5rem; height: 3.5rem; } }
.planner__tagline { margin: 0; }
.calendar--compact .calendar__month.is-now::after { display: none; }
.hero h1 { text-wrap: balance; }


/* --- Home: illustrated garden section ----------------------------------------- */
.hero__art { margin: 0; }
.garden-section { width: 100%; height: auto; display: block; }
.gs-soil { fill: #d9c9a8; }
.gs-grass { stroke: #8aa857; stroke-width: 4; stroke-linejoin: round; }
.gs-trunk { fill: #7a6250; }
.gs-leaf-dark { fill: #2f5a47; }
.gs-leaf { fill: #5a8a5f; stroke: rgb(0 0 0 / 0.12); stroke-width: 1; }
.gs-leaf-light { fill: #7fa463; stroke: rgb(0 0 0 / 0.1); stroke-width: 1; }
.gs-strap { stroke: #7a9a5a; stroke-width: 2.4; fill: none; stroke-linecap: round; }
.gs-bird { fill: #3d4a52; }
.gs-leader { stroke: var(--lichen); stroke-width: 1; stroke-dasharray: 2 3; }
.gs-label { font: 600 15px var(--sans); fill: var(--lichen); }
.gs-label--mid { fill: var(--bark); font-weight: 700; }
@media (prefers-color-scheme: dark) { .gs-soil { fill: #5a4c38; } }
@media (max-width: 52rem) {
  .hero { grid-template-columns: minmax(0, 1fr); gap: 1rem; }
  .hero__art { order: -1; max-width: 26rem; }
}
.planner__list-name { display: block; font-size: var(--step-1); color: var(--lichen); font-weight: 400; margin-top: 0.2rem; }

/* --- List page ------------------------------------------------------------------ */
.list-hero { display: grid; grid-template-columns: minmax(0, 1fr) minmax(16rem, 21rem); gap: 1.5rem 2.5rem; align-items: start; margin-bottom: 1.5rem; }
.list-hero .page-title { margin-bottom: 0.3rem; }
.list-hero__meta { margin: 0 0 0.6rem; color: var(--lichen); }
.list-hero__desc { max-width: 42rem; margin: 0 0 0.5rem; }
.list-hero__tools { display: flex; flex-wrap: wrap; gap: 0.4rem 1.25rem; margin: 0.75rem 0 0; font-size: var(--step--1); }
.list-hero__tools .link-button { color: var(--bush); font-size: inherit; }
@media (max-width: 48rem) { .list-hero { grid-template-columns: 1fr; } }

.layout-card { display: grid; grid-template-rows: auto auto; background: var(--paper); border: 1px solid var(--rule);
  border-radius: var(--radius); overflow: hidden; text-decoration: none; color: var(--bark); transition: border-color 0.15s, box-shadow 0.15s; }
.layout-card:hover, .layout-card:focus-visible { border-color: var(--bush); box-shadow: 0 4px 14px rgb(0 0 0 / 0.08); }
.layout-card__plan { display: block; width: 100%; height: 9.5rem; background: #f3eee4; padding: 0.75rem; box-sizing: border-box; }
.lc-bed { fill: #e8dcc6; stroke: #b9a37e; stroke-width: 0.03; }
.lc-leaf { fill-opacity: 0.88; stroke: rgb(0 0 0 / 0.2); stroke-width: 0.02; }
.lc-flower { stroke: rgb(0 0 0 / 0.15); stroke-width: 0.02; }
.lc-empty { fill: var(--lichen); font-family: var(--sans); }
.layout-card__body { display: grid; gap: 0.15rem; padding: 0.75rem 1rem 0.9rem; border-top: 1px solid var(--rule); }
.layout-card__title { font: 600 var(--step-1)/1.2 var(--serif); color: var(--bush); }
.layout-card__title::after { content: " \2192"; }
.layout-card__meta { font-size: var(--step--1); color: var(--lichen); }

.list-settings-bar { display: grid; gap: 0.75rem; margin-bottom: 2rem; max-width: 46rem; }
.list-settings-bar .share-box { margin: 0; }

.list-year { margin-bottom: 2rem; }
.list-year h2, .list-section-title { font-size: var(--step-1); margin: 0 0 0.6rem; }
.list-year__months { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 4px; max-width: 46rem; }
.list-year__month { display: flex; flex-direction: column; justify-content: flex-end; gap: 3px; min-height: 5.5rem; padding: 4px;
  background: var(--paper); border: 1px solid var(--rule); border-radius: 4px; }
.list-year__chips { display: flex; flex-direction: column-reverse; gap: 2px; }
.list-year__chip { height: 0.45rem; border-radius: 2px; box-shadow: inset 0 0 0 1px rgb(0 0 0 / 0.12); }
.list-year__label { font-size: var(--step--1); font-weight: 700; text-align: center; }

.list-item { grid-template-columns: minmax(0, 1.2fr) auto minmax(0, 1fr) auto; }
.list-item__cal { width: 9.6rem; }
@media (max-width: 60rem) { .list-item__cal { display: none; } .list-item { grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr) auto; } }
.share-box__row .button { white-space: nowrap; }
.list-item__cal { margin-right: 0.5rem; }
.planner__slope-note { font-weight: 400; }
.profile .slope { stroke: #b9a37e; stroke-width: 0.01; }
.profile .contour { stroke: rgb(120 95 60 / 0.25); stroke-width: 0.012; }
.plan .edge-label--halo { paint-order: stroke; stroke: var(--paper); stroke-width: 0.06; stroke-linejoin: round; pointer-events: none; }

/* --- Profile (rebuilt) -------------------------------------------------------- */
.profile-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 0.5rem 1rem; }
.profile-box { background: var(--paper); border: 1px solid var(--rule); border-radius: var(--radius); overflow: hidden; }
.planner__views .profile { display: block; width: auto; max-width: 100%; height: auto; border: 0; border-radius: 0; background: none; margin: 0 auto; }
.profile .sky { fill: var(--paper); }
.profile .soil { fill: #c7b08a; }
.profile .surface-line { stroke: #9c8259; }
.profile .back-edge { stroke: #b39a72; }
.profile .grid { stroke: rgb(0 0 0 / 0.08); }
.profile .tick { fill: var(--lichen); text-anchor: end; font-family: var(--sans); }
.profile .profile-label { fill: #4e3f2a; font-family: var(--sans); font-weight: 600; }
.segmented { display: inline-flex; border: 1px solid var(--rule); border-radius: 99px; overflow: hidden; background: var(--paper); }
.segmented button { font: inherit; font-size: var(--step--1); padding: 0.3rem 0.85rem; border: 0; background: none; cursor: pointer; color: var(--bark); }
.segmented button[aria-pressed="true"] { background: var(--bush); color: var(--paper); }

/* --- Bed shape: drawing and editing the bed's edge ---------------------------------- */
.shape-tools { flex-basis: 100%; display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem 0.75rem;
  padding-top: 0.75rem; border-top: 1px solid var(--rule); font-size: var(--step--1); }
.shape-tools__label { font-weight: 700; }
.shape-tools__buttons { display: inline-flex; flex-wrap: wrap; gap: 0.5rem; align-items: center; }
.shape-tools__buttons[hidden] { display: none; }
.shape-tools__stats { color: var(--lichen); }
.shape-tools__calc { margin-left: auto; }
.shape-tools__help { margin: -0.75rem 0 1rem; font-size: var(--step--1); padding: 0.5rem 0.9rem; border-left: 4px solid var(--wattle);
  background: var(--paper); border-radius: 0 var(--radius) var(--radius) 0; color: var(--bark); }
.shape-tools__help[hidden] { display: none; }
.plan .yard { fill: none; stroke: var(--rule); stroke-width: 1px; stroke-dasharray: 4 4; vector-effect: non-scaling-stroke; }
.plan .bed { stroke-linejoin: round; }
.plan .spot__outside { fill: none; stroke: var(--lichen); stroke-width: 1.5px; stroke-dasharray: 3 3; vector-effect: non-scaling-stroke; }
.plan .spot--inactive { pointer-events: none; opacity: 0.45; }
.plan.is-drawing { cursor: crosshair; }
.plan .draft-line { fill: rgb(35 73 59 / 0.08); stroke: var(--bush); stroke-width: 2px; stroke-dasharray: 6 4; vector-effect: non-scaling-stroke; }
.plan .corner { fill: var(--paper); stroke: var(--bush); stroke-width: 2px; vector-effect: non-scaling-stroke; }
.plan .corner--first { fill: var(--wattle); }
.plan .corner--hover { fill: var(--bush); pointer-events: none; }
.plan .corner--handle { cursor: move; outline: none; }
.plan .corner--handle:focus-visible { fill: var(--wattle); stroke-width: 3px; }
.plan .midpoint { cursor: copy; }
.plan .midpoint circle { fill: var(--paper); fill-opacity: 0.85; stroke: var(--lichen); stroke-width: 1px; vector-effect: non-scaling-stroke; }
.plan .midpoint path { stroke: var(--bush); stroke-width: 1.5px; vector-effect: non-scaling-stroke; }
.plan .edge-length { fill: var(--bush); text-anchor: middle; font-family: var(--sans); font-weight: 700; pointer-events: none;
  paint-order: stroke; stroke: var(--paper); stroke-width: 3px; stroke-linejoin: round; vector-effect: non-scaling-stroke; }
.profile .mulch { fill: #7a5a3a; }
.profile .yard-surface { fill: #dfe6d3; }

/* --- Compact plant rows on phones ------------------------------------------------
   Each row is about the height of its thumbnail: name, scientific name, then a slim
   flowering calendar with the type and height beside it. Longer details and the Add
   button are on the plant page instead. */
.plant-row__short, .plant-row__weed { display: none; }
@media (max-width: 40rem) {
  .plant-row {
    position: relative;
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas: "link";
    padding-block: 6px;
    gap: 0;
    --thumb: 56px;
    --cal-cell: 0.6rem;
    --cal-width: calc(12 * var(--cal-cell) + 11 * 2px);
  }
  .plant-row__facts, .plant-row .tag, .plant-row .row-add { display: none; }
  .plant-row__link { gap: 0.75rem; }
  .plant-row__thumb { width: var(--thumb); height: var(--thumb); }
  .plant-row__thumb--empty { font-size: 1.5rem; }
  .plant-row__names { line-height: 1.25; }
  .plant-row__names > span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .plant-row__common { font-size: var(--step-0); }
  .plant-row__names .sci { font-size: var(--step--1); }
  /* Third line: the calendar sits at its start (positioned over the row so taps still
     open the plant), and the type and height follow it. */
  .plant-row__short { display: block; font-size: var(--step--1); color: var(--lichen);
    padding-left: calc(var(--cal-width) + 0.5rem); }
  .plant-row__calendar { display: block; position: absolute; margin: 0; pointer-events: none;
    left: calc(var(--thumb) + 0.75rem); bottom: calc(6px + 0.2rem); }
  .plant-row__calendar .calendar--compact { grid-template-columns: repeat(12, var(--cal-cell)); }
  .plant-row__calendar .calendar--compact .calendar__month { aspect-ratio: 1 / 1.45; }
  .plant-row__weed { display: inline-grid; place-items: center; width: 1.05rem; height: 1.05rem; margin-left: 0.35rem;
    border-radius: 50%; background: var(--ochre-soft); color: var(--ochre); font: 700 0.75rem/1 var(--sans); vertical-align: 0.1em; }
}

/* --- Garden calculators -------------------------------------------------------------- */
.calcs__tagline { margin-top: 0; max-width: 44rem; }
.calcs__note { font-size: var(--step--1); margin-top: 2rem; }
.calc-area, .calc { background: var(--paper); border: 1px solid var(--rule); border-radius: var(--radius); padding: 1rem 1.25rem; }
.calc-area { margin: 1.5rem 0 2rem; display: grid; gap: 0.75rem; justify-items: start; }
.calc-area h2, .calc h2 { font-size: var(--step-1); margin: 0; }
.calc-area__from { margin: 0; }
.calc-area__fields, .calc-area__fields > div { display: flex; flex-wrap: wrap; gap: 0.75rem 1.25rem; align-items: end; }
.calc-area__fields > div[hidden] { display: none; }
.calc-area__hint { margin: 0; font-size: var(--step--1); max-width: 46rem; }
.calc-area label, .calc label { font-weight: 700; font-size: var(--step--1); display: grid; gap: 0.25rem; }
.unit-input { display: inline-flex; align-items: center; gap: 0.35rem; font-weight: 400; }
.unit-input input { width: 6.5rem; padding: 0.4rem 0.5rem; }
.calc-area input[readonly] { background: var(--gum-leaf); }
.calc-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 21rem), 1fr)); gap: 1.25rem; align-items: start; }
.calc { display: grid; gap: 0.75rem; }
.calc select { width: 100%; padding: 0.4rem; font-weight: 400; }
.calc__choice { border: 0; padding: 0; margin: 0; display: grid; gap: 0.3rem; }
.calc__choice legend { font-weight: 700; font-size: var(--step--1); padding: 0; margin-bottom: 0.2rem; }
.calc__choice label { display: flex; gap: 0.5rem; align-items: center; font-weight: 400; }
.calc__inline { margin: 0; font-size: var(--step--1); display: flex; flex-wrap: wrap; align-items: center; gap: 0.35rem; }
.calc__inline input { width: 4.5rem; }
.calc__inline select { width: auto; }
.chips { display: flex; flex-wrap: wrap; gap: 0.35rem; margin: -0.35rem 0 0; }
.chips button { font: inherit; font-size: 0.8rem; padding: 0.2rem 0.6rem; border-radius: 99px; border: 1px solid var(--rule);
  background: var(--gum-leaf); color: var(--bark); cursor: pointer; }
.chips button:hover { border-color: var(--bush); color: var(--bush); }
.calc__result { margin: 0.25rem 0 0; padding: 0.6rem 0.8rem; border-radius: var(--radius); background: var(--bush-soft);
  font: 600 var(--step-1)/1.3 var(--serif); }
.calc__working { margin: 0; font-size: var(--step--1); color: var(--lichen); }
.calc__tip { margin: 0; font-size: var(--step--1); border-top: 1px solid var(--rule); padding-top: 0.6rem; }
.calc__bucket summary { cursor: pointer; color: var(--bush); font-size: var(--step--1); }
.calc__bucket[open] { display: grid; gap: 0.5rem; }
.calc__bucket p { margin: 0; font-size: var(--step--1); }
@media print { .chips, .calc__bucket, .calc-area .segmented { display: none; } }

/* --- Climbers: up a support or along the ground ---------------------------------------- */
.selection__habit { margin: 0.25rem 0 0.75rem; }
.selection__habit[hidden] { display: none; }
.selection__habit-label { font-size: var(--step--1); font-weight: 700; margin: 0 0 0.3rem; }
