:root {
  --ink: #1a2420;
  --ink-soft: #3d4a44;
  --paper: #f3f6f2;
  --paper-2: #e7eee6;
  --moss: #2f5d45;
  --moss-deep: #1e3d2d;
  --amber: #c45c26;
  --line: rgba(30, 61, 45, 0.14);
  --shadow: 0 18px 40px rgba(20, 35, 28, 0.12);
  --radius: 14px;
  --font-display: "Fraunces", Georgia, serif;
  --font-body: "Source Sans 3", "Segoe UI", sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  font-family: var(--font-body);
  background: var(--paper);
  line-height: 1.45;
}

.bg-wash {
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(1200px 600px at 10% -10%, rgba(196, 92, 38, 0.12), transparent 55%),
    radial-gradient(900px 500px at 90% 0%, rgba(47, 93, 69, 0.16), transparent 50%),
    linear-gradient(180deg, #eef4ec 0%, #f7faf6 45%, #e8efe6 100%);
}

.bg-wash::after {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cpath d='M0 60h120M60 0v120' stroke='%231e3d2d' stroke-width='1' fill='none'/%3E%3C/svg%3E");
}

a {
  color: var(--moss-deep);
  text-underline-offset: 0.15em;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.site-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem 1.5rem;
  padding: 1.25rem clamp(1rem, 3vw, 2.5rem);
  position: sticky;
  top: 0;
  z-index: 10;
  backdrop-filter: blur(10px);
  background: rgba(243, 246, 242, 0.82);
  border-bottom: 1px solid var(--line);
}

.brand {
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.2rem;
}

.brand-lockup {
  display: flex;
  align-items: baseline;
  gap: 0.55rem;
}

.brand-mark {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  letter-spacing: -0.03em;
  color: var(--moss-deep);
}

.brand-sub {
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--amber);
}

.brand-stand {
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  color: var(--ink-soft);
  opacity: 0.85;
  line-height: 1.2;
}

.header-tools {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 0.65rem 0.85rem;
  flex: 1 1 320px;
  min-width: min(100%, 280px);
}

.search-form {
  display: flex;
  gap: 0.5rem;
  flex: 1 1 220px;
  max-width: 420px;
}

.tax-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  align-items: center;
}

.tax-filter select {
  appearance: none;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.75)
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%232f5d45' d='M1 1l5 5 5-5'/%3E%3C/svg%3E")
    no-repeat right 0.7rem center;
  border-radius: 999px;
  padding: 0.55rem 1.9rem 0.55rem 0.9rem;
  font: inherit;
  font-size: 0.88rem;
  color: inherit;
  max-width: min(100%, 15rem);
  cursor: pointer;
}

.tax-filter select:focus {
  outline: 2px solid rgba(47, 93, 69, 0.35);
  outline-offset: 1px;
}

.tax-filter select:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.search-form input {
  flex: 1;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.75);
  border-radius: 999px;
  padding: 0.7rem 1rem;
  font: inherit;
  color: inherit;
}

.search-form input:focus {
  outline: 2px solid rgba(47, 93, 69, 0.35);
  outline-offset: 1px;
}

.search-form input:not(:placeholder-shown) {
  border-color: rgba(47, 93, 69, 0.45);
  background: rgba(255, 255, 255, 0.92);
}

.search-form button,
.btn {
  border: 0;
  border-radius: 999px;
  background: var(--moss);
  color: #f7faf6;
  font: inherit;
  font-weight: 600;
  padding: 0.7rem 1.15rem;
  cursor: pointer;
  transition: transform 0.18s ease, background 0.18s ease;
}

.search-form button {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.search-form button:hover,
.btn:hover {
  background: var(--moss-deep);
  transform: translateY(-1px);
}

.btn-ghost {
  background: transparent;
  color: var(--moss-deep);
  border: 1px solid var(--line);
}

.btn-ghost:hover {
  background: rgba(47, 93, 69, 0.08);
}

.btn-clear {
  width: 2.35rem;
  height: 2.35rem;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: transparent;
  color: var(--ink-soft);
  font: inherit;
  font-size: 1.35rem;
  line-height: 1;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.btn-clear:hover {
  background: rgba(47, 93, 69, 0.08);
  color: var(--moss-deep);
  transform: translateY(-1px);
}

.app {
  width: min(1180px, calc(100% - 2rem));
  margin: 0 auto;
  padding: 1.5rem 0 3rem;
}

.loading,
.empty,
.error {
  padding: 2rem 0;
  color: var(--ink-soft);
}

.hero {
  display: grid;
  gap: 1.15rem;
  margin-bottom: 1.75rem;
  animation: rise 0.55s ease both;
  max-width: 40rem;
}

.hero-home {
  max-width: none;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 1.25rem 2.5rem;
  align-items: start;
}

.hero-home-copy {
  display: grid;
  gap: 1.15rem;
  max-width: 40rem;
}

.hero-home-copy--geo {
  gap: 0.85rem;
}

.hero-home--geo .hero-home-copy {
  max-width: 44rem;
}

.geo-extract p {
  margin: 0 0 0.75rem;
}

.geo-extract p:last-child {
  margin-bottom: 0;
}

.geo-extract-catalog {
  color: var(--ink);
}

.hero-iucn-filter {
  margin: 0;
  min-width: 11.5rem;
  justify-self: end;
}

.hero-filters {
  display: grid;
  gap: 1.15rem;
  justify-self: end;
  min-width: min(18rem, 100%);
}

.hero-filters .hero-iucn-filter {
  justify-self: stretch;
}

.hero-geo-filter {
  margin: 0;
}

.geo-split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.55rem 1rem;
  align-items: start;
  margin-top: 0.35rem;
}

.geo-chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: 0;
  max-width: 17.5rem;
}

.geo-chip {
  appearance: none;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.55);
  color: var(--ink-soft);
  font: inherit;
  font-size: 0.78rem;
  padding: 0.28rem 0.55rem;
  border-radius: 999px;
  cursor: pointer;
}

.geo-chip:hover {
  border-color: rgba(47, 93, 69, 0.35);
  color: var(--moss-deep);
}

.geo-chip.is-active {
  background: rgba(47, 93, 69, 0.12);
  border-color: var(--moss);
  color: var(--moss-deep);
  font-weight: 600;
}

.geo-chip-unknown {
  opacity: 0.9;
}

.geo-country-picker {
  position: relative;
  width: fit-content;
  max-width: 100%;
  margin-top: 0.05rem;
  justify-self: start;
}

.geo-country-picker.is-disabled {
  opacity: 0.55;
}

.geo-country-trigger {
  display: flex;
  align-items: center;
  width: 100%;
  box-sizing: border-box;
  font: inherit;
  font-size: 0.85rem;
  padding: 0.4rem 1.85rem 0.4rem 0.55rem;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.7);
  color: var(--ink);
  cursor: pointer;
  text-align: left;
  background-image: linear-gradient(45deg, transparent 50%, var(--ink-soft) 50%),
    linear-gradient(135deg, var(--ink-soft) 50%, transparent 50%);
  background-position: calc(100% - 14px) calc(50% - 2px), calc(100% - 9px) calc(50% - 2px);
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
}

.geo-country-trigger:disabled {
  cursor: not-allowed;
}

.geo-country-trigger-inner {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  min-width: 0;
}

.geo-flag {
  width: 20px;
  height: 15px;
  object-fit: cover;
  border-radius: 2px;
  flex: 0 0 auto;
  box-shadow: 0 0 0 1px rgba(20, 35, 28, 0.12);
}

.geo-flag--empty {
  display: inline-block;
  width: 20px;
  height: 15px;
  background: rgba(20, 35, 28, 0.08);
  border-radius: 2px;
}

.geo-country-menu {
  position: absolute;
  z-index: 40;
  top: calc(100% + 0.3rem);
  left: 0;
  right: 0;
  min-width: 100%;
  max-height: 16rem;
  overflow: auto;
  margin: 0;
  padding: 0.25rem;
  list-style: none;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.97);
  box-shadow: var(--shadow);
}

.geo-country-option {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.35rem 0.45rem;
  border-radius: 6px;
  cursor: pointer;
  font-size: 0.85rem;
}

.geo-country-option:hover,
.geo-country-option.is-selected {
  background: rgba(47, 93, 69, 0.1);
}

.geo-country-option-label {
  min-width: 0;
}

.distribution-block {
  margin-top: 0.85rem;
}

.distribution-line {
  margin: 0.25rem 0 0.2rem;
  line-height: 1.4;
}

.distribution-sep {
  margin: 0 0.35rem;
  opacity: 0.5;
}

.hero-iucn-filter .iucn-filter-caption {
  margin: 0.55rem 0 0;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.35rem 0.5rem;
}

.iucn-dot-btn {
  border: 0;
  padding: 0;
  margin: 0;
  cursor: pointer;
  opacity: 0.92;
  font: inherit;
}

.iucn-dot-btn:hover {
  opacity: 1;
  transform: scale(1.2);
}

.iucn-dot-btn:focus-visible {
  outline: 2px solid rgba(47, 93, 69, 0.45);
  outline-offset: 3px;
}

.hero-iucn-filter .iucn-dot {
  width: 0.85rem;
  height: 0.85rem;
}

.hero-care-filter {
  margin: 0;
}

.care-chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: 0.35rem;
}

.mismatch-hint {
  margin: -0.35rem 0 0.85rem;
}

@media (max-width: 760px) {
  .site-header {
    flex-direction: column;
    align-items: stretch;
    gap: 0.75rem;
    padding: 0.75rem 1rem 0.85rem;
  }

  .brand {
    align-items: center;
    text-align: center;
    width: 100%;
  }

  .brand-lockup {
    justify-content: center;
  }

  .brand-mark {
    font-size: 1.55rem;
  }

  .brand-sub {
    font-size: 0.78rem;
    letter-spacing: 0.12em;
  }

  .brand-stand {
    display: none;
  }

  .header-tools {
    flex: 0 0 auto;
    width: 100%;
    min-width: 0;
    justify-content: center;
    gap: 0;
  }

  .tax-filters {
    display: none;
  }

  .search-form {
    flex: 0 1 auto;
    width: min(100%, 22rem);
    max-width: 22rem;
    margin-inline: auto;
    gap: 0.4rem;
  }

  .search-form input {
    min-width: 0;
    padding: 0.5rem 0.85rem;
    font-size: 0.92rem;
  }

  .search-form button {
    width: 2.45rem;
    height: 2.45rem;
    padding: 0;
    border-radius: 999px;
  }

  .search-btn-label {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
  }

  .search-form button::before {
    content: "";
    width: 1rem;
    height: 1rem;
    background: no-repeat center / contain
      url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23f7faf6' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='M20 20l-3.5-3.5'/%3E%3C/svg%3E");
  }

  .app {
    width: min(1180px, calc(100% - 1.25rem));
    padding: 1rem 0 2.5rem;
  }

  .hero-home {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .hero-home-copy {
    max-width: none;
    justify-items: center;
    text-align: center;
  }

  .hero h1 {
    font-size: clamp(1.85rem, 8vw, 2.5rem);
  }

  .hero-lead {
    max-width: 36rem;
    margin-inline: auto;
  }

  .hero-actions {
    justify-content: center;
  }

  .hero-iucn-filter,
  .hero-filters,
  .hero-geo-filter,
  .hero-care-filter {
    justify-self: stretch;
    width: 100%;
    min-width: 0;
    max-width: 100%;
    box-sizing: border-box;
  }

  .hero-iucn-filter {
    text-align: center;
    overflow: hidden;
  }

  .hero-iucn-filter .field-label,
  .hero-geo-filter .field-label,
  .hero-care-filter .field-label {
    display: block;
    text-align: center;
  }

  .hero-iucn-filter .iucn-row {
    width: 100%;
    flex-wrap: nowrap;
    justify-content: stretch;
    min-width: 0;
  }

  .hero-iucn-filter .iucn-scale {
    display: flex;
    width: 100%;
    max-width: 100%;
    min-width: 0;
    justify-content: space-between;
    align-items: center;
    gap: clamp(0.2rem, 2vw, 0.55rem);
    box-sizing: border-box;
  }

  .hero-iucn-filter .iucn-dot,
  .hero-iucn-filter .iucn-dot-btn {
    flex: 1 1 0;
    width: auto;
    height: auto;
    aspect-ratio: 1;
    min-width: 0;
    max-width: clamp(1.1rem, 7vw, 1.65rem);
    opacity: 0.45;
  }

  .hero-iucn-filter .iucn-dot-btn.is-active,
  .hero-iucn-filter .iucn-dot.is-active {
    opacity: 1;
    transform: scale(1.18);
  }

  .hero-iucn-filter .iucn-filter-caption {
    justify-content: center;
    text-align: center;
  }

  .hero-geo-filter {
    text-align: center;
  }

  .hero-care-filter {
    text-align: center;
  }

  .geo-split {
    grid-template-columns: 1fr;
    justify-items: center;
  }

  .geo-chip-row {
    max-width: 100%;
    justify-content: center;
  }

  .hero-geo-filter .geo-chip-row,
  .hero-care-filter .care-chip-row {
    justify-content: center;
  }

  .geo-country-label {
    justify-self: center;
  }

  .geo-country-picker {
    justify-self: center;
  }

  .hero-care-filter .geo-filter-caption {
    text-align: center;
  }

  .filter-bar,
  .geo-chip-row,
  .care-chip-row {
    flex-wrap: wrap;
    overflow-x: visible;
    -webkit-overflow-scrolling: auto;
    scrollbar-width: auto;
    padding-bottom: 0;
    margin-inline: 0;
    padding-inline: 0;
  }

  .filter-chip,
  .geo-chip {
    flex: 0 0 auto;
  }

  .gallery {
    grid-template-columns: repeat(auto-fill, minmax(148px, 1fr));
    gap: 0.75rem;
  }

  .site-footer {
    padding-inline: 1rem;
    font-size: 0.88rem;
  }
}

.hero h1 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(2.35rem, 5.5vw, 3.6rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.05;
  color: var(--moss-deep);
}

.hero-lead {
  margin: 0;
  max-width: 36rem;
  color: var(--ink-soft);
  font-size: clamp(1.02rem, 2.2vw, 1.18rem);
  line-height: 1.55;
}

.hero-kicker {
  margin: 0;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--amber);
}

.hero-latin {
  margin: -0.35rem 0 0;
  font-size: 1.15rem;
  font-style: italic;
  color: var(--ink-soft);
}

.hero-taxon .taxon-extract {
  margin: 0.15rem 0 0;
  max-width: 40rem;
  color: var(--ink-soft);
  font-size: 1.02rem;
  line-height: 1.55;
}

.taxon-inline-link {
  color: var(--moss-deep);
  font-weight: 600;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.15em;
  text-decoration-color: rgba(47, 93, 69, 0.35);
}

.taxon-inline-link:hover {
  color: var(--moss);
  text-decoration-color: rgba(47, 93, 69, 0.7);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-top: 0.2rem;
}

.gallery-single {
  max-width: 280px;
}

.meta-line {
  color: var(--ink-soft);
  font-size: 0.95rem;
}

.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 1rem;
}

.tile {
  display: flex;
  flex-direction: column;
  text-decoration: none;
  color: inherit;
  border-radius: var(--radius);
  overflow: hidden;
  background: rgba(255, 255, 255, 0.55);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  animation: rise 0.55s ease both;
}

.tile:nth-child(2) { animation-delay: 0.04s; }
.tile:nth-child(3) { animation-delay: 0.08s; }
.tile:nth-child(4) { animation-delay: 0.12s; }
.tile:nth-child(5) { animation-delay: 0.16s; }
.tile:nth-child(6) { animation-delay: 0.2s; }

.tile:hover {
  transform: translateY(-4px);
  box-shadow: 0 22px 44px rgba(20, 35, 28, 0.16);
}

.tile-media {
  aspect-ratio: 4 / 3;
  background:
    linear-gradient(135deg, rgba(47, 93, 69, 0.18), rgba(196, 92, 38, 0.12)),
    var(--paper-2);
  overflow: hidden;
}

.tile-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.35s ease;
}

.no-image-thumb {
  width: 100%;
  height: 100%;
  min-height: 100%;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 0.55rem;
  background:
    radial-gradient(circle at 50% 40%, rgba(255, 255, 255, 0.08), transparent 55%),
    linear-gradient(160deg, #3a1616 0%, #1f1010 100%);
  color: #f7ecec;
}

.stop-sign {
  width: 4.4rem;
  height: 4.4rem;
  display: grid;
  place-items: center;
  background: #d5242a;
  clip-path: polygon(
    30% 0%,
    70% 0%,
    100% 30%,
    100% 70%,
    70% 100%,
    30% 100%,
    0% 70%,
    0% 30%
  );
  box-shadow: inset 0 0 0 4px #f4f4f4;
}

.stop-sign-bar {
  width: 58%;
  height: 0.55rem;
  border-radius: 999px;
  background: #f4f4f4;
}

.no-image-label {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #f0c9c9;
}

.no-image-thumb--detail {
  min-height: 240px;
}

.no-image-thumb--detail .stop-sign {
  width: 5.5rem;
  height: 5.5rem;
}

.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-top: 0.15rem;
}

.filter-chip {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.55);
  color: var(--moss-deep);
  border-radius: 999px;
  padding: 0.4rem 0.85rem;
  font: inherit;
  font-weight: 600;
  font-size: 0.92rem;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.filter-chip:hover {
  background: rgba(47, 93, 69, 0.08);
}

.filter-chip.is-active {
  background: var(--moss);
  border-color: var(--moss);
  color: #f7faf6;
}

.tile:hover .tile-media img {
  transform: scale(1.04);
}

.tile-body {
  padding: 0.85rem 0.95rem 1rem;
  display: grid;
  gap: 0.2rem;
}

.tile-de {
  font-weight: 700;
  font-size: 1.02rem;
  line-height: 1.25;
  hyphens: auto;
  -webkit-hyphens: auto;
  overflow-wrap: break-word;
  word-break: normal;
}

.tile-la {
  font-style: italic;
  color: var(--ink-soft);
  font-size: 0.92rem;
}

.section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  justify-content: space-between;
  gap: 0.75rem;
  margin: 0 0 1rem;
}

.section-head h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 3vw, 2rem);
}

.gallery-sentinel {
  height: 1px;
  margin: 1.5rem 0 0.5rem;
}

.detail {
  display: grid;
  gap: 1.5rem;
  animation: rise 0.45s ease both;
}

@media (min-width: 860px) {
  .detail {
    grid-template-columns: minmax(280px, 0.95fr) 1.2fr;
    align-items: start;
  }
}

.detail-media {
  border-radius: calc(var(--radius) + 4px);
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--paper-2);
  box-shadow: var(--shadow);
  min-height: 240px;
}

.detail-media img {
  width: 100%;
  height: 100%;
  max-height: 460px;
  object-fit: cover;
  display: block;
}

.range-map {
  margin-top: 1rem;
}

.range-map-media {
  margin-top: 0.35rem;
  border-radius: calc(var(--radius) + 2px);
  overflow: hidden;
  border: 1px solid var(--line);
  background: #fff;
}

.range-map-media img {
  width: 100%;
  height: auto;
  max-height: 280px;
  object-fit: contain;
  display: block;
  background: #f7faf6;
}

.range-map-media--empty {
  min-height: 120px;
  display: grid;
  place-items: center;
  padding: 1rem;
  background:
    linear-gradient(135deg, rgba(47, 93, 69, 0.06), rgba(196, 92, 38, 0.05)),
    #f7faf6;
}

.range-map-media--empty .meta-line {
  margin: 0;
}

.detail-panel h1 {
  margin: 0 0 0.25rem;
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 3.5vw, 2.6rem);
  letter-spacing: -0.03em;
  line-height: 1.15;
}

.name-editor {
  margin: 0 0 1.15rem;
}

.field-label {
  display: block;
  margin: 0 0 0.35rem;
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--amber);
  font-weight: 700;
}

.name-input {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.72);
  padding: 0.7rem 0.9rem;
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 3vw, 2.2rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--ink);
  margin-bottom: 0.35rem;
}

.name-input:focus,
.alias-input:focus {
  outline: 2px solid rgba(47, 93, 69, 0.35);
  outline-offset: 1px;
}

.detail-latin {
  margin: 0 0 1rem;
  font-style: italic;
  color: var(--ink-soft);
  font-size: 1.1rem;
}

.alias-box {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem;
  min-height: 2.7rem;
  padding: 0.45rem 0.55rem;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.72);
}

.alias-list {
  display: contents;
}

.alias-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  border: 0;
  border-radius: 999px;
  background: rgba(47, 93, 69, 0.12);
  color: var(--moss-deep);
  font: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  padding: 0.28rem 0.55rem 0.28rem 0.7rem;
  cursor: pointer;
}

.alias-chip:hover {
  background: rgba(213, 36, 42, 0.12);
  color: #8a1d22;
}

.alias-chip-x {
  font-size: 1.05rem;
  line-height: 1;
  opacity: 0.7;
}

.alias-input {
  flex: 1 1 140px;
  min-width: 140px;
  border: 0;
  background: transparent;
  padding: 0.35rem 0.25rem;
  font: inherit;
  color: inherit;
}

.alias-input:focus {
  outline: none;
}

.alias-empty {
  color: var(--ink-soft);
  font-size: 0.92rem;
  padding: 0.15rem 0.2rem;
}

.field-hint {
  margin: 0.4rem 0 0;
  color: var(--ink-soft);
  font-size: 0.86rem;
}

#name-save-hint {
  color: var(--moss);
  font-weight: 700;
}

.ext-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin: 0 0 0.85rem;
}

.iucn-status {
  margin: 0 0 1.25rem;
  padding: 0.75rem 0.9rem;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.55);
}

.iucn-status--empty {
  opacity: 0.85;
}

.iucn-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem 1rem;
}

.iucn-scale {
  display: inline-flex;
  align-items: center;
  gap: 0.28rem;
  padding: 0.2rem 0.15rem;
}

.iucn-dot {
  width: 0.72rem;
  height: 0.72rem;
  border-radius: 50%;
  background: #c8c8c8;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.12);
  opacity: 0.45;
  transition: transform 0.15s ease, opacity 0.15s ease;
}

.iucn-dot--ex { background: #000; }
.iucn-dot--ew { background: #542344; }
.iucn-dot--cr { background: #d81e05; }
.iucn-dot--en { background: #fc7f3f; }
.iucn-dot--vu { background: #f9e814; }
.iucn-dot--nt { background: #cce226; }
.iucn-dot--lc { background: #60c659; }

.iucn-dot.is-active {
  opacity: 1;
  transform: scale(1.35);
  box-shadow:
    0 0 0 2px #fff,
    0 0 0 3px rgba(0, 0, 0, 0.25);
}

.iucn-text {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.4rem 0.55rem;
}

.iucn-code {
  font-size: 0.85rem;
  letter-spacing: 0.06em;
  padding: 0.15rem 0.45rem;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.06);
}

.iucn-code--lc { background: rgba(96, 198, 89, 0.22); color: #1f6b28; }
.iucn-code--nt { background: rgba(204, 226, 38, 0.28); color: #5a6b10; }
.iucn-code--vu { background: rgba(249, 232, 20, 0.35); color: #6b5b00; }
.iucn-code--en { background: rgba(252, 127, 63, 0.25); color: #9a3d10; }
.iucn-code--cr { background: rgba(216, 30, 5, 0.18); color: #9a1408; }
.iucn-code--ew,
.iucn-code--ex { background: rgba(0, 0, 0, 0.12); color: #222; }

.iucn-label {
  font-weight: 600;
  color: var(--ink);
}

.iucn-details {
  display: grid;
  gap: 0.55rem;
  margin-top: 0.75rem;
  padding-top: 0.7rem;
  border-top: 1px solid var(--line);
}

.iucn-detail {
  display: grid;
  gap: 0.15rem;
  font-size: 0.95rem;
  line-height: 1.45;
  color: var(--ink-soft);
}

.iucn-detail-label {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--moss-deep);
}

.pill-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  text-decoration: none;
  color: var(--moss-deep);
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.65);
  border-radius: 999px;
  padding: 0.4rem 0.8rem;
  font-weight: 600;
  font-size: 0.92rem;
}

.wiki-w {
  display: inline-grid;
  place-items: center;
  width: 1.35rem;
  height: 1.35rem;
  border-radius: 50%;
  background: #111;
  color: #fff;
  font-family: Georgia, serif;
  font-weight: 700;
  font-size: 0.85rem;
}

.block {
  margin-bottom: 1.15rem;
}

.block h2 {
  margin: 0 0 0.45rem;
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--amber);
}

.tax-path {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.25rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.tax-path li {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
}

.tax-path li:not(:last-child)::after {
  content: "›";
  margin-left: 0.25rem;
  color: var(--ink-soft);
}

.tax-chip {
  background: rgba(47, 93, 69, 0.08);
  border-radius: 999px;
  padding: 0.2rem 0.55rem;
  font-size: 0.92rem;
}

a.tax-chip-link {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  text-decoration: none;
  color: var(--moss-deep);
  font-weight: 600;
  transition: background 0.15s ease, transform 0.15s ease;
}

a.tax-chip-link:hover {
  background: rgba(47, 93, 69, 0.16);
  transform: translateY(-1px);
}

.tax-count {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--ink-soft);
  background: rgba(255, 255, 255, 0.7);
  border-radius: 999px;
  padding: 0.05rem 0.4rem;
  min-width: 1.2rem;
  text-align: center;
}

.protect-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.55rem;
}

.protect-list li {
  padding: 0.7rem 0.85rem;
  border-left: 3px solid var(--moss);
  background: rgba(255, 255, 255, 0.55);
  border-radius: 0 10px 10px 0;
}

.protect-list strong {
  display: block;
  margin-bottom: 0.15rem;
}

.protect-meta {
  color: var(--ink-soft);
  font-size: 0.92rem;
}

.extract {
  margin: 0;
  color: var(--ink-soft);
  max-width: 60ch;
}

.species-note {
  margin: 0;
  padding: 0.75rem 0.9rem;
  border-left: 3px solid var(--amber);
  background: rgba(196, 92, 38, 0.08);
  border-radius: 0 10px 10px 0;
  color: var(--ink-soft);
  max-width: 62ch;
}

.note-block h2 {
  color: var(--amber);
}

.image-credit {
  margin: 0.55rem 0 0;
  font-size: 0.8rem;
  color: var(--ink-soft);
}

.site-footer {
  width: min(1180px, calc(100% - 2rem));
  margin: 0 auto 2rem;
  padding-top: 1rem;
  border-top: 1px solid var(--line);
  color: var(--ink-soft);
  font-size: 0.88rem;
}

.site-footer p {
  margin: 0 0 0.45rem;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.55rem;
  align-items: center;
}

.footer-login-wrap {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem 0.55rem;
}

.footer-login {
  color: inherit;
  opacity: 0.55;
  font-size: 0.82rem;
  text-decoration: none;
}

.footer-login:hover,
.footer-login:focus-visible {
  opacity: 0.9;
  text-decoration: underline;
}

body.is-admin .footer-login-wrap {
  display: none;
}

.about {
  max-width: 42rem;
  display: grid;
  gap: 1.5rem;
  animation: rise 0.45s ease both;
}

.about-header {
  display: grid;
  gap: 0.75rem;
}

.about-header h1 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(2rem, 4.5vw, 3rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.1;
  color: var(--moss-deep);
}

.about-block {
  display: grid;
  gap: 0.65rem;
}

.about-block h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.25rem;
  color: var(--moss-deep);
}

.about-block p,
.about-list {
  margin: 0;
  color: var(--ink-soft);
  line-height: 1.55;
}

.about-list {
  padding-left: 1.2rem;
  display: grid;
  gap: 0.75rem;
}

.about-list li::marker {
  color: var(--amber);
}

.about-cite {
  margin: 0;
  padding: 0.9rem 1rem;
  border-left: 3px solid var(--moss);
  background: rgba(255, 255, 255, 0.55);
  color: var(--ink);
  line-height: 1.5;
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.detail-german {
  margin: 0 0 0.35rem;
  font-family: var(--font-display);
  font-size: clamp(1.55rem, 3.2vw, 2.25rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.15;
}

.name-missing {
  color: var(--ink-soft);
  font-weight: 600;
  font-style: italic;
}

.curated-badge {
  display: inline-block;
  margin: 0 0 0.85rem;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--moss-deep);
  background: rgba(47, 93, 69, 0.12);
  border-radius: 999px;
  padding: 0.28rem 0.65rem;
}

.alias-box--readonly {
  margin-bottom: 0.85rem;
}

.alias-chip--static {
  cursor: default;
  padding: 0.28rem 0.7rem;
}

.alias-chip--static:hover {
  background: rgba(47, 93, 69, 0.12);
  color: var(--moss-deep);
}

.detail-care {
  margin: 0 0 1.1rem;
}

.btn-report,
.btn-primary,
.btn-ghost {
  font: inherit;
  cursor: pointer;
}

.btn-report {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.7);
  color: var(--moss-deep);
  font-weight: 700;
  border-radius: 999px;
  padding: 0.55rem 1rem;
}

.btn-report:hover {
  background: rgba(196, 92, 38, 0.1);
  border-color: rgba(196, 92, 38, 0.35);
  color: #8a3d16;
}

.btn-primary {
  border: 0;
  border-radius: 999px;
  padding: 0.55rem 1.15rem;
  background: var(--moss);
  color: #fff;
  font-weight: 700;
}

.btn-primary:disabled {
  opacity: 0.55;
  cursor: wait;
}

.btn-ghost {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.55rem 1.05rem;
  background: transparent;
  color: var(--ink-soft);
  font-weight: 600;
}

body.modal-open {
  overflow: hidden;
}

#report-modal-root {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: grid;
  place-items: center;
  padding: 1rem;
}

#report-modal-root[hidden] {
  display: none !important;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(20, 32, 26, 0.48);
}

.modal-sheet {
  position: relative;
  z-index: 1;
  width: min(34rem, 100%);
  max-height: min(90vh, 40rem);
  overflow: auto;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(243, 246, 242, 0.96)),
    var(--paper);
  border: 1px solid var(--line);
  border-radius: 18px;
  box-shadow: var(--shadow);
  padding: 1.15rem 1.2rem 1.25rem;
  animation: rise 0.28s ease both;
}

.modal-head {
  display: flex;
  justify-content: space-between;
  gap: 0.8rem;
  align-items: start;
  margin-bottom: 0.85rem;
}

.modal-head h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.55rem;
  letter-spacing: -0.03em;
}

.modal-species {
  margin: 0.25rem 0 0;
  color: var(--ink-soft);
}

.modal-close {
  border: 0;
  background: transparent;
  font-size: 1.6rem;
  line-height: 1;
  color: var(--ink-soft);
  cursor: pointer;
  padding: 0.1rem 0.35rem;
}

.report-form fieldset {
  border: 0;
  margin: 0 0 0.85rem;
  padding: 0;
}

.report-form legend {
  font-size: 0.78rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--amber);
  font-weight: 700;
  margin-bottom: 0.45rem;
}

.report-cats {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.report-cat {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.35rem 0.7rem;
  background: rgba(255, 255, 255, 0.65);
  cursor: pointer;
  font-size: 0.92rem;
  font-weight: 600;
}

.report-cat:has(input:checked) {
  background: rgba(47, 93, 69, 0.14);
  border-color: transparent;
  color: var(--moss-deep);
}

.report-cat input {
  accent-color: var(--moss);
}

.report-form textarea,
.report-form input[type="email"] {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.78);
  padding: 0.7rem 0.85rem;
  font: inherit;
  color: inherit;
  margin: 0 0 0.75rem;
  resize: vertical;
}

.report-form textarea:focus,
.report-form input[type="email"]:focus {
  outline: 2px solid rgba(47, 93, 69, 0.35);
  outline-offset: 1px;
}

.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.5rem;
  margin-top: 0.35rem;
}

.form-error {
  color: #8a1d22;
  margin: 0 0 0.65rem;
}

.form-success {
  color: var(--moss-deep);
  font-weight: 700;
  margin: 0 0 0.65rem;
}

/* Admin chrome in main header */
.admin-chrome {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  margin-left: 0.15rem;
}

.admin-chrome[hidden] {
  display: none !important;
}

.bell-btn {
  position: relative;
  display: inline-grid;
  place-items: center;
  width: 2.45rem;
  height: 2.45rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.72);
  color: var(--moss-deep);
  text-decoration: none;
}

.bell-btn:hover,
.bell-btn:focus-visible {
  background: rgba(196, 92, 38, 0.12);
  color: #8a3d16;
  outline: none;
}

.bell-count {
  position: absolute;
  top: -0.2rem;
  right: -0.2rem;
  min-width: 1.15rem;
  height: 1.15rem;
  padding: 0 0.3rem;
  border-radius: 999px;
  background: var(--amber);
  color: #fff;
  font-size: 0.68rem;
  font-weight: 700;
  line-height: 1.15rem;
  text-align: center;
}

.admin-logout {
  border: 1px solid var(--line);
  background: transparent;
  border-radius: 999px;
  padding: 0.4rem 0.75rem;
  font: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--ink-soft);
  cursor: pointer;
}

.admin-logout:hover {
  color: var(--moss-deep);
}

body.is-admin .site-header {
  box-shadow: inset 0 -2px 0 rgba(47, 93, 69, 0.18);
}

.admin-bird-form .name-input {
  margin-bottom: 0.2rem;
}

.admin-bird-form textarea,
.admin-bird-form input[type="url"],
.admin-bird-form input[type="text"]:not(.name-input):not(.alias-input) {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.72);
  padding: 0.55rem 0.75rem;
  font: inherit;
  margin-bottom: 0.35rem;
}

.admin-edit-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.9rem 1.1rem;
  margin-top: 0.5rem;
}

@media (max-width: 720px) {
  .admin-edit-grid {
    grid-template-columns: 1fr;
  }
}

.admin-image-preview {
  aspect-ratio: 4 / 3;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: rgba(30, 61, 45, 0.06);
  display: grid;
  place-items: center;
  margin-bottom: 0.45rem;
}

.admin-image-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.preview-empty {
  color: var(--ink-soft);
  font-size: 0.88rem;
}

.check-line {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  margin: 0.45rem 0 0.2rem;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--ink-soft);
}

.admin-edit-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
  margin-top: 0.85rem;
}

.pflege-inbox {
  max-width: 820px;
  margin: 0 auto;
  animation: rise 0.35s ease both;
}

.pflege-head {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem 1.2rem;
  justify-content: space-between;
  align-items: end;
  margin-bottom: 0.5rem;
}

.pflege-inbox .filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

.pflege-inbox .chip {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.7);
  border-radius: 999px;
  padding: 0.35rem 0.75rem;
  color: var(--ink-soft);
  font: inherit;
  font-size: 0.9rem;
  cursor: pointer;
}

.pflege-inbox .chip.is-active {
  background: rgba(47, 93, 69, 0.14);
  color: var(--moss-deep);
  border-color: transparent;
  font-weight: 700;
}

.report-list {
  display: grid;
  gap: 0.85rem;
  margin-top: 0.75rem;
}

.report-card {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 0.95rem 1.05rem;
  background: rgba(255, 255, 255, 0.62);
}

.report-card h2 {
  margin: 0 0 0.2rem;
  font-family: var(--font-display);
  font-size: 1.2rem;
}

.report-card h2 a {
  color: inherit;
  text-decoration: none;
}

.report-card h2 a:hover {
  color: var(--moss);
}

.report-card .latin {
  margin: 0 0 0.5rem;
  font-style: italic;
  color: var(--ink-soft);
}

.report-card .cats {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
  margin: 0 0 0.5rem;
}

.report-card .cat {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 0.2rem 0.5rem;
  border-radius: 6px;
  background: rgba(196, 92, 38, 0.12);
  color: #8a3d16;
}

.report-card p {
  margin: 0 0 0.55rem;
  white-space: pre-wrap;
}

.report-meta {
  font-size: 0.85rem;
  color: var(--ink-soft);
}

.report-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  align-items: center;
}

.report-actions button,
.report-actions .btn-primary {
  border: 0;
  border-radius: 999px;
  padding: 0.45rem 0.95rem;
  background: var(--moss);
  color: #fff;
  font: inherit;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
}

.report-actions .btn-reject {
  background: #8a1d22;
}

.pflege-inbox .empty {
  color: var(--ink-soft);
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}
