/* Pratum – mobile first. Ein Inhaltsbereich; Navigation: Kopfzeile (ab 760 px) oder Fusszeile (Handy). */
:root {
  --brand: #0f7f74; --brand-ink: #0a5a52; --brand-soft: #e2f2ef; --on-brand: #fff;
  --bg: #f4f6f4; --surface: #fff; --surface-2: #eef2ef; --line: #dbe3df; --line-strong: #7a8883;
  --ink: #17221e; --ink-2: #4b5a54; --ink-3: #5b6a64;
  --gut: #2f9e5f; --mittel: #d39b17; --schlecht: #e2701f; --kritisch: #c93a32; --offen: #9aa7a1;
  --gut-soft: #e3f4ea; --mittel-soft: #fbf1d6; --schlecht-soft: #fde9dc; --kritisch-soft: #fbe3e1;
  /* Ampelfarben für Text und Füllungen mit weisser Schrift (≥ 4,5 : 1) */
  --gut-text: #1b6e3d; --mittel-text: #7a5600; --schlecht-text: #a94a0b; --kritisch-text: #b02a22; --gut-strong: #1f7d47;
  --disabled-bg: #e6ebe8; --disabled-ink: #55645e;
  --radius: 14px; --radius-s: 10px; --tap: 48px;
  --shadow: 0 1px 2px rgb(0 0 0 / .06), 0 4px 16px rgb(0 0 0 / .06);
  --fs: 1rem; --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --safe-b: env(safe-area-inset-bottom, 0px);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --brand: #3fb8a8; --brand-ink: #7dd8cb; --brand-soft: #143430; --on-brand: #04201c;
    --bg: #0d1714; --surface: #15221e; --surface-2: #1b2b26; --line: #263a33; --line-strong: #628072;
    --ink: #e7efec; --ink-2: #b2c2bc; --ink-3: #98a99f;
    --gut-soft: #16301f; --mittel-soft: #33290d; --schlecht-soft: #36200f; --kritisch-soft: #3a1714;
    --gut-text: #6fd69a; --mittel-text: #f0c24f; --schlecht-text: #ffa066; --kritisch-text: #ff8f86; --gut-strong: #2f9e5f;
    --disabled-bg: #26352f; --disabled-ink: #a9b9b1;
    --shadow: 0 1px 2px rgb(0 0 0 / .4); color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --brand: #3fb8a8; --brand-ink: #7dd8cb; --brand-soft: #143430; --on-brand: #04201c;
  --bg: #0d1714; --surface: #15221e; --surface-2: #1b2b26; --line: #263a33; --line-strong: #628072;
  --ink: #e7efec; --ink-2: #b2c2bc; --ink-3: #98a99f;
  --gut-soft: #16301f; --mittel-soft: #33290d; --schlecht-soft: #36200f; --kritisch-soft: #3a1714;
  --gut-text: #6fd69a; --mittel-text: #f0c24f; --schlecht-text: #ffa066; --kritisch-text: #ff8f86; --gut-strong: #2f9e5f;
  --disabled-bg: #26352f; --disabled-ink: #a9b9b1;
  --shadow: 0 1px 2px rgb(0 0 0 / .4); color-scheme: dark;
}
/* Draussen: maximaler Kontrast, grössere Schrift und Ziele */
:root[data-outdoor="1"] {
  --bg: #fff; --surface: #fff; --surface-2: #f1f1f1; --line: #6b6b6b; --line-strong: #000;
  --ink: #000; --ink-2: #1a1a1a; --ink-3: #333; --brand: #005f56; --brand-ink: #003d37;
  --fs: 1.125rem; --tap: 56px; --shadow: none; color-scheme: light;
  --gut-text: #14582f; --schlecht-text: #8a3a06; --kritisch-text: #8f1f19; --mittel-text: #5e4200; --disabled-bg: #ececec; --disabled-ink: #333;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--kopf-h, 0px) + 5rem); scroll-padding-bottom: calc(var(--fuss-h, 0px) + 1rem); }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 var(--fs)/1.45 var(--font); }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: var(--brand-ink); }
:focus-visible { outline: 3px solid var(--brand); outline-offset: 2px; border-radius: 6px; }
/* Ziele, die nur per Skript (Seitenwechsel, Dialog) den Fokus bekommen: bei Maus und Touch kein Ring */
[tabindex="-1"]:focus:not(:focus-visible), #main:focus { outline: none; }
.skip { position: absolute; left: -999px; } .skip:focus { left: 8px; top: 8px; z-index: 99; background: var(--surface); padding: 12px 16px; min-height: 44px; display: inline-flex; align-items: center; }
abbr[title] { text-decoration: underline dotted; text-underline-offset: 3px; cursor: help; }
.sr { position: absolute; left: 0; top: 0; width: 1px; height: 1px; margin: -1px; padding: 0; border: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; scroll-behavior: auto !important; } }

/* ---------- Shell ---------- */
:root { --kopf-h: 0px; --fuss: 0px; --fuss-h: calc(3.9rem + var(--safe-b)); }
/* Kein overflow-x:clip/hidden mehr: nichts wird abgeschnitten. Breite Inhalte brechen um oder scrollen in ihrem eigenen Behälter (Tabellen, Leisten). */
.shell { min-height: 100dvh; }
.region-detail { min-width: 0; }
@media (min-width: 760px) {
  :root { --kopf-h: 56px; }
  /* Inhalt mittig, schmal; Pflanzenliste etwas breiter */
  .region-detail { max-width: 880px; margin: 0 auto; }
  .shell[data-breit="1"] .region-detail { max-width: 1100px; }
}
@media (max-width: 759.98px) {
  .shell[data-fuss="1"] { --fuss: var(--fuss-h); padding-bottom: var(--fuss-h); }
  html.tippt .shell { --fuss: 0px; padding-bottom: 0; }
  /* Unterseiten (Zurück-Pfeil in der Seitenleiste des Inhalts) ersetzen die Kopfzeile */
  .shell[data-sub="1"] .topbar { display: none; }
}

/* ---------- Kopfzeile (Logo; ab 760 px mit Textnavigation und «+ Neu») ---------- */
.topbar { position: sticky; top: 0; z-index: 6; display: flex; align-items: center; gap: 14px; min-height: 56px; padding: 6px 12px; padding-top: max(6px, env(safe-area-inset-top));
  background: color-mix(in srgb, var(--surface) 94%, transparent); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.topbar { flex-wrap: wrap; }
.topbar .brand { display: flex; align-items: center; gap: 10px; flex: 1; min-width: 0; text-decoration: none; color: var(--ink); border-radius: 10px; }
.topbar .brand img { width: 34px; height: 34px; border-radius: 9px; }
.topbar .brand b { font-size: 1.1rem; letter-spacing: .01em; }
.topnav, .top-sprache, .topbar .top-neu { display: none; }
@media (min-width: 760px) {
  .topbar { padding: 6px max(16px, calc((100vw - 1100px) / 2)); }
  .topbar .brand { flex: none; margin-right: 12px; }
  .topnav { display: flex; align-items: center; gap: 4px; flex: 1; min-width: 0; }
  .topnav a { display: inline-flex; align-items: center; min-height: 40px; padding: 0 14px; border-radius: 10px; color: var(--ink-2); font-weight: 650; text-decoration: none; border-bottom: 3px solid transparent; border-radius: 10px 10px 0 0; }
  .topnav a:hover { background: var(--surface-2); color: var(--ink); }
  .topnav a[aria-current="page"] { color: var(--brand-ink); border-bottom-color: var(--brand); background: var(--brand-soft); }
  .top-rechts { display: flex; align-items: center; gap: 8px; flex: none; }
  .topbar .top-neu { display: inline-flex; }
  .top-neu svg { width: 18px; height: 18px; }
  .top-sprache { display: inline-flex; gap: 2px; padding: 2px; border-radius: 10px; background: var(--surface-2); }
  .top-sprache button { min-width: 32px; min-height: 30px; border: 0; border-radius: 8px; background: transparent; color: var(--ink-3); font-size: .74rem; font-weight: 750; letter-spacing: .04em; cursor: pointer; }
  .top-sprache button[aria-pressed="true"] { background: var(--surface); color: var(--ink); box-shadow: var(--shadow); }
}
.top-rechts { display: flex; align-items: center; gap: 8px; }

/* ---------- Fusszeile am Handy: fünf Ziele, «Neu» in der Mitte ---------- */
.fussnav { display: none; }
@media (max-width: 759.98px) {
  .fussnav { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); align-items: stretch;
    padding: 0 4px var(--safe-b); background: var(--surface); border-top: 1px solid var(--line); box-shadow: 0 -2px 10px rgb(0 0 0 / .06); }
  .shell[data-fuss="0"] .fussnav, html.cam-offen .fussnav, html.tippt .fussnav { display: none; }
  .fn { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; min-height: 56px; min-width: 0; padding: 6px 2px; border: 0; background: transparent; color: var(--ink-3);
    font: inherit; font-size: .72rem; font-weight: 650; text-decoration: none; cursor: pointer; }
  .fn:focus-visible { outline-offset: -4px; }
  .fn-ico { display: grid; place-items: center; width: 52px; height: 28px; border-radius: 14px; }
  .fn-ico svg { width: 22px; height: 22px; }
  .fn-t { line-height: 1.1; max-width: 100%; overflow-wrap: anywhere; hyphens: auto; text-align: center; }
  .fn[aria-current="page"] { color: var(--brand-ink); }
  .fn[aria-current="page"] .fn-ico { background: var(--brand-soft); }
  .fn[aria-current="page"] .fn-t { font-weight: 800; }
  .fn-neu { color: var(--ink); }
  .fn-neu .fn-ico { width: 46px; height: 36px; border-radius: 14px; background: var(--brand); color: var(--on-brand); box-shadow: 0 3px 10px rgb(15 127 116 / .35); margin-top: -6px; }
  .fn-neu .fn-ico svg { width: 24px; height: 24px; }
  .fn-neu .fn-t { font-weight: 750; }
}

/* ---------- Top bars ---------- */
.bar { position: sticky; top: var(--kopf-h); z-index: 5; display: flex; align-items: center; gap: 8px; min-height: 56px;
  padding: 6px 12px; padding-top: max(6px, env(safe-area-inset-top)); background: color-mix(in srgb, var(--surface) 92%, transparent);
  backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.bar h1, .bar h2 { font-size: 1.05rem; margin: 0; line-height: 1.2; flex: 1; min-width: 0; overflow-wrap: anywhere; }
.bar .sub { display: block; font-size: .78rem; color: var(--ink-3); font-weight: 500; overflow-wrap: anywhere; }
/* Hauptseiten (Wiesen, Pflanzen, Werkzeuge, Hilfe): schlichte Überschrift statt Leiste mit Zurück-Pfeil */
.bar.bar-top { position: static; background: none; backdrop-filter: none; border-bottom: 0; min-height: 0; padding: 18px 16px 0; }
.bar.bar-top h1, .bar.bar-top h2 { font-size: 1.45rem; }
@media (min-width: 760px) { .bar { background: var(--bg); backdrop-filter: none; } .bar.bar-top { padding-left: 16px; } }
.icon-btn { width: 44px; height: 44px; display: inline-grid; place-items: center; border-radius: 12px; border: 0; background: transparent; cursor: pointer; color: var(--ink-2); flex: none; }
.icon-btn:hover { background: var(--surface-2); }
.icon-btn svg, .btn svg { width: 22px; height: 22px; }

/* ---------- Basics ---------- */
.pad { padding: 16px; }
.stack > * + * { margin-top: 12px; }
.muted { color: var(--ink-3); }
.small { font-size: .86rem; }
.row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.grow { flex: 1; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; box-shadow: var(--shadow); }
.section-title { font-size: .76rem; font-weight: 750; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-3); margin: 22px 4px 8px; }
h3, .h-q { font-size: 1.1rem; margin: 0 0 4px; }
.btn { min-height: var(--tap); max-width: 100%; padding: 6px 18px; line-height: 1.25; text-align: center; overflow-wrap: anywhere; display: inline-flex; align-items: center; justify-content: center; gap: 8px; border-radius: 12px;
  border: 1px solid var(--line-strong); background: var(--surface); font-weight: 650; cursor: pointer; text-decoration: none; color: var(--ink); }
.btn:hover { background: var(--surface-2); }
.btn.primary { background: var(--brand); border-color: var(--brand); color: var(--on-brand); }
.btn.primary:hover { filter: brightness(1.05); }
.btn.ghost { border-color: transparent; background: transparent; }
.btn.danger { color: var(--kritisch-text); border-color: color-mix(in srgb, var(--kritisch) 55%, var(--line)); }
.btn.block { width: 100%; }
/* Deaktiviert: graue Fläche, gestrichelter Rand, gut lesbare Schrift (statt Halbtransparenz) */
.btn[disabled], .btn.primary[disabled], .btn.danger[disabled] { background: var(--disabled-bg); color: var(--disabled-ink); border: 1px dashed var(--line-strong); filter: none; cursor: not-allowed; }
.btn.sm { min-height: 38px; padding: 4px 12px; font-size: .9rem; }
.chip { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: 99px; font-size: .8rem; font-weight: 650; background: var(--surface-2); color: var(--ink-2); max-width: 100%; overflow-wrap: anywhere; }
.chip.gut { background: var(--gut-soft); color: var(--gut-text); } .chip.mittel { background: var(--mittel-soft); color: var(--mittel-text); }
.chip.schlecht { background: var(--schlecht-soft); color: var(--schlecht-text); } .chip.kritisch { background: var(--kritisch-soft); color: var(--kritisch-text); }
.dot { width: 10px; height: 10px; border-radius: 50%; display: inline-block; flex: none; }

label.field { display: block; }
label.field > span { display: block; font-size: .86rem; font-weight: 650; color: var(--ink-2); margin-bottom: 6px; }
.input { width: 100%; min-height: var(--tap); padding: 10px 14px; border: 1px solid var(--line-strong); border-radius: 12px; background: var(--surface); }
input[type="range"] { min-height: 44px; accent-color: var(--brand); }
summary { cursor: pointer; min-height: 44px; padding: 10px 0; }
textarea.input { min-height: 88px; resize: vertical; }
.hint { font-size: .8rem; color: var(--ink-3); margin-top: 6px; }
.grid2 { display: grid; gap: 12px; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.grid2 > *, .grid4 > *, .opts > * { min-width: 0; }
@media (max-width: 420px) { .grid2 { grid-template-columns: minmax(0, 1fr); } }

/* ---------- Listen ---------- */
.list { list-style: none; margin: 0; padding: 0; }
.item { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 12px; min-height: 60px; cursor: pointer; text-decoration: none; color: inherit; border: 1px solid transparent; }
.item:hover { background: var(--surface-2); }
.item[aria-current="true"] { background: var(--brand-soft); border-color: color-mix(in srgb, var(--brand) 35%, transparent); }
.item > span:not(.meta):not(.avatar) { min-width: 0; flex: 1; }
.item .t, .item .s { display: block; }
.item .t { font-weight: 650; overflow-wrap: anywhere; }
.item .s { font-size: .8rem; color: var(--ink-3); overflow-wrap: anywhere; }
.item .meta { margin-left: auto; text-align: right; flex: none; }
.item .num { font-variant-numeric: tabular-nums; font-weight: 750; }
.item .mini { width: 46px; height: 46px; flex: none; }
.avatar { width: 40px; height: 40px; border-radius: 11px; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand-ink); font-weight: 800; flex: none; font-size: .85rem; }
.sync-ico { width: 16px; height: 16px; vertical-align: -3px; }
.empty { text-align: center; padding: 32px 16px; color: var(--ink-3); }
.empty svg { width: 120px; height: 120px; opacity: .9; }

/* ---------- FAB / Aktionsleiste ---------- */
.actionbar { position: sticky; bottom: 0; z-index: 4; display: flex; gap: 10px; padding: 10px 12px calc(10px + var(--safe-b));
  background: color-mix(in srgb, var(--surface) 94%, transparent); backdrop-filter: blur(10px); border-top: 1px solid var(--line); }
.actionbar .btn { flex: 1; }
.fab-wrap { position: sticky; bottom: 0; padding: 12px 16px calc(14px + var(--safe-b)); display: flex; justify-content: flex-end; pointer-events: none; }
.fab { pointer-events: auto; min-height: 56px; padding: 0 22px; border-radius: 18px; box-shadow: 0 6px 20px rgb(15 127 116 / .35); }

/* ---------- Wizard ---------- */
.steps { display: flex; gap: 6px; overflow-x: auto; padding: 10px 12px; scrollbar-width: none; border-bottom: 1px solid var(--line); background: var(--surface); }
.steps::-webkit-scrollbar { display: none; }
.step-chip { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; min-height: 36px; border-radius: 99px; border: 1px solid var(--line); background: var(--surface);
  white-space: nowrap; font-size: .85rem; font-weight: 650; cursor: pointer; color: var(--ink-2); }
.step-chip .n { width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; font-size: .72rem; background: var(--surface-2); }
.step-chip.done .n { background: var(--gut-strong); color: #fff; }
.step-chip[aria-current="step"] { border-color: var(--brand); background: var(--brand-soft); color: var(--brand-ink); }
.wizard { max-width: 760px; margin: 0 auto; padding: 16px 16px 24px; }
.q { margin: 0 0 22px; }
.q > h3 { font-size: 1.12rem; }
.q > .qhint { color: var(--ink-3); font-size: .9rem; margin: 0 0 12px; }
.opts { display: grid; gap: 8px; }
.opts.cols2 { grid-template-columns: 1fr 1fr; }
.opts.cols3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 400px) { .opts.cols3 { grid-template-columns: minmax(0, 1fr); } }
.opt b, .opt small { overflow-wrap: anywhere; hyphens: auto; }
@media (min-width: 560px) { .opts.cols-wide { grid-template-columns: 1fr 1fr; } }
.opt { position: relative; display: flex; align-items: center; gap: 12px; text-align: left; min-height: var(--tap); padding: 10px 14px; border-radius: 12px; cursor: pointer;
  border: 1.5px solid var(--line-strong); background: var(--surface); transition: border-color .12s, background .12s, transform .06s; }
.opt:active { transform: scale(.985); }
.opt:hover { border-color: var(--ink-3); }
.opt[aria-pressed="true"] { border-color: var(--brand); background: var(--brand-soft); box-shadow: inset 0 0 0 1px var(--brand); }
/* Gewählt zusätzlich mit Haken (nicht nur Farbe); der Platz ist immer reserviert, damit nichts springt. Für Screenreader leer (aria-pressed sagt es). */
.opt::after { content: "✓" / ""; flex: none; width: 1.3rem; text-align: center; font-weight: 800; color: var(--brand-ink); visibility: hidden; }
.opt[aria-pressed="true"]::after { visibility: visible; }
.seg button[aria-pressed="true"]::before, .au-chip[aria-pressed="true"]::before, .chip-btn[aria-pressed="true"]::before, .pf-tabs button[aria-pressed="true"]::before, .kb-btn[aria-pressed="true"]::before, .tier-schalter[aria-pressed="true"]::before { visibility: visible; }
a.chip-btn[aria-current="true"]::before { visibility: visible; }
.seg button::before, .au-chip::before, .chip-btn::before, .pf-tabs button::before, .kb-btn::before, .tier-schalter::before { content: "✓" / ""; display: inline-block; width: 1.1em; margin-right: .1em; text-align: center; font-weight: 800; visibility: hidden; }
.tier-schalter::before { align-self: flex-start; margin: 0 -2px 0 0; }
.pf-opt[aria-pressed="true"]::after { content: "✓" / ""; position: absolute; left: 7px; top: 4px; font-size: .8rem; font-weight: 800; color: var(--brand-ink); }
.opt .lead { flex: none; min-width: 44px; height: 36px; padding: 0 8px; display: grid; place-items: center; border-radius: 10px; font-weight: 800; background: var(--surface-2); font-variant-numeric: tabular-nums; }
.opt .body { flex: 1; min-width: 0; }
.opt .body b { display: block; font-weight: 700; }
.opt .body small { display: block; color: var(--ink-3); font-size: .84rem; line-height: 1.3; }
.opt .tag { flex: none; font-size: .78rem; font-weight: 750; color: var(--ink-2); font-variant-numeric: tabular-nums; }
.opt .lead sub, .wi-vorschlag .lead sub { font-size: .65em; line-height: 1; vertical-align: baseline; position: relative; top: .3em; margin-left: 1px; }
.opt .lead:has(sub) { display: flex; align-items: center; justify-content: center; }
.opt.warn .lead { background: var(--kritisch-soft); color: var(--kritisch-text); }
/* Vorschlag (Stadium aus den Wochen): Badge als .tag in der Karte, Rahmen gestrichelt – eindeutig dieser Karte zugeordnet */
.opt.suggest:not([aria-pressed="true"]) { border-style: dashed; border-color: var(--mittel); }
.seg { display: inline-flex; padding: 4px; gap: 4px; background: var(--surface-2); border-radius: 13px; width: 100%; }
.seg button { flex: 1; min-width: 0; min-height: 44px; border: 0; border-radius: 10px; background: transparent; font-weight: 650; cursor: pointer; color: var(--ink-2); }
.seg button[aria-pressed="true"] { background: var(--surface); color: var(--ink); box-shadow: var(--shadow); }
.toggle { display: flex; align-items: center; gap: 12px; min-height: var(--tap); padding: 8px 14px; border: 1.5px solid var(--line-strong); border-radius: 12px; cursor: pointer; background: var(--surface); }
.toggle input { width: 22px; height: 22px; accent-color: var(--brand); }
.stepper { display: flex; align-items: stretch; border: 1px solid var(--line-strong); border-radius: 12px; overflow: hidden; background: var(--surface); }
.stepper button { flex: none; width: 56px; border: 0; background: var(--surface-2); font-size: 1.4rem; font-weight: 700; cursor: pointer; }
.stepper button:focus-visible { outline-offset: -4px; }
.stepper input { flex: 1; width: 0; min-width: 0; border: 0; text-align: center; font-size: 1.3rem; font-weight: 750; min-height: 52px; background: transparent; font-variant-numeric: tabular-nums; }
.plant-chips { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 6px; margin-bottom: 8px; scrollbar-width: thin; }
.plant-chips button { flex: none; }

/* ---------- Rad ---------- */
.rad-layout { display: grid; gap: 16px; }
/* Rad und Fragen nebeneinander nur, wenn der Arbeitsbereich selbst breit genug ist (nicht das ganze Fenster) */
.region-detail { container-type: inline-size; container-name: detail; }
@container detail (min-width: 760px) { .rad-layout { grid-template-columns: minmax(320px, 440px) 1fr; align-items: start; } .rad-sticky { position: sticky; top: calc(var(--kopf-h) + 70px); } }
.rad-box { background: var(--surface); border: 1px solid var(--line); border-radius: 22px; padding: 6px; box-shadow: var(--shadow); }
.rad { display: block; width: 100%; height: auto; max-width: 460px; margin: 0 auto; touch-action: manipulation; }
.rad .rz-hit { cursor: pointer; }
.rad .rz-hit:hover { filter: brightness(.94); }
.rad-mini { width: 46px; height: 46px; }
.factor-nav { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.factor-nav button { display: inline-flex; align-items: center; gap: 6px; min-height: 36px; padding: 4px 10px 4px 6px; border-radius: 99px; border: 1px solid var(--line); background: var(--surface); font-size: .84rem; font-weight: 650; cursor: pointer; }
.factor-nav button[aria-current="true"] { border-color: var(--ink); }
.factor-nav .sw { width: 18px; height: 18px; border-radius: 50%; display: grid; place-items: center; font-size: .65rem; color: #1d2925; font-weight: 800; }
.live { display: flex; gap: 10px; align-items: center; padding: 10px 14px; border-radius: 12px; background: var(--surface-2); margin: 10px 0 0; font-weight: 650; }

/* ---------- Ergebnis ---------- */
.hero { border-radius: 20px; padding: 18px; color: #fff; background: var(--offen); display: grid; grid-template-columns: minmax(0, 1fr); gap: 4px; }
.hero > * { min-width: 0; overflow-wrap: anywhere; }
/* Verläufe so dunkel, dass weisse Schrift ≥ 4,5 : 1 hat (gelb: dunkle Schrift) */
.hero.gut { background: linear-gradient(135deg, #1f7d47, #17653a); } .hero.mittel { background: linear-gradient(135deg, #d9a21d, #b88207); color: #2b1d00; }
.hero.schlecht { background: linear-gradient(135deg, #b94d0f, #9a3d08); } .hero.kritisch { background: linear-gradient(135deg, #b3322b, #8f221c); }
.hero .k { font-size: .82rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; }
.hero .v { font-size: 1.6rem; font-weight: 800; line-height: 1.15; }
.kpis { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
@media (min-width: 640px) { .kpis { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.kpi .v { overflow-wrap: anywhere; }
.kz-erkl { margin: 8px 0 0; font-size: .9rem; color: var(--ink-2); }
.kz-erkl summary { color: var(--brand-ink); font-weight: 650; }
.kz-erkl dl { margin: 0 0 6px; display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 4px 12px; }
.kz-erkl dt { font-weight: 750; color: var(--ink); } .kz-erkl dd { margin: 0; }
.kpi { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; }
.kpi .l { font-size: .78rem; font-weight: 700; color: var(--ink-3); }
.kpi .v { font-size: 1.55rem; font-weight: 800; font-variant-numeric: tabular-nums; line-height: 1.2; }
.kpi .v small { font-size: .8rem; font-weight: 600; color: var(--ink-3); }
.kpi .d { font-size: .78rem; font-weight: 650; }
.d.neg { color: var(--kritisch-text); } .d.pos { color: var(--gut-text); }
.gauge { position: relative; height: 12px; border-radius: 99px; background: linear-gradient(90deg, #f3d2cf, #f8e7b8 45%, #cde9d7 70%); margin: 10px 0 18px; }
.gauge .mk { position: absolute; top: -5px; width: 4px; height: 22px; border-radius: 2px; background: var(--ink); transform: translateX(-2px); }
.gauge .ghost { background: var(--ink-3); opacity: .5; }
.gauge .tg { position: absolute; top: 15px; font-size: .7rem; color: var(--ink-3); transform: translateX(-50%); white-space: nowrap; }
.tbl-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); }
table.tbl { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; font-size: .92rem; }
.tbl th, .tbl td { padding: 9px 12px; text-align: right; border-bottom: 1px solid var(--line); white-space: nowrap; }
.tbl th:first-child, .tbl td:first-child { text-align: left; }
.tbl thead th { font-size: .75rem; text-transform: uppercase; letter-spacing: .04em; color: var(--ink-3); background: var(--surface-2); position: sticky; top: 0; }
.tbl th button { all: unset; cursor: pointer; } .tbl th button:hover { color: var(--ink); }
.tbl tbody tr:last-child td { border-bottom: 0; }
.tbl tr.click { cursor: pointer; } .tbl tr.click:hover td { background: var(--surface-2); }
.tbl strong { font-weight: 800; }
.alert { border-radius: 14px; padding: 12px 14px; display: flex; gap: 10px; align-items: flex-start; font-weight: 600; }
.alert.kritisch { background: var(--kritisch-soft); color: var(--kritisch-text); border: 1px solid color-mix(in srgb, var(--kritisch) 35%, transparent); }
.alert.info { background: var(--surface-2); color: var(--ink-2); font-weight: 500; }
.alert svg { width: 22px; height: 22px; flex: none; }
.rating { display: flex; justify-content: space-between; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.rating:last-child { border-bottom: 0; }

/* ---------- Übersicht ---------- */
.ov-grid { display: grid; gap: 16px; }
@media (min-width: 1100px) { .ov-grid { grid-template-columns: 1.2fr 1fr; } }
.bars { display: grid; gap: 8px; }
.bars .b { display: grid; grid-template-columns: minmax(80px, 140px) 1fr 52px; gap: 10px; align-items: center; font-size: .86rem; cursor: pointer; }
.bars .lbl { overflow-wrap: anywhere; font-weight: 600; }
.bars .track { position: relative; height: 22px; background: var(--surface-2); border-radius: 6px; overflow: hidden; }
.bars .base { position: absolute; inset: 0 auto 0 0; background: repeating-linear-gradient(135deg, var(--line-strong) 0 4px, transparent 4px 8px); opacity: .7; }
.bars .val { position: absolute; inset: 0 auto 0 0; border-radius: 6px; }
.bars .target { position: absolute; top: -3px; bottom: -3px; width: 2px; background: var(--ink); }
.bars .n { text-align: right; font-weight: 750; font-variant-numeric: tabular-nums; }
.wheels { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 10px; }
.wheels a { text-decoration: none; color: inherit; text-align: center; font-size: .8rem; font-weight: 600; padding: 8px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface); }
.wheels a:hover { border-color: var(--line-strong); }
.wheels svg { width: 100%; height: auto; }
.legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: .8rem; color: var(--ink-3); }
.legend span { display: inline-flex; gap: 6px; align-items: center; }

/* ---------- Sheet / Dialog ---------- */
.scrim { position: fixed; inset: 0; background: rgb(8 16 13 / .45); z-index: 40; display: flex; align-items: flex-end; justify-content: center; animation: fade .15s; }
.sheet { background: var(--surface); width: 100%; max-width: 560px; max-height: 92dvh; overflow-y: auto; border-radius: 22px 22px 0 0; padding: 8px 18px calc(18px + var(--safe-b)); animation: up .2s ease-out; }
.sheet::before { content: ''; display: block; width: 40px; height: 5px; border-radius: 3px; background: var(--line-strong); margin: 4px auto 12px; }
.sheet h2 { margin: 0 0 8px; font-size: 1.25rem; }
.sheet:focus, .sheet h2:focus, .cam:focus, .cam-t b:focus { outline: none; }
@media (min-width: 760px) { .scrim { align-items: center; } .sheet { border-radius: 22px; padding-bottom: 20px; } .sheet::before { display: none; } }
@keyframes up { from { transform: translateY(30px); opacity: 0; } } @keyframes fade { from { opacity: 0; } }
.consent ul { padding-left: 1.1em; margin: 8px 0; } .consent li { margin: 6px 0; }
.qr-box { display: grid; place-items: center; background: #fff; border-radius: 14px; padding: 14px; }
.qr-box img, .qr-box svg { width: 220px; height: 220px; image-rendering: pixelated; }
.copy-field { display: flex; gap: 8px; } .copy-field input { font-size: .82rem; }
#toast { position: fixed; left: 50%; bottom: calc(86px + var(--safe-b)); transform: translateX(-50%); z-index: 60; pointer-events: none; display: flex; flex-direction: column; align-items: center; gap: 8px; width: max-content; max-width: calc(100vw - 24px); }
#toast .t { pointer-events: auto; display: flex; flex-wrap: wrap; gap: 4px 10px; align-items: center; background: #17221e; color: #fff; padding: 6px 8px 6px 16px; min-height: 44px; border-radius: 12px; font-weight: 600; box-shadow: 0 8px 24px rgb(0 0 0 / .25); animation: up .2s; max-width: 100%; }
#toast .t-text { flex: 1 1 auto; min-width: 0; overflow-wrap: anywhere; }
#toast .t-btn, #toast .t-x { all: unset; box-sizing: border-box; cursor: pointer; min-height: 44px; min-width: 44px; padding: 0 12px; display: inline-flex; align-items: center; justify-content: center; font-weight: 700; text-decoration: underline; border-radius: 10px; color: inherit; }
#toast .t-x { text-decoration: none; font-size: 1.5rem; padding: 0; }
#toast .t-btn:focus-visible, #toast .t-x:focus-visible { outline: 3px solid #fff; outline-offset: 0; }

.typ-cards { display: grid; gap: 10px; }
.typ-card { display: flex; gap: 14px; align-items: center; padding: 14px; border-radius: 16px; border: 1.5px solid var(--line); background: var(--surface); cursor: pointer; text-align: left; min-height: 76px; }
.typ-card:hover { border-color: var(--brand); }
.typ-card .ico { width: 52px; height: 52px; border-radius: 14px; display: grid; place-items: center; flex: none; font-weight: 800; font-size: .8rem; }
.typ-card b { display: block; font-size: 1.05rem; }
.welcome { max-width: 720px; margin: 0 auto; padding: 32px 20px; }
.welcome h2 { font-size: 1.6rem; margin: 0 0 8px; }
.feature { display: flex; gap: 12px; align-items: flex-start; margin: 14px 0; }
.feature .fi { width: 38px; height: 38px; border-radius: 10px; background: var(--brand-soft); color: var(--brand-ink); display: grid; place-items: center; flex: none; }
.feature .fi svg { width: 22px; height: 22px; }
/* Offline-Hinweis: ruhige Marke in der Kopfzeile (bzw. in der Leiste einer Unterseite), nur wenn offline */
.offline-pill { display: none; align-items: center; font-size: .78rem; font-weight: 700; line-height: 1.2; padding: 3px 10px; border-radius: 99px; background: var(--mittel-soft); color: var(--mittel-text); border: 1px solid color-mix(in srgb, var(--mittel) 50%, transparent); max-width: 100%; }
html.offline .offline-pill { display: inline-flex; }
.bar > .offline-pill { order: 98; flex: 0 1 auto; }
.topbar .top-rechts .offline-pill { flex: 0 1 auto; }
.ph-chart { width: 100%; max-width: 420px; height: auto; display: block; }
.drop { border: 2px dashed var(--line-strong); border-radius: 16px; padding: 22px; text-align: center; cursor: pointer; }
.drop.over { border-color: var(--brand); background: var(--brand-soft); }
@media print { .bar, .actionbar, .steps, .topbar, .fussnav, .fab-wrap { display: none !important; } }

/* Datenschutzseite */
.doc{max-width:760px;margin:0 auto;padding:24px 18px 64px}
.doc h1{font-size:1.6rem}
.doc h2{font-size:1.15rem;margin-top:28px}
.draft{background:#fbf1d6;color:#7a5300;border-radius:12px;padding:10px 14px;font-weight:600}

/* Fotos */
.fotos { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 8px; }
.foto-thumb, .foto-add { position: relative; aspect-ratio: 1; border-radius: 12px; overflow: hidden; border: 1px solid var(--line); background: var(--surface-2); padding: 0; cursor: pointer; }
.foto-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.foto-thumb .foto-art { position: absolute; left: 6px; bottom: 6px; font-size: .68rem; font-weight: 750; background: rgb(0 0 0 / .55); color: #fff; padding: 1px 7px; border-radius: 99px; }
.foto-thumb.gesperrt img { filter: blur(14px) grayscale(.6); transform: scale(1.15); }
.foto-thumb .lock { position: absolute; inset: 0; display: grid; place-items: center; color: #fff; }
.foto-thumb .lock svg { width: 30px; height: 30px; filter: drop-shadow(0 1px 3px rgb(0 0 0 / .5)); }
.foto-thumb.fehlt::after { content: 'nicht auf diesem Gerät'; position: absolute; inset: 0; display: grid; place-items: center; font-size: .7rem; color: var(--ink-3); padding: 8px; text-align: center; }
.foto-add { display: grid; place-items: center; align-content: center; gap: 4px; border-style: dashed; border-width: 2px; color: var(--ink-2); font-size: .78rem; font-weight: 700; }
.foto-add svg { width: 26px; height: 26px; }
.foto-gross { display: block; width: 100%; max-height: 70dvh; object-fit: contain; border-radius: 12px; background: #000; }
.redact { position: fixed; inset: 0; z-index: 80; background: #111; color: #fff; display: flex; flex-direction: column; }
.redact-bar { display: flex; flex-wrap: wrap; gap: 8px 14px; align-items: center; padding: 10px 14px; padding-top: max(10px, env(safe-area-inset-top)); background: #1d1d1d; }
.redact-bar .row { margin-left: auto; }
.redact-bar .btn { color: #fff; background: #333; border-color: #555; }
.redact-bar .btn.primary { background: var(--brand); border-color: var(--brand); }
.redact-stage { flex: 1; display: grid; place-items: center; overflow: hidden; touch-action: none; padding: 8px; }
.redact-stage canvas { touch-action: none; cursor: crosshair; max-width: 100%; }

/* Futterart-Farben (Merkblatt K3a/K3b/K3c) */
:root { --typ-heu: #357a55; --typ-gras: #2f78b0; --typ-mais: #e9b43c; }
.item.typ-heu { box-shadow: inset 5px 0 0 var(--typ-heu); }
.item.typ-gras { box-shadow: inset 5px 0 0 var(--typ-gras); }
.item.typ-mais { box-shadow: inset 5px 0 0 var(--typ-mais); }
.typ-badge { display: inline-block; font-size: .66rem; font-weight: 800; line-height: 1; padding: 3px 6px; border-radius: 6px; color: #10201a; vertical-align: 1px; }
.typ-badge.typ-heu { background: var(--typ-heu); color: #fff; } .typ-badge.typ-gras { background: var(--typ-gras); color: #fff; } .typ-badge.typ-mais { background: var(--typ-mais); }
.tbl tr.typ-heu td:first-child { box-shadow: inset 4px 0 0 var(--typ-heu); }
.tbl tr.typ-gras td:first-child { box-shadow: inset 4px 0 0 var(--typ-gras); }
.tbl tr.typ-mais td:first-child { box-shadow: inset 4px 0 0 var(--typ-mais); }
.item.typ-heu .typ-avatar { background: var(--typ-heu); color: #fff; } .item.typ-gras .typ-avatar { background: var(--typ-gras); color: #fff; } .item.typ-mais .typ-avatar { background: var(--typ-mais); color: #10201a; }

@media print { .update-banner { display: none !important; } }
/* Hinweis auf neue Version */
.update-banner { position: fixed; left: 50%; top: 12px; transform: translateX(-50%); z-index: 60; display: flex; gap: 12px; align-items: center;
  background: var(--surface); color: var(--ink); border: 1px solid var(--brand); border-radius: var(--radius); box-shadow: var(--shadow); padding: 8px 10px 8px 14px; max-width: calc(100vw - 32px); }

/* Sammelerfassung (Ernterapport) */
.grid4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
@media (max-width: 640px) { .grid4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.input.sm { min-height: 38px; padding: 6px 8px; font-size: .92rem; border-radius: 8px; }
.sammel-tbl td { padding: 4px; vertical-align: middle; }
.sammel-tbl td .input { width: 100%; min-width: 7em; }
.sammel-tbl td.sm .input { min-width: 4.5em; width: 6em; }
.sammel-tbl td select.input { min-width: 6.5em; }
.sammel { container-type: inline-size; }
/* Schmal (Handy): jede Zeile als Karte mit beschrifteten Feldern */
@container (max-width: 720px) {
  .sammel .tbl-wrap { overflow: visible; border: 0; background: none; }
  .sammel-tbl, .sammel-tbl tbody { display: block; }
  .sammel-tbl thead { display: none; }
  .sammel-tbl tr { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 10px; background: var(--surface); border: 1px solid var(--line);
    border-radius: var(--radius); padding: 10px 12px 12px; margin-bottom: 12px; box-shadow: var(--shadow); }
  .sammel-tbl td { display: block; padding: 0; border: 0; min-width: 0; text-align: left; }
  .sammel-tbl td.parz { order: 1; } .sammel-tbl td.nr { order: 0; }
  .sammel-tbl td[data-l="Schnitt"] { order: 2; } .sammel-tbl td[data-l="Nutzung"] { order: 3; }
  .sammel-tbl td[data-l="Bestand"] { order: 4; } .sammel-tbl td[data-l="Stadium"] { order: 5; }
  .sammel-tbl td[data-l^="Konservierung"] { order: 6; } .sammel-tbl td[data-l="Lager"] { order: 7; }
  .sammel-tbl td.regen, .sammel-tbl td.ts { order: 8; } .sammel-tbl td[data-l="Höhe"] { order: 9; }
  .sammel-tbl td.breit { order: 10; } .sammel-tbl td.info { order: 11; }
  .sammel-tbl tr[data-art="heu"] td.ts, .sammel-tbl tr[data-art="gras"] td.regen, .sammel-tbl tr[data-art="mais"] td.regen { display: none; }
  .sammel-tbl tr[data-art="mais"] td[data-l="Bestand"], .sammel-tbl tr[data-art="mais"] td[data-l="Stadium"], .sammel-tbl tr[data-art="mais"] td[data-l="Nutzung"] { display: none; }
  .sammel-tbl td[data-l]::before { content: attr(data-l); display: block; font-size: .78rem; font-weight: 650; color: var(--ink-3); margin-bottom: 3px; }
  .sammel-tbl td .input, .sammel-tbl td.sm .input, .sammel-tbl td select.input { width: 100%; min-width: 0; min-height: 44px; font-size: 1rem; }
  .sammel-tbl td.nr { grid-column: 1 / -1; font-weight: 750; color: var(--ink); font-size: 1rem; text-align: left; }
  .sammel-tbl td.nr::before { content: "Probe "; }
  .sammel-tbl td.parz, .sammel-tbl td.breit, .sammel-tbl td.info { grid-column: 1 / -1; }
  .sammel-tbl td.info:empty { display: none; }
}
.sammel-tbl td.nr { color: var(--ink-3); font-size: .85rem; text-align: right; }
.sammel-tbl td.info { min-width: 12em; }
.sammel .actionbar { margin-top: 16px; }

/* Was ist als Nächstes zu tun? – dezent: drei sanfte Pulse, danach feiner Rahmen */
.naechstes { outline: 2px solid rgb(15 127 116 / .45); outline-offset: 3px; border-radius: 14px; animation: naechst 1.8s ease-in-out .5s 3; }
.btn.naechstes { border-radius: var(--radius-s); }
@keyframes naechst { 0%, 100% { box-shadow: 0 0 0 0 rgb(15 127 116 / 0); } 50% { box-shadow: 0 0 0 7px rgb(15 127 116 / .2); } }
:root[data-theme="dark"] .naechstes { outline-color: rgb(63 184 168 / .55); }
@media (prefers-reduced-motion: reduce) { .naechstes { animation: none; } }
.assist-praxis { background: var(--surface-2); border-radius: 12px; padding: 8px 10px; margin: 0 0 8px; font-size: .9rem; }
.assist-praxis b { display: block; font-size: .8rem; text-transform: uppercase; letter-spacing: .04em; color: var(--ink-2); margin-bottom: 2px; }
.assist-praxis p { margin: 0; }
.assist-praxis ol, .assist-liste { margin: 0; padding-left: 1.2em; }
.assist-praxis li + li, .assist-liste li + li { margin-top: 3px; }
.assist-riechen { margin-bottom: 8px; }

/* Grundfutter-Bilanz */
.alert.warn { background: var(--mittel-soft); color: var(--ink); font-weight: 500; border: 1px solid color-mix(in srgb, var(--mittel) 35%, transparent); }
.bl-teil .icon-btn { width: 44px; height: 44px; min-width: 44px; font-size: 1.3rem; }
.bl-wert { min-height: 44px; display: flex; align-items: center; font-weight: 750; font-size: 1.1rem; }
.bl-werte { display: flex; flex-wrap: wrap; gap: 8px 12px; align-items: end; margin-top: 8px; font-size: .9rem; }
.bl-werte > span, .bl-werte > label { display: grid; gap: 2px; min-width: 0; }
.bl-werte > span > span, .bl-werte > label > span { font-size: .75rem; color: var(--ink-3); font-weight: 650; }
.bl-werte .input.sm { width: 5.2em; }
.bars .track { position: relative; }
.bars .ziel { position: absolute; top: -3px; bottom: -3px; width: 2px; background: var(--ink); border-radius: 1px; }
.gb-annahme { display: flex; flex-wrap: wrap; gap: 6px; }
.gb-annahme .input { width: auto; flex: 1 1 140px; min-width: 0; }
.gb-spanne { display: block; width: 100%; height: auto; margin-top: 10px; font-family: var(--font); }
:root { --typ-gruen: #8cbf4f; --typ-gps: #9a6232; }
.item.typ-gruen { box-shadow: inset 5px 0 0 var(--typ-gruen); } .item.typ-gps { box-shadow: inset 5px 0 0 var(--typ-gps); }
.typ-badge.typ-gruen { background: var(--typ-gruen); color: #10201a; } .typ-badge.typ-gps { background: var(--typ-gps); color: #fff; }
.tbl tr.typ-gruen td:first-child { box-shadow: inset 4px 0 0 var(--typ-gruen); } .tbl tr.typ-gps td:first-child { box-shadow: inset 4px 0 0 var(--typ-gps); }
.item.typ-gruen .typ-avatar { background: var(--typ-gruen); color: #10201a; } .item.typ-gps .typ-avatar { background: var(--typ-gps); color: #fff; }
@container (max-width: 720px) {
  .sammel-tbl tr[data-art="gruen"] td.ts, .sammel-tbl tr[data-art="gruen"] td.regen, .sammel-tbl tr[data-art="gps"] td.regen { display: none; }
  .sammel-tbl tr[data-art="gps"] td[data-l="Bestand"], .sammel-tbl tr[data-art="gps"] td[data-l="Stadium"], .sammel-tbl tr[data-art="gps"] td[data-l="Nutzung"] { display: none; }
}

/* Wiese mit Kamera: Vollbild-Kamera und Werkzeuge auf Standbild */
html.cam-offen, html.cam-offen body { overflow: hidden; }
.cam { position: fixed; inset: 0; z-index: 35; background: #000; color: #fff; display: flex; flex-direction: column; }
.cam-buehne { position: relative; flex: 1; min-height: 0; overflow: hidden; touch-action: none; }
.cam-buehne video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transform-origin: center; }
.cam-ov, .cam-bild { position: absolute; inset: 0; width: 100%; height: 100%; }
.cam-ghost { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .45; pointer-events: none; }
.cam-ref { position: absolute; right: 8px; top: 76px; width: min(42%, 260px); max-height: 55%; object-fit: contain; background: #fff; border-radius: 10px; border: 2px solid #fff; box-shadow: 0 4px 18px rgb(0 0 0 / .5); }
.cam-ref[hidden] { display: none; }
.cam-top { position: absolute; left: 0; right: 0; top: 0; display: flex; gap: 10px; align-items: flex-start; padding: max(10px, env(safe-area-inset-top)) 12px 18px; background: linear-gradient(rgb(0 0 0 / .7), transparent); pointer-events: none; }
.cam-top > * { pointer-events: auto; }
.cam-x { flex: none; width: 44px; height: 44px; border-radius: 50%; border: 0; background: rgb(0 0 0 / .55); color: #fff; font-size: 1.25rem; cursor: pointer; }
.cam-t { min-width: 0; font-size: .9rem; line-height: 1.35; text-shadow: 0 1px 3px #000; }
.cam-t > b { display: block; font-size: 1.02rem; }
.cam-t > span { display: block; opacity: .92; }
.cam-info { position: absolute; left: 12px; right: 12px; bottom: 8px; pointer-events: none; text-align: center; }
.cam-info[hidden] { display: none; }
.cam-info:not(:empty), .cam-werkzeug .cam-info:not([hidden]) { padding: 6px 10px; }
.cam-info:not(:empty) { background: rgb(0 0 0 / .6); border-radius: 10px; font-size: .88rem; }
.cam-panel { position: absolute; left: 12px; right: 12px; bottom: 56px; background: rgb(20 20 20 / .92); border-radius: 14px; padding: 12px; display: grid; gap: 8px; }
.cam-panel[hidden] { display: none; }
.cam-panel .row { display: flex; flex-wrap: wrap; gap: 8px; }
.cam-unten { flex: none; background: #111; padding: 8px 10px calc(10px + var(--safe-b)); display: grid; gap: 8px; max-height: 46dvh; overflow-y: auto; }
.cam-werkzeug .cam-info { position: static; background: none; }
.cam-ctrl { display: flex; align-items: center; justify-content: center; gap: 12px; flex-wrap: nowrap; }
.cam-ctrl.wrap { flex-wrap: wrap; gap: 8px; }
.cam-btn { min-height: 44px; padding: 0 14px; border-radius: 12px; border: 1px solid #555; background: #2a2a2a; color: #fff; font-weight: 650; cursor: pointer; }
.cam-btn.primary { background: var(--brand); border-color: var(--brand); color: #fff; }
.cam-btn.on { background: #c9a227; border-color: #c9a227; color: #000; }
.cam-btn:focus-visible, .cam-shot:focus-visible, .cam-x:focus-visible, .cam-kl:focus-visible, .cam-chip:focus-visible { outline: 3px solid #fff; outline-offset: 2px; }
.cam-regler input[type=range] { min-height: 44px; }
.cam-btn:disabled { background: #3a3a3a; color: #c9c9c9; border: 1px dashed #8a8a8a; cursor: not-allowed; }
.cam-btn[hidden] { display: none; }
.cam-shot { flex: none; width: 70px; height: 70px; border-radius: 50%; border: 5px solid #fff; background: rgb(255 255 255 / .25); cursor: pointer; }
.cam-shot:active { background: #fff; }
.cam-shot.on { background: #c9a227; }
.cam-shot[hidden] { display: none; }
.cam-regler { display: flex; align-items: center; gap: 10px; font-size: .85rem; }
.cam-regler[hidden] { display: none; }
.cam-regler input[type=range] { flex: 1; min-width: 0; }
.cam-regler .input { background: #222; color: #fff; border-color: #555; }
.cam-wert { font-size: 1.4rem; font-weight: 800; min-width: 90px; text-align: center; }
.cam-palette { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
.cam-kl { display: flex; align-items: center; gap: 6px; min-height: 44px; padding: 4px 8px; border-radius: 10px; border: 2px solid #444; background: #222; color: #fff; font-size: .82rem; text-align: left; cursor: pointer; }
.cam-kl i { flex: none; width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; font: 700 .75rem/1 var(--font); color: #fff; border: 2px solid #fff; }
.cam-kl b { margin-left: auto; }
.cam-kl.on { border-color: #fff; background: #3a3a3a; }
.cam-chips { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; scroll-snap-type: x mandatory; }
.cam-chip { flex: none; width: 112px; scroll-snap-align: start; display: grid; gap: 4px; padding: 4px; border-radius: 10px; border: 2px solid #444; background: #222; color: #fff; font-size: .72rem; line-height: 1.2; text-align: left; cursor: pointer; }
.cam-chip img, .cam-chip .ohne { width: 100%; height: 72px; object-fit: contain; border-radius: 6px; background: #fff; }
.cam-chip .ohne { display: grid; place-items: center; background: #333; color: #aaa; }
.cam-chip.on { border-color: #c9a227; }
.cmp img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.cmp-linie { position: absolute; top: 0; bottom: 0; width: 3px; margin-left: -1px; background: #fff; box-shadow: 0 0 6px #000; pointer-events: none; }
.cmp-regler { width: 100%; }
.cam select.input { background: #222; color: #fff; border-color: #555; }
@media (max-width: 400px) { .cam-palette { grid-template-columns: repeat(2, minmax(0, 1fr)); } .cam-shot { width: 62px; height: 62px; } }

.wi-inline { display: flex; flex-wrap: wrap; gap: 8px 12px; align-items: center; margin: 0 0 14px; }
.wi-inline .btn svg { width: 20px; height: 20px; }
.wi-balken { display: flex; height: 22px; border-radius: 8px; overflow: hidden; margin: 6px 0; background: var(--surface-2); }
.wi-legende { display: flex; flex-wrap: wrap; gap: 4px 12px; font-size: .78rem; color: var(--ink-2); margin-bottom: 10px; }
.wi-legende i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 4px; vertical-align: -1px; }
.wi-vorschlag { display: flex; gap: 12px; align-items: center; padding: 10px 12px; border-radius: 12px; background: var(--brand-soft); margin: 8px 0; }
.wi-vorschlag .lead { font-size: 1.4rem; font-weight: 800; min-width: 44px; text-align: center; }
.wi-tab { width: 100%; border-collapse: collapse; font-size: .9rem; margin-bottom: 8px; }
.wi-tab td { padding: 4px 0; border-bottom: 1px solid var(--line); }
.wi-tab td:last-child { text-align: right; font-variant-numeric: tabular-nums; }
.alert.warn { background: var(--mittel-soft); color: var(--ink); font-weight: 500; }
.wi-gross { font-size: 2.2rem; font-weight: 800; margin: 4px 0; }
.fp-mini { width: 44px; height: 44px; border-radius: 10px; object-fit: cover; flex: none; }

.pflanzen .pf-m { margin-bottom: 14px; }
.pf-kopf { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.pf-w { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 132px), 1fr)); gap: 6px; }
.pf-opt { display: grid; justify-items: center; gap: 2px; padding: 8px 6px; min-height: 48px; border-radius: 12px; border: 1px solid var(--line-strong); background: var(--surface); color: var(--ink); font-size: .84rem; text-align: center; cursor: pointer; position: relative; }
.pf-opt small { position: absolute; top: 4px; right: 7px; font-size: .7rem; color: var(--ink-3); }
.pf-opt[aria-pressed="true"] { border: 2px solid var(--brand); background: var(--brand-soft); }
.pf-opt:disabled { background: var(--disabled-bg); color: var(--disabled-ink); border: 1px dashed var(--line-strong); cursor: not-allowed; }
.pf-opt svg { color: var(--brand-ink); }
.pf-treffer { border-top: 2px solid var(--line); padding-top: 10px; display: grid; gap: 8px; }
.pf-art { padding: 10px 12px; border-radius: 12px; background: var(--surface-2); display: grid; gap: 4px; }
.pf-art .chip { margin-left: 6px; }
.pf-art .btn { justify-self: start; margin-top: 4px; }
.cam-werkzeug .cam-top { position: static; order: -1; background: #111; padding-bottom: 8px; }
.cam-werkzeug .cam-t { text-shadow: none; }
.pf-tabs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; margin-bottom: 10px; }
@media (min-width: 640px) { .pf-tabs { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.pf-tabs button { min-height: 44px; display: inline-flex; align-items: center; justify-content: center; border-radius: 10px; border: 1px solid var(--line-strong); background: var(--surface); color: var(--ink-2); font-weight: 650; font-size: .88rem; cursor: pointer; }
.pf-tabs button[aria-pressed="true"] { background: var(--brand); border-color: var(--brand); color: var(--on-brand); }
.pf-pfad { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-bottom: 8px; }
.pf-krume { border: 0; background: var(--brand-soft); color: var(--brand-ink); border-radius: 99px; padding: 5px 11px; min-height: 32px; font-size: .8rem; font-weight: 650; cursor: pointer; text-align: left; }
.pf-krume.start { background: var(--surface-2); color: var(--ink-2); }
.pf-krume + .pf-krume::before { content: '› '; }
.pf-pfad .btn { margin-left: auto; }
.pf-reihe { font-weight: 650; font-size: .9rem; margin: 0 0 10px; }
.pf-spalten { display: grid; gap: 8px; }
.pf-spalte { display: flex; gap: 12px; align-items: center; text-align: left; padding: 12px 14px; min-height: 56px; border-radius: 12px; border: 1px solid var(--line-strong); background: var(--surface); color: var(--ink); cursor: pointer; }
.pf-spalte small { display: block; color: var(--ink-3); font-size: .8rem; margin-top: 2px; }
.pf-nr { flex: none; min-width: 34px; height: 34px; padding: 0 6px; border-radius: 50%; display: grid; place-items: center; background: var(--brand); color: var(--on-brand); font-weight: 800; font-size: .85rem; }
.pf-frage { font-weight: 700; margin: 12px 0 6px; }
.pf-krit { display: grid; gap: 6px; }
.pf-krit .pf-opt { justify-items: start; text-align: left; padding: 12px 54px 12px 14px; font-size: .92rem; }
.pf-krit .pf-opt small { top: 50%; transform: translateY(-50%); right: 12px; }
.pf-art { margin-bottom: 8px; }
.pf-art-kopf { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.pf-art-kopf .chip { margin-left: 0; }
.pf-sym { color: var(--brand-ink); display: inline-grid; }
.pf-weg { font-size: .74rem; }
.pf-ic { width: 40px; height: 40px; object-fit: contain; flex: none; border-radius: 6px; background: #f1f1f1; }
.pf-spalte .pf-ic { width: 46px; height: 46px; }
.pf-krit .pf-opt { grid-template-columns: auto 1fr; display: grid; align-items: center; column-gap: 10px; }
.pf-krit .pf-opt:not(:has(.pf-ic)) { grid-template-columns: 1fr; }
.pf-bilder { display: flex; gap: 6px; overflow-x: auto; padding: 4px 0; }
.pf-bild { flex: none; width: 76px; height: 96px; padding: 0; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; background: #fff; cursor: pointer; }
.pf-bild img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pf-bild.zg img { object-fit: contain; background: #f1f1f1; }
.pf-gross { background: #f1f1f1; }
.pf-x { color: var(--ink); background: var(--mittel-soft); border-radius: 8px; padding: 4px 8px; }
.pf-eagff summary { cursor: pointer; font-size: .85rem; font-weight: 650; color: var(--brand-ink); }
.ext a { display: inline-block; padding: 10px 0; }
.ext li { padding: 2px 0; }
.pf-eagff p { margin: 6px 0; }
.hilfe ul.doks, .hilfe ul.ext { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.doks a { display: flex; gap: 12px; align-items: center; padding: 10px 12px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); color: var(--ink); text-decoration: none; }
.doks a > span:last-child { display: grid; gap: 2px; min-width: 0; }
.doc-ico { flex: none; width: 40px; height: 48px; border-radius: 6px; display: grid; place-items: center; background: var(--kritisch-soft); color: var(--kritisch-text); font: 800 .72rem/1 var(--font); }
.ext a { color: var(--brand-ink); }
.pool-karten { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 250px), 1fr)); gap: 10px; }
.pool-link { display: grid; gap: 4px; color: var(--ink); text-decoration: none; }
.pool-karte { display: grid; gap: 8px; padding: 12px 14px; border-radius: var(--radius); border: 1px solid var(--line); background: var(--surface); color: var(--ink); text-decoration: none; box-shadow: var(--shadow); }
.pool-karte:hover { border-color: var(--brand); }
.pool-kopf { display: flex; gap: 8px; align-items: center; }
.pool-kpi { display: flex; gap: 14px; margin-top: 4px; }
.pool-kpi span { display: grid; line-height: 1.1; }
.pool-kpi b { font-size: 1.1rem; }
.pool-lab td.num { text-align: right; }
.chip.muster { background: #5b3fc4; color: #fff; font-weight: 800; letter-spacing: .02em; }
.muster-text { color: #5b3fc4; }
:root[data-theme="dark"] .muster-text { color: #b6a6ff; }
.aw-knopf.drin { color: #5b3fc4; border-color: #5b3fc4; }
.aw-pille { position: fixed; left: 12px; bottom: calc(78px + var(--safe-b)); z-index: 31; border: 0; border-radius: 99px; padding: 10px 16px; background: #5b3fc4; color: #fff; font-weight: 750; box-shadow: var(--shadow); cursor: pointer; }
.aw-liste li { display: flex; gap: 10px; align-items: center; padding: 6px 0; border-bottom: 1px solid var(--line); }
.aw-art { flex: none; font-size: .72rem; font-weight: 800; padding: 2px 8px; border-radius: 99px; background: var(--surface-2); }
.aw-liste .grow { flex: 1; min-width: 0; }
.tier-umschalter { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-top: 14px; }
.tier-schalter { display: flex; align-items: center; gap: 10px; padding: 10px 12px; min-height: 64px; border: 2px solid var(--line-strong); border-radius: var(--radius); background: var(--surface); color: var(--ink); cursor: pointer; text-align: left; }
.tier-schalter[aria-pressed="true"] { border-color: var(--brand); background: var(--brand-soft); box-shadow: inset 0 0 0 1px var(--brand); }
.tier-schalter:disabled { background: var(--disabled-bg); color: var(--disabled-ink); border-style: dashed; cursor: not-allowed; }
.tier-schalter:disabled .tier-txt small { color: var(--disabled-ink); }
.tier-ico { font-size: 2.1rem; line-height: 1; flex: none; }
.tier-txt { display: grid; line-height: 1.2; min-width: 0; }
.tier-txt b { font-size: 1.05rem; }
.tier-txt small { color: var(--ink-2); font-size: .85rem; }
.tier-kasten { margin-top: 10px; }
.tier-btn { margin-top: 10px; }
.card > .row:first-child { flex-wrap: wrap; row-gap: 8px; }
.actionbar .rad-zurueck { flex: 0 0 auto; min-width: 52px; padding: 0 12px; }
.split-btn { flex: 1; display: flex; gap: 2px; min-width: 0; }
.split-btn .btn.primary { flex: 1; display: grid; justify-items: center; line-height: 1.15; border-radius: var(--radius) 4px 4px var(--radius); min-width: 0; }
.split-btn .split-haupt { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.split-btn .btn.primary small { font-size: .72rem; opacity: .85; font-weight: 600; }
.split-btn .split-neben { flex: 0 0 auto; border-radius: 4px var(--radius) var(--radius) 4px; padding: 0 12px; font-size: .86rem; }
.pf-baum { display: grid; gap: 8px; }
.pf-knoten { display: grid; gap: 6px; }
.pf-spalte .grow { flex: 1; min-width: 0; }
.pf-spalte[aria-expanded="true"], .pf-zweig[aria-expanded="true"] { border-color: var(--brand); background: var(--brand-soft); }
.pf-pfeil { flex: none; color: var(--brand-ink); font-size: 1rem; width: 1em; text-align: center; }
.pf-ast { margin-left: 10px; padding-left: 8px; border-left: 3px solid var(--brand-soft); display: grid; gap: 6px; }
.pf-zweig { display: grid !important; grid-template-columns: auto auto 1fr; align-items: center; column-gap: 8px; justify-items: start; text-align: left; padding: 10px 54px 10px 10px !important; position: relative; }
.pf-zweig:not(:has(.pf-ic)) { grid-template-columns: auto 1fr; }
.pf-zweig small { position: absolute; top: 50%; right: 12px; transform: translateY(-50%); }
.pf-namen { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.pf-name { width: 100%; min-height: 44px; display: flex; align-items: center; gap: 8px; padding: 8px 10px; border-radius: 10px; border: 1px dashed var(--line-strong); background: var(--surface); color: var(--ink); cursor: pointer; text-align: left; }
.pf-name[aria-expanded="true"] { border-style: solid; border-color: var(--brand); }
.pf-portraet { margin: 6px 0 4px; }
.pf-portraet .pf-art-kopf > b, .pf-portraet .pf-art-kopf > .pf-sym { display: none; }
/* Suchknopf (Lupe) rechts unten angeheftet (nur der Knopf), Quellenangabe steht statisch am Ende des Inhalts (davor, mit Abstand unter dem letzten Text);
   die Zeile des Knopfs hat eigene Höhe, so überdeckt er am Ende des Inhalts keinen Text. Handy: über der Fusszeile */
.pf-such-dock { position: sticky; bottom: calc(8px + var(--safe-b) + var(--fuss)); z-index: 32; display: flex; align-items: flex-end; justify-content: flex-end; min-height: 66px; margin-top: 2px; padding: 6px 0 2px; pointer-events: none; }
.pf-such-dock > * { pointer-events: auto; }
.pf-fuss { font-size: .78rem; line-height: 1.4; color: var(--ink-3); text-align: left; text-wrap: pretty; }
.pf-fuss a { color: inherit; text-decoration: underline; padding: 6px 0; }
p.pf-fuss { margin: 22px 0 0; padding-top: 10px; border-top: 1px solid var(--line); }
.pf-such-badge { flex: none; width: 54px; height: 54px; border-radius: 50%; border: 0; background: var(--brand); color: var(--on-brand); display: grid; place-items: center; box-shadow: 0 4px 14px rgb(0 0 0 / .25); cursor: pointer; }
.pf-such-dock.offen { display: grid; gap: 6px; width: 100%; min-height: 0; pointer-events: auto; padding: 18px 0 6px; background: var(--pf-dock-bg, var(--bg)); border-top: 1px solid var(--line); }
.sheet .pf-such-dock { --pf-dock-bg: var(--surface); bottom: 0; }
.pflanzen { padding-bottom: 6px; }
.pf-fotos-knopf .pf-pfeil { margin-right: 5px; }
.pf-such-feld { display: flex; align-items: center; gap: 6px; background: var(--surface); border: 2px solid var(--brand); border-radius: 99px; padding: 4px 6px 4px 14px; box-shadow: 0 4px 14px rgb(0 0 0 / .2); color: var(--brand-ink); }
.pf-such-feld .input { border: 0; background: transparent; min-height: 40px; flex: 1; min-width: 0; padding: 0 4px; box-shadow: none; }
.pf-such-ergebnis { max-height: min(55vh, 520px); overflow-y: auto; background: var(--surface); border: 1px solid var(--line-strong); border-radius: var(--radius); box-shadow: 0 6px 20px rgb(0 0 0 / .18); padding: 8px 10px; }
.pf-such-ergebnis ul { list-style: none; margin: 0 0 6px; padding: 0; display: grid; gap: 4px; }
.pf-such-tipp { margin: 4px 2px; }
.pf-treffer-zeile { width: 100%; display: grid; gap: 2px; text-align: left; padding: 8px 10px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); cursor: pointer; }
.pf-treffer-zeile:hover, .pf-treffer-zeile:focus-visible { border-color: var(--brand); }
.pf-tz-kopf { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.pf-tz-merkmal { color: var(--ink-2); }
.pflanzen mark { background: #fde68a; color: inherit; border-radius: 3px; padding: 0 1px; }
:root[data-theme="dark"] .pflanzen mark { background: #8a6d00; }
.pf-blink { animation: pfBlink 1.6s ease-out 1; }
@keyframes pfBlink { 0%, 40% { box-shadow: 0 0 0 4px #fde68a; } 100% { box-shadow: none; } }
.pf-such-feld .input:focus, .pf-such-feld .input:focus-visible { outline: none; box-shadow: none; border: 0; }
.pf-such-feld:focus-within { box-shadow: 0 0 0 3px var(--brand-soft), 0 4px 14px rgb(0 0 0 / .2); }
.app-umschalter { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; padding: 8px 12px 0; }
.app-knopf { display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; border-radius: 12px; border: 2px solid var(--line); background: var(--surface-2); color: var(--ink-2); font-weight: 750; cursor: pointer; }
.app-knopf[aria-pressed="true"] { background: #facc15; border-color: #eab308; color: #1f2937; box-shadow: 0 2px 8px rgb(234 179 8 / .35); }
.app-knopf:not([aria-pressed="true"]):hover { border-color: var(--brand); color: var(--ink); }
.app-mini { display: inline-flex; gap: 2px; padding: 2px; border-radius: 10px; background: var(--surface-2); margin-left: auto; flex: none; }
.bar > .app-mini { order: 99; }
.app-mini-k { width: 36px; height: 34px; display: grid; place-items: center; border: 0; border-radius: 8px; background: transparent; color: var(--ink-3); cursor: pointer; }
.app-mini-k[aria-pressed="true"] { background: #facc15; color: #1f2937; }

/* Tastaturkürzel: Ctrl halten blendet Schildchen ein */
html.kb-hinweise [data-kb] { position: relative; }
html.kb-hinweise [data-kb]::after { content: attr(data-kb); position: absolute; top: -8px; left: -6px; z-index: 5; min-width: 20px; padding: 2px 6px; border-radius: 6px; background: #facc15; color: #1f2937; font: 800 .74rem/1.2 var(--font); box-shadow: 0 1px 4px rgb(0 0 0 / .3); pointer-events: none; text-align: center; }
.kb-tab kbd { display: inline-block; min-width: 1.6em; padding: 1px 6px; border: 1px solid var(--line-strong); border-bottom-width: 2px; border-radius: 6px; background: var(--surface-2); font: 700 .82rem var(--font); text-align: center; }
.kb-tab td:last-child { text-align: left; }

/* Fotopunkt: zum Standort führen */
.fp-fuehren .cam-top { position: static; background: #111; }
.fp-nav { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; padding: 12px 16px max(16px, env(safe-area-inset-bottom)); text-align: center; }
.fp-nav-phase { font-weight: 700; font-size: 1.05rem; color: #ffd84d; }
.fp-nav-rose { position: relative; width: min(64vw, 260px); aspect-ratio: 1; border-radius: 50%; border: 2px solid rgb(255 255 255 / .25); display: grid; place-items: center; }
.fp-nav-pfeil { width: 72%; height: 72%; fill: #ffd84d; transition: transform .35s ease-out; }
.fp-nav-n { position: absolute; left: 50%; top: 50%; margin: -11px 0 0 -9px; width: 18px; font-weight: 700; color: #ff6b6b; transition: transform .35s ease-out; }
.fp-da .fp-nav-pfeil { fill: #8fd3ff; }
.fp-passt .fp-nav-pfeil { fill: #6fdc8c; }
.fp-passt .fp-nav-rose { border-color: #6fdc8c; }
.fp-nav-dist { font-size: 2.6rem; font-weight: 800; line-height: 1; }
.fp-nav-text { max-width: 34ch; }
.fp-nav-klein { font-size: .8rem; opacity: .7; }
.fp-nav-knoepfe { margin-top: 6px; }
.fp-mini-pfeil { width: 1.05em; height: 1.05em; vertical-align: -.15em; display: inline-block; }

/* Wiesenaufnahme (AGFF-Merkblatt 8) */
.aufnahme .au-nav { display: flex; gap: 6px; flex-wrap: wrap; position: sticky; top: calc(var(--kopf-h) + 56px); z-index: 2; background: var(--bg); padding: 6px 0; margin-bottom: 4px; }
.aufnahme .au-zeile { display: grid; grid-template-columns: minmax(min(130px, 100%), 32%) minmax(0, 1fr); gap: 6px 12px; align-items: center; padding: 6px 0; border-bottom: 1px solid var(--line); }
.aufnahme .au-z-t { font-size: .88rem; display: flex; flex-direction: column; gap: 2px; }
.aufnahme .au-seg { flex-wrap: wrap; }
.aufnahme .au-seg button { min-height: 44px; font-size: .82rem; }
.aufnahme .au-step { display: inline-flex; align-items: center; gap: 8px; }
.aufnahme .au-step b { min-width: 46px; text-align: center; }
.aufnahme .au-step .btn { min-width: 44px; min-height: 44px; padding: 0 8px; }
.aufnahme .au-kreise { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 10px; margin-bottom: 8px; }
.aufnahme .au-kreis { border: 1px solid var(--line); border-radius: var(--radius-s, 10px); padding: 8px; display: flex; flex-direction: column; gap: 2px; }
.aufnahme .au-kreis .au-zeile { grid-template-columns: 60px 1fr; padding: 3px 0; border: 0; }
.aufnahme .au-mittel { background: var(--surface-2); }
.aufnahme .au-kats { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(260px, 100%), 1fr)); gap: 10px; }
.aufnahme .au-kat { border: 1px solid var(--line); border-radius: var(--radius-s, 10px); padding: 8px; }
.aufnahme .au-kat-kopf { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 4px; }
.aufnahme .au-art { display: flex; align-items: center; gap: 6px; padding: 3px 0; }
.aufnahme .au-art-n { flex: 1; min-width: 0; font-size: .88rem; }
.aufnahme .au-weg-btn { width: 44px; height: 44px; font-size: 1.3rem; }
.aufnahme .au-zeiger { font-size: .68rem; padding: 0 6px; }
.aufnahme .au-warn { color: var(--schlecht-text); font-weight: 600; }
.aufnahme .au-wert { font-weight: 700; }
.aufnahme .au-h4 { margin: 14px 0 6px; font-size: .95rem; }
.aufnahme .au-hinweise { margin: 4px 0 8px; padding-left: 18px; }
.aufnahme .au-ziel { display: grid; grid-template-columns: 110px 1fr 130px; gap: 10px; align-items: center; margin: 6px 0; font-size: .88rem; }
.aufnahme .au-ziel-bar { position: relative; height: 12px; border-radius: 6px; background: var(--surface-2); }
.aufnahme .au-ziel-soll { position: absolute; top: 0; bottom: 0; background: var(--gut-soft); border-radius: 6px; }
.aufnahme .au-ziel-ist { position: absolute; top: -3px; bottom: -3px; width: 4px; border-radius: 2px; background: var(--schlecht); }
.aufnahme .au-ziel-ist.ok { background: var(--gut); }
.aufnahme .au-chips-titel { font-weight: 600; font-size: .88rem; margin: 12px 0 6px; }
.au-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.au-chip { cursor: pointer; border: 1px solid var(--line-strong); background: var(--surface); min-height: 44px; }
.au-chip[aria-pressed="true"] { background: var(--brand); color: var(--on-brand); border-color: var(--brand); }
.aufnahme .au-massn { margin: 6px 0; padding-left: 18px; }
.aufnahme .au-vorschlag { border-left: 3px solid var(--brand); padding: 4px 10px; margin: 4px 0 12px; background: var(--surface-2); border-radius: 0 8px 8px 0; }
.aufnahme .au-vorschlag ul { margin: 4px 0 6px; padding-left: 18px; }
.aufnahme .au-vergleich td, .aufnahme .au-vergleich th { text-align: center; }
.aufnahme .au-jetzt { font-weight: 700; }
.aufnahme .au-weg { padding-left: 20px; }
.aufnahme .au-weg li { margin: 8px 0; }
.aufnahme .au-weg li span { display: block; font-size: .85rem; color: var(--ink-2); }
.au-wahl { display: flex; flex-direction: column; gap: 6px; max-height: 55vh; overflow: auto; }
.au-wahl-art { text-align: left; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); padding: 8px 10px; cursor: pointer; display: flex; flex-direction: column; gap: 2px; color: inherit; }
.au-wahl-art:disabled { background: var(--disabled-bg); color: var(--disabled-ink); border-style: dashed; cursor: not-allowed; }
@container (max-width: 560px) { .aufnahme .au-zeile { grid-template-columns: 1fr; } .aufnahme .au-ziel { grid-template-columns: 90px 1fr; } .aufnahme .au-ziel > span:last-child { grid-column: 1 / -1; } }

@media (max-width: 600px) { .aufnahme .au-zeile { grid-template-columns: 1fr; } .aufnahme .au-ziel { grid-template-columns: 90px 1fr; } .aufnahme .au-ziel > span:last-child { grid-column: 1 / -1; } }
.aufnahme section.q { scroll-margin-top: calc(var(--kopf-h) + 64px); }

/* ---- UX-Quick-Wins (b1-81) ---- */
/* Mindestschrift für Nebentexte, Hinweise in voller Grösse */
.item .s, .bar .sub { font-size: .875rem; }
.tbl thead th { font-size: .8rem; color: var(--ink-2); }
.hint, .qhint { font-size: 1rem; }
.chip { font-size: .85rem; }
/* Druckrückmeldung ohne Hover (Touch) */
.btn:active, .step-chip:active, .au-chip:active, .icon-btn:active, .seg button:active { transform: scale(.97); }
/* Touch: alle «kleinen» Bedienelemente auf Tippgrösse, mehr Abstand gegen Fehltreffer */
@media (pointer: coarse) {
  .btn.sm, .step-chip, .au-chip, .seg.sm button, .factor-nav button, .aufnahme .au-seg button, .au-weg-btn, .code6-einf { min-height: var(--tap); }
  .icon-btn { width: var(--tap); height: var(--tap); }
  .au-chips, .row, .seg, .steps { gap: 8px; }
  .au-chip { padding: 0 14px; }
}
:root[data-outdoor="1"] .btn.sm, :root[data-outdoor="1"] .step-chip, :root[data-outdoor="1"] .au-chip { min-height: 56px; }
/* Dialog mit ungespeicherten Eingaben: Wackeln statt Schliessen */
@keyframes wackeln { 0%, 100% { transform: translateX(0); } 20% { transform: translateX(-7px); } 40% { transform: translateX(7px); } 60% { transform: translateX(-5px); } 80% { transform: translateX(5px); } }
.sheet.wackeln { animation: wackeln .35s; }
@media (prefers-reduced-motion: reduce) { .sheet.wackeln { animation: none; outline: 3px solid var(--schlecht); } }
/* Fehlermeldungen: auffällig und länger sichtbar */
#toast .t.fehler { background: #a8271f; color: #fff; font-weight: 600; }

.doc .kurz { background: var(--brand-soft); border-left: 4px solid var(--brand); border-radius: 8px; padding: 12px 16px; margin: 0 0 20px; }
.doc .kurz ul { margin: 6px 0 0; padding-left: 20px; }
input[aria-invalid="true"] { border-color: var(--schlecht-text); border-width: 2px; box-shadow: 0 0 0 2px var(--schlecht-soft); }
.feld-fehler { margin: 6px 0 0; font-size: .9rem; font-weight: 650; color: var(--schlecht-text); }
.au-z-i .feld-fehler { margin-top: 4px; }

/* Modus «Wiese» (feste Einstellung der Pratum-Seite) */
.app-zu-futter { display: flex; align-items: center; gap: 8px; margin: 0 12px 8px; padding: 8px 12px; min-height: 44px; border: 1px solid var(--line); border-radius: 12px; color: var(--ink-2); text-decoration: none; font-size: .9rem; }
.app-zu-futter svg { width: 20px; height: 20px; }
.app-zu-futter span:nth-of-type(1) { flex: 1; }
.app-zu-futter:hover { background: var(--surface-2); }
html[data-modus="wiese"] #main .bar { padding-right: 12px; }

.wi-schritte { margin: 0; padding-left: 22px; } .wi-schritte li { margin: 6px 0; } .wi-schritte li span { display: block; color: var(--ink-2); font-size: .9rem; }
.aufnahme .au-fp { border: 1px dashed var(--line-strong); border-radius: 14px; background: var(--surface); padding: 12px 14px; }
.aufnahme .au-fp .h-q { margin: 0 0 6px; } .aufnahme .au-fp p { margin: 0 0 8px; } .aufnahme .au-fp .row { gap: 8px; }
.au-opt { font-size: .75rem; font-weight: 600; color: var(--ink-2); border: 1px solid var(--line); border-radius: 999px; padding: 1px 8px; margin-left: 6px; vertical-align: 2px; }

/* Pendenzen (Admin und Expertenseite) */
.pend.erledigt { opacity: .75; } .pend.korrektur { border-left: 4px solid var(--mittel); } .pend.offen { border-left: 4px solid var(--brand); }
.pend summary { cursor: pointer; } .pend ul { margin: 4px 0; padding-left: 20px; }
.tp-tab td { vertical-align: top; white-space: pre-wrap; font-size: .9rem; } .tp-tab .tp-gruppe td { background: var(--surface-2); }
.tp-fehlt { color: var(--kritisch); font-style: italic; } .tp h3 { scroll-margin-top: 70px; margin-top: 22px; }
.la-beta { display: inline-block; vertical-align: 3px; margin: 0 6px 0 0; padding: 2px 8px; border-radius: 999px; background: #f6c35b; color: #3a2a00; font-size: .7rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.la-beta-band { background: #fff3cd; color: #4a3800; border: 1px solid #f0d27a; border-left: 6px solid #f0b429; border-radius: 10px; padding: 8px 12px; margin: 0 0 12px; font-size: .9rem; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .la-beta-band { background: #3a3014; color: #fbe8b0; border-color: #6b5520; } }
:root[data-theme="dark"] .la-beta-band { background: #3a3014; color: #fbe8b0; border-color: #6b5520; }
.au-eag { font-size: .72rem; font-weight: 600; color: var(--brand-ink); white-space: nowrap; margin-left: 4px; }
.app-zu-futter.app-unten { margin: 4px 12px 24px; }
/* Checkliste Konservierbarkeit */
.kb-verfahren { display: flex; flex-wrap: wrap; gap: 8px; }
.chip-btn { min-height: 44px; padding: 6px 14px; border: 1px solid var(--line-strong); border-radius: 999px; background: var(--surface); color: var(--ink); font: inherit; cursor: pointer; }
.chip-btn[aria-pressed="true"] { background: var(--brand); border-color: var(--brand); color: var(--on-brand); font-weight: 600; }
.kb-h { margin: 4px 0 6px; font-size: .95rem; }
.kb-liste { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.kb-item, .kb-abl { display: flex; gap: 10px; align-items: flex-start; justify-content: space-between; padding: 10px 12px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); flex-wrap: wrap; }
.kb-abl { justify-content: flex-start; }
.kb-text { flex: 1 1 260px; min-width: 0; }
.kb-m { margin-top: 4px; color: var(--ink-2); }
.kb-q { display: block; margin-top: 3px; font-size: .75rem; color: var(--ink-3); }
.kb-wahl { display: flex; gap: 4px; flex-shrink: 0; }
.kb-btn { min-height: 44px; min-width: 56px; padding: 4px 10px; border: 1px solid var(--line-strong); border-radius: 10px; background: var(--surface); color: var(--ink); font: inherit; font-size: .9rem; cursor: pointer; }
.kb-btn.ja[aria-pressed="true"] { background: var(--gut-strong); border-color: var(--gut-strong); color: #fff; }
.kb-btn.nein[aria-pressed="true"] { background: #b3322b; border-color: #b3322b; color: #fff; }
.kb-btn.offen[aria-pressed="true"] { background: var(--surface-2); border-color: var(--ink-3); font-weight: 600; }
.kb-punkt { width: 12px; height: 12px; border-radius: 50%; margin-top: 5px; flex-shrink: 0; background: var(--line-strong); }
.kb-punkt.gut { background: var(--gut); } .kb-punkt.mittel { background: var(--mittel); } .kb-punkt.schlecht { background: var(--kritisch); }
.kb-ergebnis { border-left: 5px solid var(--line-strong); } .kb-ergebnis.gut { border-left-color: var(--gut); } .kb-ergebnis.mittel { border-left-color: var(--mittel); } .kb-ergebnis.schlecht { border-left-color: var(--kritisch); }
.kb-offen { margin: 6px 0 0; padding-left: 18px; }
.badge-betatest { display: inline-block; margin-left: 6px; padding: 1px 7px; border-radius: 999px; background: #f6c35b; color: #3a2a00; font-size: .66rem; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; vertical-align: 2px; }

/* Start «Wiesen»: ein grosser Knopf, zwei kleine, dann die Liste */
.start .btn.gross { min-height: 60px; font-size: 1.1rem; border-radius: 16px; }
.start-klein { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-top: 10px; }
.start-klein .btn { padding: 0 10px; line-height: 1.15; text-align: center; }
.start-klein .btn svg { width: 18px; height: 18px; flex: none; }
.item .avatar svg { width: 22px; height: 22px; }
.start-titel { font-size: 1.15rem; margin: 26px 0 8px; }
.filter { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 4px; }
a.chip-btn { display: inline-flex; align-items: center; text-decoration: none; }
a.chip-btn[aria-current="true"] { background: var(--brand); border-color: var(--brand); color: var(--on-brand); font-weight: 600; }
.start .section-title { margin: 18px 4px 4px; text-transform: none; letter-spacing: 0; font-size: .9rem; }
.start .empty { padding: 24px 4px; text-align: left; font-size: 1.02rem; }
.item .meta.small { white-space: nowrap; }
.item .avatar { background: var(--surface-2); color: var(--ink-2); }
button.item { width: 100%; text-align: left; background: none; border: 1px solid transparent; font: inherit; color: inherit; cursor: pointer; }
.werkzeuge .item { border-color: var(--line); background: var(--surface); margin-bottom: 8px; }
.werkzeuge .item:hover { background: var(--surface-2); }
.werkzeuge .avatar { color: var(--brand-ink); background: var(--brand-soft); }
.werkzeuge .item .s { white-space: normal; }
.badge-betatest { font-size: .62rem; padding: 1px 6px; margin-left: 0; vertical-align: 0; }
.hilfe #daten { scroll-margin-top: calc(var(--kopf-h) + 12px); margin-top: 30px; outline: none; }
.hilfe .app-zu-futter { margin: 12px 0 0; }

/* «Neu»-Menü */
.neu-liste { display: grid; gap: 8px; }
.neu-eintrag { display: flex; align-items: center; gap: 14px; width: 100%; min-height: 64px; padding: 10px 14px; border-radius: 14px; border: 1.5px solid var(--line-strong); background: var(--surface); color: var(--ink); text-align: left; cursor: pointer; font: inherit; }
.neu-eintrag:hover { border-color: var(--brand); }
.neu-eintrag b { display: block; font-size: 1.05rem; }
.neu-eintrag small { display: block; color: var(--ink-3); font-size: .86rem; }
.neu-eintrag.haupt { background: var(--brand); border-color: var(--brand); color: var(--on-brand); min-height: 72px; }
.neu-eintrag.haupt small { color: inherit; }
.neu-ico { flex: none; width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand-ink); }
.neu-eintrag.haupt .neu-ico { background: rgb(255 255 255 / .2); color: inherit; }
.neu-ico svg { width: 24px; height: 24px; }

/* Hinweis oben im Schlüssel: Kurzzeile, voller Text klappt auf */
.pf-hin { margin: 0 0 10px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface-2); }
.pf-hin.warn { border-color: var(--mittel); background: var(--mittel-soft); }
.pf-hin-knopf { width: 100%; display: flex; align-items: center; gap: 8px; min-height: 44px; padding: 6px 12px; border: 0; background: transparent; color: var(--ink); font: inherit; font-size: .9rem; font-weight: 650; text-align: left; cursor: pointer; border-radius: 12px; }
.pf-hin-t { flex: 1; min-width: 0; }
.pf-hin-i { flex: none; color: var(--ink-3); font-weight: 500; white-space: nowrap; }
.pf-hin-warn { flex: none; color: var(--mittel); }
.pf-hin-trieb { flex: none; color: var(--ink-2); }
.pf-hin-voll { padding: 0 12px 12px; display: grid; gap: 8px; justify-items: start; font-size: .9rem; }
.pf-hin-voll p { margin: 0; }
.pf-hin-voll .pf-reihe { margin: 0; }
/* «Im Detail»: ruhige, waagrecht scrollbare Leiste mit Detailzeichnungen (weisse Kachel auch im Dunkelmodus) */
.pf-det { background: var(--surface-2); border-radius: 10px; padding: 6px 8px 8px; margin: 4px 0; min-width: 0; }
.pf-det-kopf { display: flex; flex-wrap: wrap; gap: 2px 8px; align-items: baseline; font-size: .74rem; color: var(--ink-3); margin-bottom: 4px; }
.pf-det-kopf b { color: var(--ink-2); font-weight: 700; }
.pf-det-reihe { display: flex; gap: 8px; overflow-x: auto; align-items: flex-start; padding-bottom: 4px; scrollbar-width: thin; overscroll-behavior-x: contain; }
.pf-det-bild { flex: none; display: grid; justify-items: center; gap: 3px; padding: 0; border: 0; background: transparent; color: var(--ink-2); cursor: pointer; max-width: 150px; }
.pf-det-img { display: block; background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 3px; }
.pf-det-img img { display: block; height: 92px; width: auto; max-width: 144px; object-fit: contain; }
.pf-det-cap { font-size: .68rem; line-height: 1.15; text-align: center; max-width: 100%; overflow-wrap: anywhere; }
.pf-det-mehr { flex: none; align-self: center; min-height: 44px; padding: 6px 12px; border-radius: 99px; border: 1px solid var(--line-strong); background: var(--surface); color: var(--ink-2); font-size: .78rem; cursor: pointer; white-space: nowrap; }
.pf-bild.zg img, .pf-gross { background: #fff; }
/* «Fotos (eAGFF)»: kleiner Textknopf, standardmässig zu */
.pf-fotos { margin: 2px 0 4px; }
.pf-fotos-knopf { border: 0; background: transparent; color: var(--ink-3); font: inherit; font-size: .78rem; padding: 12px 4px; min-height: 44px; cursor: pointer; text-decoration: underline dotted; text-underline-offset: 3px; }
.pf-fotos-reihe { display: flex; flex-wrap: wrap; gap: 8px; padding: 4px 0 6px; }
.pf-foto { width: 84px; display: grid; gap: 1px; padding: 0; border: 0; background: transparent; color: var(--ink-2); text-align: left; cursor: pointer; }
.pf-foto img { width: 84px; height: 72px; object-fit: cover; border-radius: 8px; background: var(--surface-2); display: block; }
.pf-foto-art { font-size: .66rem; line-height: 1.15; overflow-wrap: anywhere; }
.pf-foto-cr { font-size: .6rem; line-height: 1.15; color: var(--ink-3); overflow-wrap: anywhere; }

/* Kontrollkarte (swisstopo; Leaflet wird erst beim ersten Zeigen nachgeladen, siehe karte.js) */
.karte-feld { position: relative; isolation: isolate; height: 240px; border-radius: var(--radius-s); border: 1px solid var(--line-strong); overflow: hidden; background: var(--surface-2); color: var(--ink); }
.karte-feld.leaflet-container { font: inherit; background: #dfe5e2; color: #17221e; }
.karte-text { margin: 6px 0 0; overflow-wrap: anywhere; }
.karte-feld.karte-wartet, .karte-laedt { display: grid; place-items: center; text-align: center; padding: 12px; }
.karte-laedt { height: 100%; color: var(--ink-2); }
.karte-ok { display: grid; gap: 10px; justify-items: center; max-width: 34ch; font-size: .92rem; }
.karte-ok p { margin: 0; }
.karte-ok .toggle { margin: 0; }
.karte-kurz { display: block; padding: 6px; font-size: .78rem; font-weight: 700; color: var(--brand-ink); }
.karte-platz { position: absolute; inset: 0; z-index: 900; display: grid; place-items: center; padding: 10px; overflow: auto; text-align: center; background: var(--surface-2); color: var(--ink); font-size: .9rem; }
.karte-platz p { margin: 4px 0 8px; }
.karte-platz-koord { font-variant-numeric: tabular-nums; font-weight: 650; }
.karte-feld.karte-klein .karte-platz { font-size: .66rem; padding: 4px; line-height: 1.25; }
.karte-feld.karte-klein .karte-platz .btn { display: none; }
.karte-typ { display: flex; background: var(--surface); border: 1px solid var(--line-strong); border-radius: 9px; overflow: hidden; box-shadow: var(--shadow); }
.karte-typ button { min-height: 36px; border: 0; background: transparent; color: var(--ink); padding: 0 11px; font: 650 .82rem var(--font); cursor: pointer; }
.karte-typ button[aria-pressed="true"] { background: var(--brand); color: var(--on-brand); }
.karte-feld.karte-klein .leaflet-control-zoom, .karte-feld.karte-klein .karte-typ { display: none; }
.karte-feld.karte-klein .leaflet-control-attribution { font-size: 8px; padding: 0 3px; }
.karte-kreuz { position: absolute; left: 50%; top: 50%; width: 48px; height: 48px; margin: -24px 0 0 -24px; z-index: 800; pointer-events: none; }
.karte-kreuz svg { stroke: #e11d2a; stroke-width: 2.5; fill: none; filter: drop-shadow(0 0 1.5px #fff) drop-shadow(0 0 1.5px #fff); }
.karte-marker { background: none; border: 0; }
.karte-marker svg { overflow: visible; }
.karte-pt-rand { fill: #fff; } .karte-pt { fill: #0f7f74; } .karte-pt-kreuz { stroke: #fff; stroke-width: 1.4; }
.karte-kegel { fill: rgb(255 145 0 / .5); stroke: #c76400; stroke-width: 1; }
.karte-pos-rand { fill: #fff; } .karte-pos { fill: #1a73e8; }
path.karte-genau { stroke: #0f7f74; fill: #0f7f74; fill-opacity: .16; }
path.karte-genau-pos { stroke: #1a73e8; fill: #1a73e8; fill-opacity: .12; }
.karte-box { margin: 10px 0 4px; }
.fp-neu-karte { margin-top: 10px; }
.fp-neu-genau { margin: 0 0 8px; font-weight: 650; }
.fp-neu-genau.warn { background: var(--schlecht-soft); border-left: 4px solid var(--schlecht); border-radius: 8px; padding: 8px 10px; font-weight: 500; }
.fp-neu-karte .karte-feld { height: 200px; }
/* Minikarte in der Fotopunkt-Kamera (Ecke, antippen = grösser) */
.cam .karte-mini-box { position: absolute; right: 8px; z-index: 6; width: 120px; height: 120px; border-radius: 12px; overflow: hidden; border: 2px solid #fff; box-shadow: 0 2px 12px rgb(0 0 0 / .55); background: #222; }
.cam .karte-mini-box.gross { width: min(92vw, 340px); height: min(56dvh, 340px); }
.cam .karte-mini-box .karte, .cam .karte-mini-box .karte-feld { height: 100%; border: 0; border-radius: 0; }
.cam .karte-mini-box .karte-ok { color: #fff; }
.cam .karte-mini-box .karte-feld.karte-wartet { background: #222; }
.karte-mini-t { position: absolute; inset: 0; z-index: 1000; border: 0; background: transparent; cursor: pointer; padding: 0; }
.karte-mini-box.gross .karte-mini-t { inset: auto auto 6px 6px; width: 40px; height: 40px; border-radius: 50%; background: rgb(0 0 0 / .65); color: #fff; font: 700 1.5rem/1 var(--font); border: 1px solid #fff; }
.karte-mini-box.gross .karte-mini-t::before { content: '–'; }
/* Vollbild: Punkt verschieben / Standort setzen */
.karte-vollbild .karte-voll { flex: 1; min-height: 0; display: flex; }
.karte-vollbild .karte-voll .karte { flex: 1; display: flex; min-width: 0; }
.karte-vollbild .karte-voll .karte-feld { flex: 1; height: auto; border: 0; border-radius: 0; }
.karte-vollbild .karte-unten { gap: 8px; }
.karte-vollbild .karte-text-voll { margin: 0; text-align: center; font-size: .85rem; color: #ddd; overflow-wrap: anywhere; }
.karte-vollbild .karte-hinweis { margin: 0; text-align: center; font-size: .85rem; color: #ffd84d; }
.karte-vollbild .cam-ctrl { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; width: 100%; }
.karte-vollbild .cam-ctrl .cam-btn { padding: 0 6px; min-height: 48px; font-size: .88rem; line-height: 1.15; white-space: normal; overflow-wrap: normal; hyphens: auto; }
/* Platzhalter (offline): Zoom und Karte/Luftbild ausblenden, sonst liegen sie über dem Text */
.karte-feld:has(.karte-platz) .leaflet-control-container { display: none; }
.karte-vollbild .karte-legende { margin: 0; text-align: center; font-size: .75rem; color: #aaa; }

/* ---------- Bedienbarkeit (p1-7) ---------- */
.q > .h-q { font-size: 1.12rem; }
.kb-h { font-size: .95rem; }
/* Touch: Ziele mindestens 44 px */
@media (pointer: coarse) {
  .karte-typ button { min-height: 44px; min-width: 44px; }
  .leaflet-touch .leaflet-bar a, .leaflet-bar a { width: 44px; height: 44px; line-height: 44px; }
  .leaflet-touch .leaflet-control-zoom-in, .leaflet-touch .leaflet-control-zoom-out { font-size: 22px; }
  .pf-krume { min-height: 44px; }
  .pf-hin-knopf, .pf-spalte { min-height: 48px; }
  .ext a, .pf-fuss a, .au-eag { padding-block: 10px; }
}
.au-eag { display: inline-block; padding-block: 6px; }

/* Querformat am Handy (Höhe < 500 px): Leisten nicht anheften, Kopfzeile und Fusszeile kompakt */
@media (max-height: 500px) {
  :root { --kopf-h: 0px; --fuss-h: calc(2.9rem + var(--safe-b)); }
  .topbar, .bar, .aufnahme .au-nav, .actionbar, .fab-wrap, .rad-sticky { position: static; top: auto; bottom: auto; }
  .topbar { min-height: 44px; padding-block: 2px; }
  .bar { min-height: 44px; padding-block: 2px; backdrop-filter: none; }
  .bar.bar-top { padding-top: 8px; }
  .fn { flex-direction: row; gap: 6px; min-height: 44px; padding: 2px; }
  .fn-ico { width: 32px; height: 24px; } .fn-ico svg { width: 20px; height: 20px; }
  .fn-neu .fn-ico { margin-top: 0; width: 40px; height: 30px; }
  .sheet { max-height: 96dvh; }
  .pf-such-dock { position: static; }
  .scrim { align-items: center; }
}

/* Umbruch statt Überlauf (Schrift bis 200 %, Breite 320 px): Rasterspalten dürfen schrumpfen, lange Wörter werden getrennt */
.steps, .step-chip, .factor-nav button { position: relative; }
.opts, .rad-layout, .pf-baum, .pf-knoten, .pf-spalten, .pf-krit, .pf-namen, .pf-treffer, .pf-w, .typ-cards, .neu-liste, .bars, .ov-grid, .aufnahme .au-kats, .stack { grid-template-columns: minmax(0, 1fr); }
.opts.cols2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.opts.cols3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 400px) { .opts.cols3 { grid-template-columns: minmax(0, 1fr); } }
@media (min-width: 560px) { .opts.cols-wide { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@container detail (min-width: 760px) { .rad-layout { grid-template-columns: minmax(320px, 440px) minmax(0, 1fr); } }
.pf-w { grid-template-columns: repeat(auto-fill, minmax(min(100%, 132px), 1fr)); }
.pf-tabs { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (min-width: 640px) { .pf-tabs { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.pf-spalte, .pf-zweig, .pf-name, .pf-opt, .pf-treffer-zeile, .opt, .btn, .item, .neu-eintrag, .typ-card, .tier-schalter, .kb-item { min-width: 0; hyphens: auto; overflow-wrap: break-word; }
.pf-spalte > .grow, .pf-spalte b, .pf-name b { min-width: 0; overflow-wrap: anywhere; }
.opt .body b, .opt .body small, .opt .lead { overflow-wrap: break-word; }
h1, h2, h3, .h-q, .q-t { overflow-wrap: break-word; hyphens: auto; }
.start-klein .btn { overflow-wrap: break-word; }
.pf-krit .pf-opt, .pf-zweig { overflow-wrap: break-word; }

label.field > span, .pf-tabs button, .tier-txt, .kz-erkl dd, .kz-erkl dt, .wi-tab td, .wi-tab th, .pool-karte { overflow-wrap: break-word; hyphens: auto; min-width: 0; }
.pf-tabs button { padding: 4px 6px; line-height: 1.2; }
.kz-erkl dl { grid-template-columns: minmax(0, 1fr); gap: 0 12px; }
.kz-erkl dd { margin: 0 0 8px; }
@media (min-width: 480px) { .kz-erkl dl { grid-template-columns: max-content minmax(0, 1fr); } .kz-erkl dd { margin: 0 0 4px; } }
.tier-umschalter { grid-template-columns: repeat(auto-fit, minmax(min(100%, 13rem), 1fr)); }
.tier-schalter { min-width: 0; }

.alert.small { display: block; overflow-wrap: break-word; }
.alert > div, .alert > span { min-width: 0; overflow-wrap: break-word; }
.aufnahme .au-kat-kopf { flex-wrap: wrap; gap: 2px 8px; } .aufnahme .au-kat-kopf b { overflow-wrap: anywhere; }

/* Letzte Rückfallebene: nichts ragt über den Rand, auch bei 200 % Schrift und 320 px Breite */
body { overflow-wrap: break-word; }
.btn, .seg button, .pf-tabs button, .au-chip, .chip-btn, .opt, .item, .neu-eintrag, .tier-schalter, .pf-spalte, .pf-name, .pf-zweig, .pf-opt, .kb-btn, .step-chip, .factor-nav button,
.au-z-t, .au-z-n, .rating, .alert, .au-ziel span, .au-art-n, .section-title, .hero > *, .kpi .l, .kpi .d, p, li, dd, dt, label, summary, .chip { overflow-wrap: anywhere; }
.rating { flex-wrap: wrap; } .rating > div { min-width: 0; }
.step-chip { max-width: 100%; }

.aufnahme .au-art { flex-wrap: wrap; } .aufnahme .au-art-n { flex: 1 1 9rem; }
.aufnahme .au-step { flex-wrap: nowrap; }
.wi-tab td, .wi-tab th { overflow-wrap: anywhere; }

.skip { min-height: 44px; display: inline-flex; align-items: center; padding: 0 16px; }
.topbar .brand { min-height: 44px; }
.au-eag { padding-block: 12px; margin-block: -12px; }

/* ---------- Excel-Export (p1-8): vier Knöpfe unter der Aufnahme brechen um, statt zusammengedrückt zu werden ---------- */
.aufnahme .au-aktionen .btn { flex: 1 1 8.5rem; }
.aufnahme .au-aktionen .btn svg { flex: none; }

/* ---------- p1-9: Kreise, Schätzhilfe für Lücken, Artenwahl mit Suche, Gruppe je Art ---------- */
:root { --lu-gruen: #5fae4a; --lu-boden: #8b6a46; --lu-rand: #4a3520; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --lu-gruen: #3f8a3a; --lu-boden: #b48c5c; --lu-rand: #e8d3b0; } }
:root[data-theme="dark"] { --lu-gruen: #3f8a3a; --lu-boden: #b48c5c; --lu-rand: #e8d3b0; }
.aufnahme .au-kreis-kopf { display: flex; align-items: center; justify-content: space-between; gap: 6px; min-height: 44px; }
.aufnahme .au-kreis-kopf .au-weg-btn svg { width: 22px; height: 22px; }
.aufnahme .au-kreis-neu { display: flex; align-items: center; gap: 8px; margin: 0 0 10px; }
.aufnahme .au-kreise-warn { margin: 6px 0 10px; }
.aufnahme .au-kreise { grid-template-columns: repeat(auto-fill, minmax(min(230px, 100%), 1fr)); }
.au-lu-hilfe { margin: 4px 0 8px; border: 1px solid var(--line); border-radius: 10px; padding: 0 10px 8px; }
.au-lu-hilfe > summary { min-height: 44px; display: flex; align-items: center; cursor: pointer; font-weight: 700; }
.au-lu-bilder { display: grid; grid-template-columns: repeat(auto-fit, minmax(72px, 1fr)); gap: 8px; margin: 6px 0; }
.au-lu-b { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 6px; min-height: 44px; border: 2px solid var(--line-strong); border-radius: 10px; background: var(--surface); color: var(--ink); cursor: pointer; font: inherit; }
.au-lu-b[aria-pressed="true"] { border-color: var(--brand); background: var(--brand-soft); box-shadow: 0 0 0 2px var(--brand); }
.au-lu-b[aria-pressed="true"] .au-lu-t::before { content: '✓ '; }
.au-lu-t { font-weight: 700; }
.au-lu-svg { width: 100%; height: auto; aspect-ratio: 1; display: block; border-radius: 6px; }
.au-lu-svg .lu-g { fill: var(--lu-gruen); }
.au-lu-svg .lu-b { fill: var(--lu-boden); stroke: var(--lu-rand); stroke-width: .7; }
.au-lu-panel { display: grid; gap: 6px; color: #fff; }
.au-lu-panel .small { color: #e5e7eb; }
.au-suche { margin: 6px 0 2px; }
.au-suche .input { min-height: 48px; }
.au-anz { margin: 2px 0 6px; }
ul.au-wahl { list-style: none; margin: 0; padding: 0; gap: 6px; max-height: min(46vh, 380px); }
.au-o { text-align: left; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); padding: 8px 10px; cursor: pointer; display: flex; flex-direction: column; gap: 2px; min-height: 44px; }
.au-o:hover { border-color: var(--brand); }
.au-o[aria-selected="true"] { border-color: var(--brand); background: var(--brand-soft); box-shadow: 0 0 0 2px var(--brand); }
.au-o-n { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; }
.au-o-da { font-size: .8rem; font-weight: 700; color: var(--gut-text, var(--ink)); }
.au-o-frei { border-style: dashed; }
.au-vorschl { font-size: .66rem; font-weight: 700; border: 1px solid var(--line-strong); border-radius: 99px; padding: 0 6px; color: var(--ink-2); white-space: nowrap; }
.aufnahme .au-art-kat { flex: 1 1 100%; display: flex; align-items: center; gap: 8px; }
.aufnahme .au-art-kat select { flex: 1; width: auto; min-height: 44px; }
.au-lu-hilfe > summary::before { content: '▸'; margin-right: 8px; }
.au-lu-hilfe[open] > summary::before { content: '▾'; }
.au-o { flex: none; }
.au-o .chip { white-space: normal; height: auto; }
.aufnahme .au-art-n { flex: 1 1 6.5rem; }
.aufnahme .au-art-kat { flex-wrap: wrap; }
.aufnahme .au-art-kat select { flex: 1 1 8rem; min-width: 0; max-width: 100%; }
.au-lu-t { white-space: nowrap; }
.aufnahme .au-kat-hw { margin: 0 0 4px; }
.aufnahme .au-art-hw { flex: 1 1 100%; line-height: 1.35; }

/* ---------- p1-14: Fusszeile immer sichtbar, Kopfzeile der Aufnahme, Herunterladen-Menü, Kamera-Lupe, kürzere Massnahmen ---------- */
/* Arbeitsleisten (Weiter-Knöpfe im Assistenten) sitzen über der Fusszeile, nicht darunter */
@media (max-width: 759.98px) { .actionbar { bottom: var(--fuss); } }
.bar h1, .bar h2 { min-width: 0; }
.bar .sub-au { display: flex; align-items: baseline; gap: 0 5px; min-width: 0; font-size: .82rem; line-height: 1.3; overflow-wrap: normal; }
.sub-au .sub-ort { flex: 0 100 auto; min-width: 3ch; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sub-au .sub-parz { flex: 0 1 auto; min-width: 6ch; overflow-wrap: anywhere; }
.sub-au .sub-datum, .sub-au .sub-sep { flex: none; white-space: nowrap; }
.bar > .dl-wrap { order: 90; }
.dl-wrap { position: relative; display: inline-flex; flex: none; }
.dl-wrap.grow { flex: 1 1 8.5rem; }
.dl-wrap .dl-knopf.btn { flex: 1; }
.dl-popup { position: absolute; right: 0; top: calc(100% + 4px); z-index: 50; min-width: min(280px, calc(100vw - 24px)); display: grid; gap: 2px; padding: 6px; background: var(--surface); border: 1px solid var(--line-strong); border-radius: 12px; box-shadow: 0 10px 30px rgb(0 0 0 / .25); }
.dl-popup[hidden] { display: none; }
.dl-oben .dl-popup { top: auto; bottom: calc(100% + 4px); left: 0; right: auto; }
.dl-item { display: flex; flex-direction: column; align-items: flex-start; gap: 1px; min-height: 48px; padding: 6px 12px; border: 0; border-radius: 8px; background: transparent; color: var(--ink); font: inherit; text-align: left; cursor: pointer; }
.dl-item:hover, .dl-item:focus-visible { background: var(--brand-soft); }
.dl-item:focus-visible { outline: 2px solid var(--brand); outline-offset: -2px; }
.dl-t { font-weight: 700; }
.dl-s { font-size: .8rem; color: var(--ink-3); }

/* Kamera-Lupe (Pflanzen): Handy runder grüner Knopf neben der Such-Lupe, Computer Knopf mit Symbol und Text */
.pf-such-dock { gap: 10px; }
.pf-lupe-kamera { flex: none; width: 54px; height: 54px; border-radius: 50%; border: 3px solid var(--on-brand); background: var(--gut-strong); color: #fff; display: grid; place-items: center; box-shadow: 0 4px 14px rgb(0 0 0 / .3); cursor: pointer; }
.pf-lupe-kamera svg { width: 30px; height: 30px; }
.pf-lupe-btn { display: none; }
.pf-lupe-btn svg { width: 20px; height: 20px; }
@media (min-width: 760px) { .pf-lupe-kamera { display: none; } .pf-lupe-btn { display: inline-flex; } }

/* Massnahmen kurz (p1-14): Vorschläge als Kacheln, Suchfeld, Chips mit ×, je Art eine Zeile */
.au-vs { margin-top: 6px; }
.au-vs-kopf { margin: 0 0 4px; }
.au-kacheln { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(9.4em, 100%), 1fr)); gap: 6px; margin-bottom: 8px; }
.au-kachel { display: flex; flex-direction: column; align-items: flex-start; gap: 1px; min-height: 48px; padding: 6px 10px; border: 1px dashed var(--line-strong); border-radius: 10px; background: var(--surface); color: var(--ink); font: inherit; text-align: left; cursor: pointer; }
.au-kachel:hover { border-color: var(--brand); background: var(--brand-soft); }
.au-kachel { min-width: 0; overflow-wrap: anywhere; }
.au-kachel small { color: var(--ink-3); font-size: .78rem; line-height: 1.25; }
.au-cb { position: relative; margin: 4px 0; }
.au-cb .field { margin-bottom: 0; }
.au-cb-liste { list-style: none; margin: 2px 0 0; padding: 4px; max-height: 240px; overflow: auto; border: 1px solid var(--line-strong); border-radius: 10px; background: var(--surface); display: grid; gap: 2px; }
.au-cb-liste[hidden] { display: none; }
.au-cb-liste .au-o { min-height: 44px; flex-direction: row; align-items: center; justify-content: space-between; gap: 8px; }
.au-o-leer { padding: 8px 10px; }
.au-gewaehlt { margin: 6px 0 2px; }
.au-chip-x { background: var(--brand-soft); border-color: var(--brand); }
.au-chip-x::before { display: none; }
.au-massn-z { list-style: none; margin: 4px 0 6px; padding: 0; display: grid; gap: 2px; }
.au-m { border-bottom: 1px solid var(--line); }
.au-m > summary { display: flex; align-items: center; gap: 8px; min-height: 44px; cursor: pointer; list-style: none; }
.au-m > summary::-webkit-details-marker { display: none; }
.au-m > summary::before { content: '▸'; flex: none; color: var(--ink-3); }
.au-m[open] > summary::before { content: '▾'; }
.au-m > summary b { flex: none; }
.au-m-t { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--ink-2); font-size: .88rem; }
.au-m[open] .au-m-t { visibility: hidden; flex: 0 0 0; }
.au-m > p { margin: 2px 0 6px 20px; font-size: .9rem; }
@media (min-width: 760px) { .au-m-t { white-space: normal; } }
.au-vs4 { list-style: none; margin: 4px 0 6px; padding: 0; display: grid; gap: 4px; }
.au-vs4 li { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: .9rem; }
.au-vs4-t { flex: 1; min-width: 0; overflow-wrap: anywhere; }
.au-ueb { flex: none; }
.au-ueb[aria-pressed="true"] { background: var(--brand); color: var(--on-brand); border-color: var(--brand); }
.au-ueb[aria-pressed="true"]::before { content: '✓ '; }
.au-text { field-sizing: content; min-height: calc(3 * 1.4em + 16px); }
.sub-au .sub-parz { flex: 0 0 auto; max-width: 66%; overflow-wrap: anywhere; }
.sub-au .sub-ort { min-width: 5ch; }
.dl-knopf.btn { hyphens: manual; overflow-wrap: normal; white-space: nowrap; }
@media (max-width: 559.98px) { .aufnahme .au-aktionen .dl-wrap.grow { flex: 1 1 100%; } }
/* Schmale Kopfzeile (Handy, grosse Schrift): Ort allein in der ersten Zeile (nur wenn länger als die Zeile gekürzt), Parzelle · Datum darunter */
.bar h1:has(.sub-au), .bar h2:has(.sub-au) { container-type: inline-size; }
@container (max-width: 26em) {
  .bar .sub-au { flex-wrap: wrap; gap: 0; }
  .sub-au .sub-ort { flex: 0 1 100%; }
  .sub-au .sub-sep { margin: 0 5px; }
  .sub-au .sub-ort + .sub-sep { margin: 0; }
  .sub-au .sub-ort + .sub-sep > [aria-hidden] { display: none; }
  .sub-au .sub-parz { max-width: 100%; }
}
