:root {
  --bg: #f7f4ee; --bg-2: #efe9dd; --ink: #1d2420; --muted: #5d665f; --line: #d9d2c3;
  --green: #1f6f43; --green-2: #17553a; --amber: #c77d12; --red: #b3261e; --white: #fff;
  --radius: 10px; --shadow: 0 8px 24px rgba(29, 36, 32, .08);
  --text: clamp(1rem, .95rem + .3vw, 1.125rem); --h1: clamp(2rem, 1.2rem + 3.5vw, 3.6rem); --h2: clamp(1.4rem, 1.1rem + 1.2vw, 2rem);
}
* { box-sizing: border-box; }
html { color-scheme: light; }
body { margin: 0; background: var(--bg); color: var(--ink); font: var(--text)/1.55 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; }
a { color: var(--green); }
img { max-width: 100%; }
.wrap { width: min(1100px, 100% - 2rem); margin-inline: auto; }
header.top { display: flex; align-items: center; justify-content: space-between; padding: 1rem 0; gap: 1rem; flex-wrap: wrap; }
header.top .brand { display: flex; align-items: center; gap: .6rem; font-weight: 700; text-decoration: none; color: var(--ink); font-size: 1.2rem; }
header.top nav { display: flex; gap: 1rem; flex-wrap: wrap; align-items: center; }
header.top nav a { text-decoration: none; font-weight: 600; }
h1 { font-size: var(--h1); line-height: 1.05; letter-spacing: -.02em; margin: 0 0 .6rem; }
h2 { font-size: var(--h2); margin: 2.2rem 0 .8rem; }
.lead { font-size: 1.15em; color: var(--muted); max-width: 60ch; }
.hero { display: grid; grid-template-columns: 1.2fr .8fr; gap: 2rem; align-items: center; padding: 3rem 0 2rem; }
.hero .art { background: var(--bg-2); border-radius: 24px; min-height: 260px; display: grid; place-items: center; }
@media (max-width: 800px) { .hero { grid-template-columns: 1fr; padding-top: 1.5rem; } }
.btn { display: inline-block; padding: .8rem 1.3rem; border-radius: var(--radius); background: var(--green); color: var(--white); font-weight: 700; text-decoration: none; border: 0; cursor: pointer; font-size: 1em; }
.btn:hover { background: var(--green-2); }
.btn.secondary { background: var(--white); color: var(--green); border: 2px solid var(--green); }
.btn.danger { background: var(--red); }
.btn.small { padding: .45rem .8rem; font-size: .9em; }
.btn[disabled] { opacity: .5; cursor: wait; }
.card { background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow); padding: 1.4rem; }
.stack > * + * { margin-top: 1rem; }
.grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 1rem; }
label { display: block; font-weight: 600; margin-bottom: .3rem; }
input, select, textarea { width: 100%; padding: .7rem .8rem; border: 1px solid var(--line); border-radius: 8px; font: inherit; background: var(--white); }
input:focus, select:focus, textarea:focus { outline: 3px solid rgba(31, 111, 67, .25); border-color: var(--green); }
.field { margin-bottom: 1.1rem; }
.field .err { color: var(--red); font-size: .9em; margin-top: .25rem; display: none; }
.field.invalid .err { display: block; }
.field.invalid input, .field.invalid select { border-color: var(--red); }
.check { display: flex; gap: .6rem; align-items: flex-start; font-weight: 400; }
.check input { width: auto; margin-top: .3rem; }
.species { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: .8rem; }
.species label { border: 2px solid var(--line); border-radius: var(--radius); padding: .8rem; text-align: center; cursor: pointer; font-weight: 600; background: var(--white); }
.species input { display: none; }
.species input:checked + label { border-color: var(--green); background: #eaf5ee; }
.species img { height: 70px; display: block; margin: 0 auto .4rem; }
.row { display: flex; gap: .5rem; }
#map { height: 320px; border-radius: var(--radius); border: 1px solid var(--line); }
.badge { display: inline-block; padding: .15rem .55rem; border-radius: 999px; font-size: .8em; font-weight: 700; background: var(--bg-2); }
.badge.hoch { background: #fbe9d0; color: var(--amber); }
.badge.offen, .badge.paid { background: #e3f1e8; color: var(--green); }
.badge.uebernommen { background: #e1e8f5; color: #2b4f9e; }
.badge.eskaliert, .badge.failed { background: #f9dcd9; color: var(--red); }
.tabs { display: flex; gap: .4rem; flex-wrap: wrap; margin: 1rem 0; }
.tabs button { background: var(--white); border: 1px solid var(--line); padding: .5rem .9rem; border-radius: 999px; cursor: pointer; font: inherit; font-weight: 600; }
.tabs button.active { background: var(--green); color: var(--white); border-color: var(--green); }
.list { display: grid; gap: .9rem; }
.item { display: grid; grid-template-columns: 1fr auto; gap: 1rem; align-items: start; }
@media (max-width: 600px) { .item { grid-template-columns: 1fr; } }
.meta { color: var(--muted); font-size: .92em; }
code { overflow-wrap: anywhere; font-size: .92em; }
.actions { display: flex; flex-direction: column; gap: .4rem; }
.photos { display: flex; gap: .5rem; flex-wrap: wrap; }
.photos img { width: 96px; height: 96px; object-fit: cover; border-radius: 8px; }
.toast { position: fixed; bottom: 1rem; left: 50%; transform: translateX(-50%); background: var(--ink); color: var(--white); padding: .8rem 1.2rem; border-radius: 999px; opacity: 0; transition: opacity .2s; pointer-events: none; z-index: 1000; max-width: 90vw; }
.toast.show { opacity: 1; }
.toast.error { background: var(--red); }
footer { margin: 4rem 0 2rem; color: var(--muted); font-size: .9em; display: flex; gap: 1.2rem; flex-wrap: wrap; }
table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: .5rem; border-bottom: 1px solid var(--line); vertical-align: top; }
.table-wrap { overflow-x: auto; }
.hidden { display: none !important; }
