:root {
  --ink: #19392d;
  --muted: #53675d;
  --green: #204e3a;
  --line: #d5ddd2;
  --paper: #f8f9f4;
  --serif: Georgia, "Times New Roman", serif;
  color: var(--ink);
  background: var(--paper);
  font:
    16px/1.5 "DM Sans",
    "Segoe UI",
    Arial,
    sans-serif;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
button,
input,
select {
  font: inherit;
}
button,
a {
  color: inherit;
}
button {
  cursor: pointer;
}
button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible {
  outline: 3px solid #a36944;
  outline-offset: 3px;
}
button {
  background: white;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 8px 14px;
}
a {
  text-underline-offset: 3px;
}
header {
  border-bottom: 1px solid var(--line);
  background: #fff;
}
.bar,
main,
footer {
  width: min(1376px, 94%);
  margin: auto;
}
.bar {
  display: flex;
  align-items: center;
  gap: 32px;
  min-height: 73px;
}
.brand {
  border: 0;
  background: transparent;
  padding: 0;
  display: flex;
  align-items: center;
  gap: 10px;
  font: 600 clamp(21px, 2.4vw, 31px)/1 var(--serif);
  white-space: nowrap;
  letter-spacing: -1.6px;
}
.brand i {
  font-weight: 400;
}
.brand img {
  width: 37px;
  height: 37px;
  object-fit: contain;
}
nav {
  display: flex;
  margin: auto;
  align-self: stretch;
  gap: 26px;
}
nav a {
  display: grid;
  align-content: center;
  border-bottom: 3px solid transparent;
  text-decoration: none;
  padding-top: 3px;
  color: var(--muted);
  font-size: 0.94rem;
}
nav a.active {
  border-color: var(--green);
  font-weight: 650;
  color: var(--ink);
}
.saveNav,
.pill,
.btn,
.heroLabel,
.cardMeta span,
.book,
.sectionLink {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.saveNav {
  background: transparent;
  border-radius: 22px;
  font-size: 0.88rem;
}
svg {
  vertical-align: middle;
  flex-shrink: 0;
}
main {
  min-height: 73vh;
  padding: 25px 0 42px;
}
.hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  border-radius: 20px;
  min-height: 315px;
  display: grid;
  align-content: center;
  padding: 35px clamp(24px, 4vw, 62px);
  color: white;
  background: #143a2e url(img/hero.webp) center 56% / cover;
}
.hero:before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(
    90deg,
    rgba(8, 38, 28, 0.94),
    rgba(9, 43, 29, 0.77) 32%,
    rgba(9, 40, 28, 0.23) 64%,
    rgba(12, 40, 28, 0.03)
  );
}
.heroLabel,
.eyebrow {
  font:
    650 0.75rem/1.3 "Segoe UI",
    Arial,
    sans-serif;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.heroLabel {
  color: #d2e7c2;
}
.hero h1 {
  font: 400 clamp(38px, 4.2vw, 66px)/1.01 var(--serif);
  letter-spacing: -0.043em;
  margin: 15px 0 9px;
}
.hero h1 i {
  font-weight: 400;
  color: #d4e5b7;
}
.hero p {
  margin: 0 0 18px;
  font-size: 1rem;
  color: #f0f3e8;
}
.heroActions,
.actions,
.pills,
.cardMeta {
  display: flex;
  gap: 9px;
  flex-wrap: wrap;
  align-items: center;
}
.btn {
  border-radius: 8px;
  border: 1px solid transparent;
  background: var(--green);
  color: white;
  min-height: 40px;
  padding: 8px 15px;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.9rem;
}
.hero .btn {
  background: #e5efc9;
  color: #203e30;
}
.hero .secondary {
  background: #183f32ad;
  border-color: #abc1a282;
  color: white;
}
.eyebrow {
  color: #637a56;
}
.sectionTitle {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  margin: 29px 0 14px;
}
.sectionTitle h2,
.pageTitle,
h1,
h2,
h3 {
  font-family: var(--serif);
  font-weight: 500;
  line-height: 1.12;
}
.sectionTitle h2 {
  font-size: clamp(28px, 3vw, 40px);
  margin: 5px 0 0;
  letter-spacing: -0.035em;
}
.sectionLink {
  color: var(--green);
  font-size: 0.92rem;
  font-weight: 650;
  background: transparent;
  border: 0;
  padding: 5px 0;
}
.pills {
  margin: 0 0 18px;
}
.pill {
  border-radius: 24px;
  padding: 6px 13px;
  background: transparent;
  font-size: 0.89rem;
}
.pill.on {
  background: var(--green);
  color: white;
  border-color: var(--green);
}
.grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}
.plant {
  background: white;
  border: 1px solid var(--line);
  border-radius: 13px;
  position: relative;
  overflow: hidden;
  min-width: 0;
}
.cardOpen {
  width: 100%;
  border: 0;
  text-align: left;
  background: none;
  padding: 0;
  display: block;
}
.photo {
  width: 100%;
  aspect-ratio: 1.75;
  object-fit: cover;
  display: block;
}
.book {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 34px;
  height: 34px;
  background: #fffffff0;
  border: 0;
  border-radius: 50%;
  justify-content: center;
  padding: 0;
}
.book.chosen svg {
  fill: currentColor;
}
.cardText {
  padding: 13px 15px;
}
.cardText h3 {
  margin: 0 0 2px;
  font-size: 1.42rem;
  letter-spacing: -0.025em;
}
.latin {
  font: italic 1rem var(--serif);
  color: var(--muted);
}
.cardMeta {
  font-size: 0.81rem;
  padding-top: 10px;
  margin-top: 11px;
  border-top: 1px solid #e6ebe2;
  color: #43594d;
  gap: 13px;
}
.cardMeta span {
  gap: 4px;
}
.pageTitle {
  font-size: clamp(32px, 4vw, 52px);
  margin: 6px 0 12px;
  letter-spacing: -0.04em;
}
.tools {
  margin: 24px 0 12px;
  padding: 17px;
  background: #edf1e8;
  border: 1px solid var(--line);
  border-radius: 12px;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.tools input,
.tools select,
.filters select {
  padding: 9px 10px;
  border: 1px solid #b9c9b9;
  border-radius: 7px;
  background: white;
  color: var(--ink);
  min-width: 0;
}
.tools input {
  flex: 1;
  min-width: 160px;
}
.count {
  margin: 12px 0;
  font-size: 0.92rem;
  color: var(--muted);
}
.entries {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
.entry {
  text-align: left;
  padding: 13px 16px;
}
.entry small {
  display: block;
  color: var(--muted);
}
.empty {
  padding: 24px;
  background: #edf1e8;
  border-radius: 12px;
}
.more {
  display: block;
  margin: 20px auto;
}
.filters {
  display: grid;
  gap: 14px;
}
.filters label {
  display: grid;
  gap: 3px;
}
.panelHead {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 15px;
  position: sticky;
  top: 0;
  background: white;
  z-index: 2;
  padding: 17px 22px;
  border-bottom: 1px solid var(--line);
}
.panelHead h2 {
  font-size: 1.65rem;
  margin: 0;
}
.round {
  border-radius: 50%;
  width: 32px;
  height: 32px;
  padding: 0;
  line-height: 1;
}
.detailImg {
  width: 100%;
  max-height: 300px;
  object-fit: cover;
  border-radius: 10px;
}
.detail h3 {
  margin-bottom: 5px;
}
.detail p {
  margin: 4px 0 14px;
}
.tag {
  display: inline-block;
  background: #eaf0e4;
  font-size: 0.84rem;
  padding: 3px 9px;
  border-radius: 20px;
  margin: 2px;
}
.guideLinks {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.guideLinks button {
  text-align: left;
  background: #eaf0e4;
  padding: 20px;
}
.guideLinks b {
  font: 500 1.4rem var(--serif);
  display: block;
}
.guideLinks small {
  color: var(--muted);
}
dialog {
  width: min(600px, 94vw);
  padding: 0;
  border: none;
  border-radius: 16px;
  color: var(--ink);
  max-height: 86dvh;
  box-shadow: 0 20px 70px #11241d42;
}
dialog::backdrop {
  background: #0b2119aa;
}
#panelBody {
  padding: 20px;
}
footer {
  display: flex;
  border-top: 1px solid var(--line);
  padding: 16px 0 28px;
  align-items: center;
  justify-content: space-between;
  font-family: var(--serif);
}
footer button {
  border: 0;
  background: transparent;
  color: var(--muted);
  font: 14px Arial;
}
#toast {
  position: fixed;
  bottom: 18px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--ink);
  color: white;
  border-radius: 10px;
  padding: 9px 16px;
  z-index: 10;
  pointer-events: none;
}
#toast:empty {
  display: none;
}
.credits {
  font-size: 0.87rem;
  color: var(--muted);
}
@media (max-width: 900px) {
  .grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .bar {
    gap: 14px;
  }
  nav {
    gap: 15px;
  }
}
@media (max-width: 680px) {
  .bar {
    flex-wrap: wrap;
    min-height: 0;
    padding: 9px 0 0;
    justify-content: space-between;
    gap: 4px;
  }
  .bar nav {
    order: 3;
    width: 100%;
    justify-content: space-between;
  }
  .bar nav a {
    padding: 8px 3px;
  }
  .bar,
  main,
  footer {
    width: 94%;
  }
  .saveNav {
    padding: 6px 10px;
  }
  .grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 9px;
  }
  main {
    padding-top: 12px;
  }
  .hero {
    min-height: 274px;
    padding: 21px 17px;
    border-radius: 14px;
    background-position: 63% center;
  }
  .hero p {
    max-width: 22em;
  }
  .hero .btn {
    font-size: 0.82rem;
    padding: 7px 10px;
  }
  .cardText {
    padding: 9px;
  }
  .cardText h3 {
    font-size: 1.15rem;
  }
  .cardMeta {
    gap: 4px 8px;
    padding-top: 7px;
    margin-top: 8px;
  }
  .latin {
    font-size: 0.88rem;
  }
  .entries,
  .guideLinks {
    grid-template-columns: 1fr;
  }
  .sectionTitle {
    margin-top: 22px;
  }
  .pills {
    gap: 6px;
  }
  .pill {
    padding: 5px 10px;
  }
  .tools {
    padding: 10px;
  }
  .book {
    width: 29px;
    height: 29px;
    top: 6px;
    right: 6px;
  }
}
.filters {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 12px;
}
.filters label {
  font-size: 0.88rem;
}
.filters .actions {
  grid-column: 1/-1;
  position: sticky;
  bottom: 0;
  background: white;
  padding: 8px 0;
}
.compare {
  overflow-x: auto;
}
.compare table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
}
.compare th,
.compare td {
  text-align: left;
  padding: 8px;
  vertical-align: top;
  border-bottom: 1px solid var(--line);
}
.compare thead {
  background: #edf1e8;
}
.compare th small {
  display: block;
  font-weight: 400;
}
.botanyDetail {
  margin: 18px 0;
}
.botanyDetail img {
  display: block;
  width: 100%;
  max-height: 300px;
  object-fit: contain;
  background: #f1f3eb;
  border-radius: 8px;
}
.botanyDetail figcaption,
#offlineState {
  font: 13px/1.5 Arial;
  color: var(--muted);
}
#offlineState {
  margin-left: 7px;
}
.detail h3 {
  margin-top: 20px;
}
button:hover,
.pill:hover {
  filter: brightness(0.96);
}
.cardOpen:hover img {
  filter: saturate(1.13);
}
@media (max-width: 390px) {
  .hero .heroActions {
    gap: 5px;
  }
  .filters {
    gap: 7px;
  }
  .filters select {
    font-size: 0.88rem;
    padding: 8px 3px;
  }
}
.cultivarLink {
  font: inherit;
  text-align: left;
  background: transparent;
  border: 0;
  padding: 0;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.cultivarLink img {
  width: 85px;
  height: 60px;
  display: block;
  object-fit: cover;
  border-radius: 5px;
  margin-bottom: 4px;
}
@media (min-width: 681px) {
  .guideLinks {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
.species-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,290px),1fr));gap:10px}.secondary-rows{margin-top:15px}.species-row{display:flex;align-items:center;text-align:left;gap:14px;border:1px solid var(--line);border-radius:11px;min-height:80px;overflow:hidden;padding:8px 13px}.species-row img{width:63px;height:63px;object-fit:contain;flex-shrink:0;border-radius:6px}.species-row strong,.species-row em,.species-row small{display:block}.species-row strong{font:500 1.16rem Georgia,serif}.species-row em{color:var(--muted);font:italic .94rem Georgia,serif}.species-row small{margin-top:5px;font-size:.81rem}.specimen-figure{margin:12px 0}.specimen-figure img{display:block;width:100%;height:auto;max-height:350px;object-fit:contain;border-radius:8px;background:#f4f6ef}.specimen-figure figcaption{font-size:.84rem;color:var(--muted);margin:5px 0 15px}.record-section dl{margin:8px 0 14px}.record-section dl div{display:grid;grid-template-columns:minmax(105px,.48fr) 1fr;gap:9px;padding:7px 0;border-bottom:1px solid var(--line)}.record-section dd{margin:0}.record-section dt,.evidence{color:var(--muted);font-size:.9rem}.related{max-height:250px;overflow:auto;display:flex;flex-wrap:wrap;gap:5px;padding:8px 0}.detail summary{cursor:pointer;padding:7px 0}.observation{background:#edf1e8;padding:12px;margin:12px 0;border-radius:10px}
.specimen-figure img[hidden],.species-row img[hidden]{display:none}.media-status{display:block;color:var(--ink)}.detail .evidence{padding-left:1.2em}.detail details+details{margin-top:5px}
.ficha-photo{padding:1rem 0;border-bottom:1px solid #d5e0d7;margin-bottom:1rem}.ficha-photo h3{margin:0 0 .45rem}.ficha-photo .fp-preview img{width:100%;max-height:24rem;object-fit:contain;display:block;background:#edf3ee;border-radius:.75rem}.fp-actions{display:flex;flex-wrap:wrap;gap:.55rem;align-items:center}.fp-pick{position:relative;display:inline-flex;align-items:center;min-height:44px;background:#20533f;color:#fff;border-radius:.55rem;padding:.45rem .8rem;cursor:pointer;font-weight:600}.fp-pick input{position:absolute;inset:0;width:100%;height:100%;opacity:0;cursor:pointer}.fp-pick:focus-within{outline:3px solid #3c8767;outline-offset:3px}.fp-actions button[hidden]{display:none}.fp-status:empty{display:none}.fp-status,.fp-info{font-size:.9rem}.has-ficha-photo>img:not([data-personal-thumb]),.has-ficha-photo>.photo-empty{display:none}.photo-empty{display:grid;place-items:center;flex:none;width:50px;height:50px;background:#e6eee7;border-radius:8px;color:#527362}.photo-empty svg{width:23px}
