/* Treefinder – ruhige, grosszügige Oberfläche in Apple-Grammatik:
   durchscheinende Leisten, Haarlinien, weiche Tiefe, ein einziger Akzent.
   Das Botanische kommt aus der Palette, nicht aus Dekoration. */

:root {
  /* Flächen: warmes Papier mit Grünstich statt Neutralgrau */
  --bg: #f6f8f4;
  --surface: #ffffff;
  --surface-2: #f2f5ef;
  --veil: rgba(255, 255, 255, .72);

  /* Schrift */
  --ink: #171c18;
  --ink-2: #5d6a60;
  --ink-3: #8d978f;

  --hairline: rgba(23, 28, 24, .09);
  --hairline-2: rgba(23, 28, 24, .055);

  /* Akzent: gedecktes Waldgrün */
  --accent: #2c6a49;
  --accent-2: #3d8a5f;
  --on-accent: #ffffff;
  --tint: rgba(44, 106, 73, .1);
  --tint-2: rgba(44, 106, 73, .16);

  --warn: #9c5c0b;
  --warn-tint: rgba(156, 92, 11, .11);
  --danger: #a8291d;
  --danger-tint: rgba(168, 41, 29, .1);

  --r-card: 22px;
  --r-ctl: 14px;
  --r-inner: 14px;

  --lift: 0 1px 2px rgba(23, 40, 28, .04), 0 6px 18px -6px rgba(23, 40, 28, .1);
  --lift-2: 0 2px 6px rgba(23, 40, 28, .05), 0 18px 42px -16px rgba(23, 40, 28, .16);

  --gap: 20px;
  --tabbar: 58px;

  /* Icons (SF-Symbols-artig, als Maske → folgen currentColor) */
  --i-camera: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 8.5A2.5 2.5 0 0 1 5.5 6h1.2a2 2 0 0 0 1.7-.95l.5-.8A2 2 0 0 1 10.6 3h2.8a2 2 0 0 1 1.7.95l.5.8A2 2 0 0 0 17.3 6h1.2A2.5 2.5 0 0 1 21 8.5v9A2.5 2.5 0 0 1 18.5 20h-13A2.5 2.5 0 0 1 3 17.5z'/%3E%3Ccircle cx='12' cy='13' r='3.6'/%3E%3C/svg%3E");
  --i-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='4.5' width='18' height='15' rx='3'/%3E%3Ccircle cx='8.6' cy='10' r='1.6'/%3E%3Cpath d='M3.6 17.4l4.3-4.1a2 2 0 0 1 2.7-.06l3 2.7a2 2 0 0 0 2.7-.03l2.2-2.05a2 2 0 0 1 2.6-.04'/%3E%3C/svg%3E");
  --i-scan: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 8.5V6a3 3 0 0 1 3-3h2.5M21 8.5V6a3 3 0 0 0-3-3h-2.5M3 15.5V18a3 3 0 0 0 3 3h2.5M21 15.5V18a3 3 0 0 1-3 3h-2.5'/%3E%3Cpath d='M12 8.2c0 2.4 1.7 4.2 4.1 4.6-.4-2.6-1.8-4.2-4.1-4.6z'/%3E%3Cpath d='M12 15.8V10'/%3E%3Cpath d='M11.9 11.6c-.2-2-1.6-3.4-3.6-3.8.3 2.2 1.5 3.5 3.6 3.8z'/%3E%3C/svg%3E");
  --i-leaf: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 19c-1.5-7 2.5-13.5 14.5-14.5C20.5 16 14.5 20.5 7 18.5'/%3E%3Cpath d='M5.5 19.5C8 14 12 10.5 17.5 8.5'/%3E%3C/svg%3E");
  --i-info: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='9'/%3E%3Cpath d='M12 11v5.5'/%3E%3Cpath d='M12 7.6h.01'/%3E%3C/svg%3E");
  --i-back: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M14.5 5.5L8 12l6.5 6.5'/%3E%3C/svg%3E");
  --i-close: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2.2' stroke-linecap='round'%3E%3Cpath d='M6.5 6.5l11 11M17.5 6.5l-11 11'/%3E%3C/svg%3E");
  --i-pencil: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 20h4L20 8a2.4 2.4 0 0 0-3.4-3.4L4.5 16.7z'/%3E%3Cpath d='M15 6.2L18.3 9.5'/%3E%3C/svg%3E");
  --i-share: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 3.5v11'/%3E%3Cpath d='M8.3 7.2L12 3.5l3.7 3.7'/%3E%3Cpath d='M6 12.5H5.5A1.5 1.5 0 0 0 4 14v5A1.5 1.5 0 0 0 5.5 20.5h13A1.5 1.5 0 0 0 20 19v-5a1.5 1.5 0 0 0-1.5-1.5H18'/%3E%3C/svg%3E");
  --i-trash: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4.5 7h15'/%3E%3Cpath d='M9.5 7V5.2A1.2 1.2 0 0 1 10.7 4h2.6a1.2 1.2 0 0 1 1.2 1.2V7'/%3E%3Cpath d='M6.5 7l.8 11.3A2 2 0 0 0 9.3 20h5.4a2 2 0 0 0 2-1.7L17.5 7'/%3E%3Cpath d='M10.5 11v5M13.5 11v5'/%3E%3C/svg%3E");
  --i-check: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.8l4.2 4.2L19 7.2'/%3E%3C/svg%3E");
  --i-alert: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M10.3 3.9a2 2 0 0 1 3.4 0l7.1 12.4A2 2 0 0 1 19.1 19.4H4.9a2 2 0 0 1-1.7-3.1z'/%3E%3Cpath d='M12 9v4'/%3E%3Cpath d='M12 16.2h.01'/%3E%3C/svg%3E");
  --i-plus: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M12 5.5v13M5.5 12h13'/%3E%3C/svg%3E");
  --i-search: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.9' stroke-linecap='round'%3E%3Ccircle cx='10.8' cy='10.8' r='6.3'/%3E%3Cpath d='M15.5 15.5L20 20'/%3E%3C/svg%3E");
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0c0f0d;
    --surface: #161a17;
    --surface-2: #1d231f;
    --veil: rgba(18, 22, 19, .72);

    --ink: #edf1ea;
    --ink-2: #9ca99f;
    --ink-3: #78857b;

    --hairline: rgba(255, 255, 255, .1);
    --hairline-2: rgba(255, 255, 255, .06);

    --accent: #67c38a;
    --accent-2: #8ad5a7;
    --on-accent: #06180e;
    --tint: rgba(103, 195, 138, .14);
    --tint-2: rgba(103, 195, 138, .22);

    --warn: #e0a85e;
    --warn-tint: rgba(224, 168, 94, .14);
    --danger: #f08878;
    --danger-tint: rgba(240, 136, 120, .14);

    --lift: 0 1px 2px rgba(0, 0, 0, .4), 0 6px 18px -6px rgba(0, 0, 0, .5);
    --lift-2: 0 2px 8px rgba(0, 0, 0, .45), 0 20px 46px -16px rgba(0, 0, 0, .6);
  }
}

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

/* Muss vor allen display-Regeln stehen: sonst überschreiben .btn/.shots & Co.
   das hidden-Attribut und verborgene Elemente erscheinen trotzdem. */
[hidden] { display: none !important; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, system-ui, sans-serif;
  font-size: 17px;
  line-height: 1.47;
  letter-spacing: -.01em;
  -webkit-font-smoothing: antialiased;
  overscroll-behavior-y: none;
}

/* Ein weicher Lichtschein von oben – reicht als Naturbezug, ohne Deko */
body::before {
  content: "";
  position: fixed;
  inset: 0 0 auto;
  height: 420px;
  background: radial-gradient(120% 100% at 50% 0%, var(--tint) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}

h1, h2, h3 { margin: 0; font-weight: 650; letter-spacing: -.022em; line-height: 1.2; }
h1 { font-size: 19px; }
h2 { font-size: 27px; letter-spacing: -.028em; }
h3 { font-size: 17px; }
p { margin: 0; }
button { font-family: inherit; }

.muted { color: var(--ink-2); }
.small { font-size: 14px; letter-spacing: -.004em; }
.center { text-align: center; }
.stack > * + * { margin-top: 10px; }

/* ---------- Icons ---------- */
.ico {
  display: inline-block;
  width: 1.3em;
  height: 1.3em;
  flex: none;
  background: currentColor;
  -webkit-mask: var(--m) center / contain no-repeat;
  mask: var(--m) center / contain no-repeat;
}
.ico-camera { --m: var(--i-camera); }
.ico-image  { --m: var(--i-image); }
.ico-scan   { --m: var(--i-scan); }
.ico-leaf   { --m: var(--i-leaf); }
.ico-info   { --m: var(--i-info); }
.ico-back   { --m: var(--i-back); }
.ico-close  { --m: var(--i-close); }
.ico-pencil { --m: var(--i-pencil); }
.ico-share  { --m: var(--i-share); }
.ico-trash  { --m: var(--i-trash); }
.ico-check  { --m: var(--i-check); }
.ico-alert  { --m: var(--i-alert); }
.ico-plus   { --m: var(--i-plus); }

/* ---------- Kopfleiste ---------- */
.top {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: calc(env(safe-area-inset-top) + 11px) var(--gap) 11px;
  background: var(--veil);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--hairline-2);
}

.brand {
  display: flex;
  align-items: center;
  gap: 11px;
  min-width: 0;
  padding: 4px 8px 4px 4px;
  margin: -4px -8px -4px -4px;
  border: 0;
  border-radius: 13px;
  background: none;
  color: inherit;
  text-align: left;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: background-color .18s ease, transform .12s ease;
}
.brand:hover { background: var(--tint); }
.brand:active { transform: scale(.975); }
.brand:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

.mark {
  width: 36px;
  height: 36px;
  flex: none;
  display: grid;
  place-items: center;
  border-radius: 11px;
  background: linear-gradient(160deg, var(--accent-2), var(--accent));
  box-shadow: 0 2px 8px -2px rgba(44, 106, 73, .5);
}
.mark svg { width: 22px; height: 22px; fill: none; stroke: var(--on-accent); stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.brand .tagline { font-size: 12.5px; color: var(--ink-3); letter-spacing: 0; }

.chip {
  flex: none;
  max-width: 44vw;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 13.5px;
  font-weight: 550;
  letter-spacing: -.005em;
  color: var(--accent);
  background: var(--tint);
  border: 0;
  border-radius: 999px;
  padding: 7px 13px;
  cursor: pointer;
  transition: background-color .18s ease;
}
.chip:hover { background: var(--tint-2); }

/* ---------- Gerüst ---------- */
main {
  position: relative;
  z-index: 1;
  max-width: 660px;
  margin: 0 auto;
  padding: var(--gap) var(--gap) calc(env(safe-area-inset-bottom) + var(--tabbar) + 32px);
}

.card {
  background: var(--surface);
  border-radius: var(--r-card);
  padding: 22px;
  margin-bottom: 16px;
  box-shadow: var(--lift);
}
@media (prefers-color-scheme: dark) { .card { border: 1px solid var(--hairline-2); } }

.hero { padding-bottom: 20px; }
.hero h2 { margin-bottom: 8px; }
.hero > p { color: var(--ink-2); font-size: 16px; }
.hints {
  list-style: none;
  margin: 16px 0 0;
  padding: 0;
  display: grid;
  gap: 1px;
  background: var(--hairline-2);
  border-radius: var(--r-inner);
  overflow: hidden;
}
.hints li {
  background: var(--surface-2);
  padding: 11px 14px;
  font-size: 15px;
  color: var(--ink-2);
}
.hints strong { color: var(--ink); font-weight: 600; }

/* ---------- Knöpfe ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  width: 100%;
  min-height: 50px;
  padding: 13px 18px;
  border: 0;
  border-radius: var(--r-ctl);
  font-size: 17px;
  font-weight: 590;
  letter-spacing: -.012em;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: transform .12s ease, background-color .18s ease, opacity .18s ease;
}
.btn:active { transform: scale(.977); }
.btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.btn.primary { background: var(--accent); color: var(--on-accent); box-shadow: 0 2px 10px -3px rgba(44, 106, 73, .45); }
.btn.primary:hover { background: var(--accent-2); }
.btn.ghost { background: var(--tint); color: var(--accent); }
.btn.ghost:hover { background: var(--tint-2); }
.btn.quiet { background: var(--surface-2); color: var(--ink-2); }
.btn.quiet:hover { color: var(--ink); }
.btn.danger { background: var(--danger-tint); color: var(--danger); }
.btn[disabled] { opacity: .45; cursor: default; transform: none; }
.btn + .btn { margin-top: 10px; }
/* In Rastern sorgt gap für den Abstand – sonst rutscht der zweite Knopf herunter. */
.pickers .btn + .btn, .actions .btn + .btn { margin-top: 0; }
.btn.back {
  width: auto;
  min-height: 0;
  gap: 4px;
  padding: 8px 14px 8px 10px;
  margin-bottom: 14px;
  font-size: 15px;
  background: var(--surface);
  color: var(--accent);
  box-shadow: var(--lift);
}

.pickers { display: grid; gap: 10px; }
#goWrap { margin-top: 20px; }
@media (min-width: 540px) { .pickers { grid-template-columns: 1fr 1fr; } }

.link {
  background: none;
  border: 0;
  padding: 0;
  font: inherit;
  font-weight: 550;
  color: var(--accent);
  cursor: pointer;
}
.link:hover { color: var(--accent-2); }
.foot { margin-top: 18px; font-size: 14.5px; color: var(--ink-3); }

/* ---------- Felder ---------- */
.field { display: block; margin: 14px 0 0; }
.field > span {
  display: block;
  margin-bottom: 6px;
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: .035em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.field input, .field select {
  width: 100%;
  padding: 13px 14px;
  font: inherit;
  font-size: 16.5px;
  color: var(--ink);
  background: var(--surface-2);
  border: 1px solid transparent;
  border-radius: var(--r-inner);
  transition: border-color .18s ease, background-color .18s ease;
}
.field input::placeholder { color: var(--ink-3); }
.field input:focus, .field select:focus {
  outline: none;
  background: var(--surface);
  border-color: var(--accent);
}
.field select { appearance: none; -webkit-appearance: none; padding-right: 36px; }

.search { position: relative; margin: 0; }
.search .ico {
  position: absolute;
  left: 13px;
  bottom: 15px;
  color: var(--ink-3);
  --m: var(--i-search);
  width: 19px;
  height: 19px;
}
.search input { padding-left: 42px; }

.toggle {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  margin: 16px 0 0;
  font-size: 15.5px;
  color: var(--ink-2);
  cursor: pointer;
}
.toggle input { flex: none; width: 20px; height: 20px; margin: 1px 0 0; accent-color: var(--accent); }

.grid2 { display: grid; gap: 0 16px; grid-template-columns: 1fr; }
@media (min-width: 540px) { .grid2 { grid-template-columns: 1fr 1fr; } }

/* ---------- Aufnahmen ---------- */
.shots { display: flex; flex-wrap: wrap; gap: 10px; margin: 18px 0 0; }
.shot {
  position: relative;
  width: 96px;
  height: 96px;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--lift);
  animation: pop .26s cubic-bezier(.2, .9, .3, 1.2);
}
.shot img { width: 100%; height: 100%; object-fit: cover; display: block; }
.shot button {
  position: absolute;
  top: 5px;
  right: 5px;
  display: grid;
  place-items: center;
  width: 25px;
  height: 25px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  color: #fff;
  background: rgba(10, 16, 12, .55);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  cursor: pointer;
}
.shot button .ico { width: 13px; height: 13px; }
@keyframes pop { from { opacity: 0; transform: scale(.88); } }

/* ---------- Laden ---------- */
.loading { text-align: center; padding: 34px 22px; }
.sprout { width: 46px; height: 46px; margin: 0 auto 18px; color: var(--accent); }
.sprout .ico { width: 46px; height: 46px; --m: var(--i-leaf); animation: breathe 2.4s ease-in-out infinite; }
@keyframes breathe {
  0%, 100% { opacity: .35; transform: scale(.92) rotate(-4deg); }
  50% { opacity: 1; transform: scale(1) rotate(2deg); }
}
.loading p { font-size: 16.5px; font-weight: 550; }
.loading .small { margin-top: 7px; font-weight: 400; color: var(--ink-3); }
@media (prefers-reduced-motion: reduce) { .sprout .ico { animation-duration: 6s; } .shot { animation: none; } }

/* ---------- Ergebnis ---------- */
.result { padding-top: 24px; }
.result-head { display: flex; align-items: center; gap: 18px; }

.conf {
  flex: none;
  width: 78px;
  height: 78px;
  display: grid;
  place-content: center;
  text-align: center;
  border-radius: 50%;
  background: conic-gradient(var(--accent) calc(var(--p, 0) * 1%), var(--tint) 0);
  position: relative;
}
.conf::before { content: ""; position: absolute; inset: 6px; border-radius: 50%; background: var(--surface); }
.conf > * { position: relative; }
.conf span {
  font-size: 22px;
  font-weight: 640;
  letter-spacing: -.03em;
  font-variant-numeric: tabular-nums;
  color: var(--accent);
}
.conf small { display: block; margin-top: -2px; font-size: 10.5px; font-weight: 580; letter-spacing: .04em; text-transform: uppercase; color: var(--ink-3); }
.conf.low { background: conic-gradient(var(--warn) calc(var(--p, 0) * 1%), var(--warn-tint) 0); }
.conf.low span { color: var(--warn); }

.names { min-width: 0; }
.names h2 { font-size: 25px; }
.sci { margin-top: 3px; font-style: italic; font-size: 16px; color: var(--ink-2); }
.names .small { margin-top: 4px; color: var(--ink-3); }
.lead { margin-top: 16px; font-size: 16.5px; color: var(--ink-2); }

.badges { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 16px; }
.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 6px 12px 6px 10px;
  border-radius: 999px;
  font-size: 13.5px;
  font-weight: 580;
  letter-spacing: -.005em;
  background: var(--tint);
  color: var(--accent);
}
.badge .ico { width: 15px; height: 15px; }
.badge.warn { background: var(--warn-tint); color: var(--warn); }
.badge.danger { background: var(--danger-tint); color: var(--danger); }
.badge.plain { background: var(--surface-2); color: var(--ink-2); padding-left: 12px; }

.sec { margin-top: 22px; padding-top: 20px; border-top: 1px solid var(--hairline-2); }
.sec h3 {
  margin-bottom: 12px;
  font-size: 12.5px;
  font-weight: 650;
  letter-spacing: .055em;
  text-transform: uppercase;
  color: var(--ink-3);
}

.chips { display: flex; flex-wrap: wrap; gap: 7px; }
.chips span {
  padding: 7px 13px;
  border-radius: 999px;
  font-size: 14.5px;
  color: var(--ink-2);
  background: var(--surface-2);
}

.kv { margin: 0; display: grid; gap: 1px; background: var(--hairline-2); border-radius: var(--r-inner); overflow: hidden; }
.kv dt {
  padding: 11px 14px 2px;
  background: var(--surface-2);
  font-size: 12.5px;
  font-weight: 620;
  letter-spacing: .035em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.kv dd { margin: 0; padding: 0 14px 12px; background: var(--surface-2); font-size: 16px; }

.alts { display: grid; gap: 10px; }
.alt { padding: 14px 16px; border-radius: var(--r-inner); background: var(--surface-2); }
.alt .row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.alt b { font-weight: 600; font-size: 16.5px; }
.alt .row span { font-variant-numeric: tabular-nums; color: var(--ink-3); font-weight: 560; }
.alt .sci { font-size: 14.5px; margin-top: 1px; }
.alt .small { margin-top: 6px; color: var(--ink-3); }
.bar { height: 4px; margin-top: 11px; border-radius: 2px; background: var(--hairline); overflow: hidden; }
.bar i { display: block; height: 100%; width: calc(var(--p, 0) * 1%); border-radius: 2px; background: var(--accent); }

.note {
  display: flex;
  gap: 11px;
  margin-top: 18px;
  padding: 15px 16px;
  border-radius: var(--r-inner);
  font-size: 15.5px;
  background: var(--tint);
  color: var(--accent);
}
.note.warn { background: var(--warn-tint); color: var(--warn); }
.note .ico { width: 19px; height: 19px; margin-top: 2px; }
.note strong { font-weight: 620; }
.note ul { margin: 7px 0 0; padding-left: 18px; }
.note li + li { margin-top: 3px; }
.note > div { min-width: 0; }

.actions { display: grid; gap: 10px; margin-top: 24px; }
@media (min-width: 460px) { .actions { grid-template-columns: 1fr 1fr; } }
.photo { display: block; width: 100%; border-radius: 18px; margin-bottom: 4px; }

/* ---------- Funde ---------- */
.stats { display: flex; gap: 14px; padding: 18px 22px; }
.stats div { flex: 1; }
.stats strong { display: block; font-size: 30px; font-weight: 640; letter-spacing: -.03em; color: var(--accent); font-variant-numeric: tabular-nums; }
.stats span { font-size: 12.5px; font-weight: 580; letter-spacing: .045em; text-transform: uppercase; color: var(--ink-3); }

.finds { display: grid; gap: 12px; grid-template-columns: 1fr; }
@media (min-width: 540px) { .finds { grid-template-columns: 1fr 1fr; } }
.find {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  padding: 12px;
  border: 0;
  border-radius: 18px;
  background: var(--surface);
  box-shadow: var(--lift);
  color: inherit;
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition: transform .12s ease, box-shadow .2s ease;
}
.find:hover { box-shadow: var(--lift-2); }
.find:active { transform: scale(.985); }
.find img, .find .noimg {
  width: 64px;
  height: 64px;
  flex: none;
  border-radius: 14px;
  object-fit: cover;
  background: var(--tint);
  display: grid;
  place-items: center;
  color: var(--accent);
}
.find .noimg .ico { width: 28px; height: 28px; }
.find .meta { min-width: 0; }
.find b { display: block; font-weight: 600; font-size: 16.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.find .sci { font-size: 14px; margin-top: 0; }
.find time { display: block; margin-top: 3px; font-size: 13px; color: var(--ink-3); font-variant-numeric: tabular-nums; }

.empty { padding: 56px 24px; text-align: center; color: var(--ink-3); }
.empty .ico { width: 42px; height: 42px; margin-bottom: 14px; color: var(--accent); opacity: .5; --m: var(--i-leaf); }

/* ---------- Reiter ---------- */
.tabs {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 30;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  background: var(--veil);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  backdrop-filter: saturate(180%) blur(20px);
  border-top: 1px solid var(--hairline-2);
  padding-bottom: env(safe-area-inset-bottom);
}
.tab {
  display: grid;
  justify-items: center;
  gap: 3px;
  padding: 9px 4px 10px;
  border: 0;
  background: none;
  font-size: 10.5px;
  font-weight: 560;
  letter-spacing: .005em;
  color: var(--ink-3);
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: color .18s ease;
}
.tab .ico { width: 25px; height: 25px; }
.tab.active { color: var(--accent); font-weight: 620; }

/* ---------- Kleinteile ---------- */
.toast {
  position: fixed;
  left: 50%;
  bottom: calc(env(safe-area-inset-bottom) + var(--tabbar) + 18px);
  transform: translateX(-50%);
  z-index: 50;
  max-width: calc(100vw - 32px);
  padding: 13px 20px;
  border-radius: 999px;
  font-size: 15px;
  font-weight: 520;
  color: #f4f8f2;
  background: rgba(20, 30, 23, .92);
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
  box-shadow: var(--lift-2);
  animation: rise .3s cubic-bezier(.2, .9, .3, 1.1);
}
@keyframes rise { from { opacity: 0; transform: translate(-50%, 14px); } }

.diag {
  margin: 14px 0 0;
  padding: 14px 16px;
  border-radius: var(--r-inner);
  background: var(--surface-2);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 12.5px;
  line-height: 1.6;
  white-space: pre-wrap;
  word-break: break-word;
  color: var(--ink-2);
}

.prose h3 { margin: 24px 0 8px; }
.prose p { color: var(--ink-2); font-size: 16px; }
.prose p + p { margin-top: 10px; }
.prose strong { color: var(--ink); font-weight: 620; }
