/* =========================================================
   Stefan Marx · Drohnen-Pflanzenschutz – Kundenportal
   Schwarz / Orange mit Carbon-Struktur
   ========================================================= */
:root {
  --bg: #0b0b0b;
  --surface: #151515;
  --surface-2: #1c1c1c;
  --surface-3: #232323;
  --field: #0f0f0f;
  --ink: #ededed;
  --ink-strong: #ffffff;
  --muted: #9b9b9b;
  --line: #2b2b2b;
  --line-strong: #3a3a3a;
  --orange: #f26b1d;
  --orange-hi: #ff8a3d;
  --amber: #f9a51a;
  --orange-soft: rgba(242, 107, 29, .14);
  --ok: #4fd18b;
  --ok-soft: rgba(79, 209, 139, .12);
  --warn: #f5b942;
  --warn-soft: rgba(245, 185, 66, .13);
  --error: #ff6a5c;
  --error-soft: rgba(255, 106, 92, .13);
  --radius: 10px;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-display: "Bahnschrift SemiCondensed", "Bahnschrift", "Roboto Condensed", "Arial Narrow", system-ui, sans-serif;
  --carbon:
    linear-gradient(27deg, #121212 5px, transparent 5px) 0 5px,
    linear-gradient(207deg, #121212 5px, transparent 5px) 10px 0,
    linear-gradient(27deg, #1b1b1b 5px, transparent 5px) 0 10px,
    linear-gradient(207deg, #1b1b1b 5px, transparent 5px) 10px 5px,
    linear-gradient(90deg, #161616 10px, transparent 10px),
    linear-gradient(#171717 25%, #141414 25%, #141414 50%, transparent 50%, transparent 75%, #1d1d1d 75%, #1d1d1d);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; color-scheme: dark; }
body {
  margin: 0; min-height: 100vh; display: flex; flex-direction: column;
  color: var(--ink); font: 16px/1.55 var(--font);
  background: transparent;
}
a { color: var(--orange-hi); text-underline-offset: 2px; }
a:hover { color: var(--amber); }
:focus-visible { outline: 2px solid var(--orange); outline-offset: 2px; }
::selection { background: var(--orange); color: #111; }
code { font-size: .88em; background: var(--surface-3); color: var(--amber); padding: .1em .4em; border-radius: 4px; }
kbd { font: .85em var(--font); padding: .05em .45em; border: 1px solid var(--line-strong); border-bottom-width: 2px; border-radius: 4px; background: var(--surface-3); color: var(--ink-strong); }

h1, h2, .eyebrow, legend, .brand-sub, .badge, .data th, .entry-grid th {
  font-family: var(--font-display);
}
h1 { font-size: clamp(1.7rem, 3.2vw, 2.4rem); line-height: 1.1; margin: 0 0 .5rem; color: var(--ink-strong); letter-spacing: .01em; text-transform: uppercase; font-weight: 700; }
h2 { font-size: 1.2rem; margin: 0 0 .85rem; color: var(--ink-strong); text-transform: uppercase; letter-spacing: .04em; font-weight: 600; }
.lead { color: var(--muted); margin: 0 0 1.75rem; font-size: 1.05rem; max-width: 62ch; }
.muted { color: var(--muted); }
.custno { font-variant-numeric: tabular-nums; color: var(--amber); letter-spacing: .02em; }

/* ---------- Kopfzeile ---------- */
.topbar {
  position: sticky; top: 0; z-index: 1100;
  background: linear-gradient(180deg, rgba(8, 8, 8, .96), rgba(14, 14, 14, .93));
  backdrop-filter: blur(8px);
  border-bottom: 1px solid #222;
  box-shadow: 0 1px 0 rgba(242, 107, 29, .55), 0 10px 30px rgba(0, 0, 0, .45);
}
.topbar-inner {
  max-width: 1400px; margin: 0 auto; padding: .55rem 1.5rem;
  display: flex; align-items: center; justify-content: space-between; gap: 1.25rem; flex-wrap: wrap;
}
.brand { display: flex; align-items: center; gap: .9rem; text-decoration: none; }
.brand img { height: 56px; width: auto; display: block; }
.brand-sub {
  color: var(--muted); font-size: .78rem; line-height: 1.15; text-transform: uppercase; letter-spacing: .14em;
  padding-left: .9rem; border-left: 2px solid var(--orange);
}
.nav { display: flex; align-items: center; gap: .35rem; flex-wrap: wrap; }
.nav a, .nav .linkbtn {
  color: #cfcfcf; text-decoration: none; padding: .5rem .85rem; border-radius: 999px;
  font-weight: 500; font-size: .95rem; transition: background .15s, color .15s;
}
.nav a:hover, .nav .linkbtn:hover { color: #fff; background: var(--surface-3); }
.nav a.active { color: #111; background: linear-gradient(135deg, var(--amber), var(--orange)); font-weight: 650; }
.nav .logout { color: var(--muted); }

/* ---------- Seitenbereich ---------- */
.page { flex: 1; width: 100%; max-width: 920px; margin: 0 auto; padding: 2.25rem 1.5rem 3.5rem; }
.medium .page { max-width: 1140px; }
.wide .page { max-width: 1400px; }
.narrow .page { max-width: 480px; }

.footer {
  width: 100%; padding: 1.5rem; display: flex; justify-content: center; gap: 1.5rem; flex-wrap: wrap;
  font-size: .85rem; color: var(--muted); border-top: 1px solid #1f1f1f; background: rgba(8, 8, 8, .85);
}
.footer-links { display: flex; gap: 1.25rem; }
.footer a { color: var(--muted); }
.footer a:hover { color: var(--orange-hi); }

/* ---------- Anmelde-Seiten mit Drohnenfoto ---------- */
body.auth {
  background:
    linear-gradient(100deg, rgba(5, 5, 5, .94) 0%, rgba(5, 5, 5, .82) 38%, rgba(5, 5, 5, .35) 75%, rgba(5, 5, 5, .55) 100%),
    url("img/mosel-drohne.jpg") 62% center / cover no-repeat fixed;
}
.auth .page { max-width: 1180px; display: grid; grid-template-columns: minmax(0, 440px); align-content: center; padding-top: 3rem; }
.auth-brand { margin-bottom: 1.5rem; }
.auth-brand img { width: min(330px, 80%); height: auto; display: block; filter: drop-shadow(0 6px 24px rgba(0, 0, 0, .7)); }
.auth-brand p { margin: .75rem 0 0; color: #cfcfcf; text-transform: uppercase; letter-spacing: .18em; font-size: .78rem; font-family: var(--font-display); }
.auth-card {
  background: rgba(16, 16, 16, .86); backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, .08); border-top: 3px solid var(--orange);
  border-radius: 14px; padding: 2rem; box-shadow: 0 30px 80px rgba(0, 0, 0, .55);
}
.auth-card h1 { font-size: 1.7rem; }
.auth .footer { background: transparent; border-top: 0; }

/* ---------- Begrüßungsbereich mit Foto ---------- */
.hero {
  position: relative; overflow: hidden; border-radius: 16px; margin: 0 0 1.75rem;
  min-height: 230px; display: flex; align-items: flex-end;
  background:
    linear-gradient(90deg, rgba(6, 6, 6, .95) 0%, rgba(6, 6, 6, .7) 45%, rgba(6, 6, 6, .1) 100%),
    var(--hero) center 22% / cover no-repeat;
  border: 1px solid #262626;
  box-shadow: 0 20px 50px rgba(0, 0, 0, .5);
}
.hero::after {
  content: ""; position: absolute; left: 0; bottom: 0; height: 4px; width: 100%;
  background: linear-gradient(90deg, var(--orange), var(--amber) 40%, transparent 80%);
}
.hero-content { position: relative; padding: 2rem 2.25rem 2.1rem; max-width: 640px; }
.hero h1 { font-size: clamp(1.9rem, 4vw, 2.8rem); margin-bottom: .4rem; }
.hero-meta { margin: 0; color: #d6d6d6; }
.hero-slim { min-height: 180px; }
.eyebrow { margin: 0 0 .35rem; color: var(--orange-hi); text-transform: uppercase; letter-spacing: .2em; font-size: .8rem; font-weight: 600; }

/* ---------- Hinweise ---------- */
.flash {
  padding: .9rem 1.1rem; border-radius: var(--radius); margin: 0 0 1.25rem;
  background: var(--surface-2); border: 1px solid var(--line); border-left: 4px solid var(--orange);
}
.flash p { margin: 0 0 .5rem; }
.flash p:last-child { margin-bottom: 0; }
.flash-success { background: var(--ok-soft); border-color: rgba(79, 209, 139, .3); border-left-color: var(--ok); }
.flash-error { background: var(--error-soft); border-color: rgba(255, 106, 92, .3); border-left-color: var(--error); color: #ffd9d4; }
.flash-warn { background: var(--warn-soft); border-color: rgba(245, 185, 66, .3); border-left-color: var(--warn); color: #fbe7c0; }
.flash-info { border-left-color: var(--orange); }
.deadline { padding: .8rem 1.1rem; border-left: 4px solid var(--orange); background: var(--surface); border-radius: 0 var(--radius) var(--radius) 0; margin: 0 0 1.5rem; }
.deadline.is-locked { border-left-color: var(--error); }
.confirm-box { background: var(--warn-soft); padding: .75rem 1rem; border-radius: var(--radius); }

/* ---------- Fortschritt ---------- */
.steps { list-style: none; display: flex; gap: .75rem; padding: 0; margin: 0 0 1.5rem; counter-reset: step; font-size: .92rem; }
.steps li { counter-increment: step; color: var(--muted); display: flex; align-items: center; gap: .5rem; }
.steps li::before {
  content: counter(step); width: 1.75rem; height: 1.75rem; border-radius: 50%;
  display: inline-grid; place-items: center; border: 1.5px solid var(--line-strong); font-weight: 700;
}
.steps li + li { padding-left: .9rem; border-left: 1px solid var(--line-strong); }
.steps .current { color: var(--ink-strong); font-weight: 600; }
.steps .current::before { background: var(--orange); border-color: var(--orange); color: #111; }

/* ---------- Formulare ---------- */
.form fieldset { border: 0; padding: 0; margin: 0 0 2rem; }
.form legend { font-weight: 600; font-size: 1.1rem; margin-bottom: .9rem; padding: 0; color: var(--ink-strong); text-transform: uppercase; letter-spacing: .05em; }
.grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem 1.25rem; }
.grid-address { grid-template-columns: 3fr 1fr 1fr 2fr; }
.field { display: flex; flex-direction: column; gap: .35rem; margin-bottom: 1rem; }
.grid .field { margin-bottom: 0; }
.field.wide { grid-column: 1 / -1; }
.field label { font-weight: 550; font-size: .93rem; color: #dcdcdc; }
.optional { font-weight: 400; color: var(--muted); font-size: .82rem; margin-left: .25rem; }

input[type="text"], input[type="email"], input[type="password"], input[type="tel"],
input[type="date"], input[type="search"], input:not([type]), select, textarea {
  font: inherit; color: var(--ink-strong); width: 100%;
  padding: .68rem .8rem; border: 1px solid var(--line-strong); border-radius: 8px; background: var(--field);
  transition: border-color .15s, box-shadow .15s;
}
textarea { resize: vertical; line-height: 1.5; }
input::placeholder, textarea::placeholder { color: #6b6b6b; }
input:focus, select:focus, textarea:focus { border-color: var(--orange); outline: none; box-shadow: 0 0 0 3px var(--orange-soft); }
input:disabled { background: transparent; border-style: dashed; color: var(--ink); opacity: 1; }
input[type="date"]::-webkit-calendar-picker-indicator { filter: invert(.8); }
.has-error input, .has-error select { border-color: var(--error); }
.hint { margin: 0; color: var(--muted); font-size: .84rem; }
.error { margin: 0; color: var(--error); font-size: .88rem; font-weight: 500; }
.check label { display: flex; gap: .65rem; align-items: flex-start; font-weight: 400; color: var(--ink); }
input[type="checkbox"], input[type="radio"] { accent-color: var(--orange); }
.check input { width: 1.15rem; height: 1.15rem; margin-top: .2rem; flex-shrink: 0; }
.checks { display: flex; flex-direction: column; gap: .5rem; justify-content: flex-end; }
.check-inline { display: inline-flex; align-items: center; gap: .5rem; font-weight: 400 !important; }
.check-inline input { width: 1.15rem; height: 1.15rem; margin: 0; }
.actions { display: flex; align-items: center; gap: 1.25rem; flex-wrap: wrap; margin-top: .5rem; }
.inline { display: inline; margin: 0; }
.inline-form { display: flex; align-items: flex-end; gap: 1rem; flex-wrap: wrap; }
.inline-form .field { margin: 0; min-width: 14rem; }
.inline-form .actions { margin: 0; }

/* Bewirtschaftung */
.radios { border: 0; padding: 0; margin: 0; }
.radios-legend { font-weight: 550; font-size: .93rem; margin-bottom: .45rem; padding: 0; color: #dcdcdc; text-transform: none !important; letter-spacing: 0 !important; font-family: var(--font) !important; }
.radio-row { display: flex; gap: .75rem; flex-wrap: wrap; }
.radio-card {
  display: flex; align-items: center; gap: .6rem; cursor: pointer; font-weight: 500;
  padding: .7rem 1.2rem; border: 1px solid var(--line-strong); border-radius: 8px; background: var(--field);
  transition: border-color .15s, background .15s;
}
.radio-card input { width: 1.1rem; height: 1.1rem; margin: 0; }
.radio-card:hover { border-color: #555; }
.radio-card:has(input:checked) { border-color: var(--orange); background: var(--orange-soft); color: #fff; }
.radios.has-error .radio-card { border-color: var(--error); }

/* ---------- Knöpfe ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .4rem;
  font: inherit; font-weight: 650; cursor: pointer; text-decoration: none; letter-spacing: .01em;
  background: linear-gradient(135deg, var(--amber), var(--orange) 55%, #e2560c);
  color: #111; border: 0; padding: .7rem 1.3rem; border-radius: 8px;
  box-shadow: 0 6px 18px rgba(242, 107, 29, .28), inset 0 1px 0 rgba(255, 255, 255, .25);
  transition: transform .12s, box-shadow .12s, filter .12s;
}
.btn:hover { color: #111; filter: brightness(1.07); transform: translateY(-1px); box-shadow: 0 10px 24px rgba(242, 107, 29, .38); }
.btn:active { transform: translateY(0); }
.btn:disabled { opacity: .6; cursor: wait; transform: none; }
.btn-quiet {
  background: var(--surface-3); color: var(--ink-strong); box-shadow: none;
  border: 1px solid var(--line-strong);
}
.btn-quiet:hover { background: #2c2c2c; color: #fff; border-color: var(--orange); box-shadow: none; }
.linkbtn { font: inherit; background: none; border: 0; padding: 0; color: var(--orange-hi); cursor: pointer; text-decoration: underline; text-underline-offset: 2px; }
.nav .linkbtn { text-decoration: none; }
.danger { color: var(--error) !important; }

/* ---------- Inhaltsblöcke ---------- */
.panel {
  background: linear-gradient(180deg, rgba(28, 28, 28, .96), rgba(19, 19, 19, .96));
  border: 1px solid var(--line); border-radius: 14px; padding: 1.4rem 1.6rem; margin-bottom: 1.25rem;
  box-shadow: 0 12px 30px rgba(0, 0, 0, .35);
}
.panel p:last-child { margin-bottom: 0; }
.panel-head { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; flex-wrap: wrap; }
.panel-edit { border-color: var(--orange); }
.facts { display: grid; grid-template-columns: max-content 1fr; gap: .55rem 1.75rem; margin: 0; }
.facts dt { color: var(--muted); }
.facts dd { margin: 0; color: var(--ink-strong); }
.copy { display: flex; gap: .5rem; }
.copy input { flex: 1; }
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 1.25rem; }
.two-col .panel { margin-bottom: 1.25rem; }
.next-step {
  display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap;
  padding: 1.2rem 1.6rem; border-radius: 14px; color: #111; font-weight: 550;
  background: linear-gradient(135deg, var(--amber), var(--orange));
  box-shadow: 0 14px 34px rgba(242, 107, 29, .3);
}
.next-step p { margin: 0; }
.next-step .btn { background: #111; color: #fff; box-shadow: none; }
.next-step .btn:hover { background: #000; color: var(--amber); }

/* Status */
.badge { display: inline-block; padding: .32rem .8rem; border-radius: 999px; font-size: .85rem; font-weight: 600; white-space: nowrap; letter-spacing: .03em; }
.badge-open      { background: var(--surface-3); color: var(--muted); }
.badge-draft     { background: var(--warn-soft); color: var(--warn); }
.badge-submitted { background: var(--ok-soft); color: var(--ok); box-shadow: inset 0 0 0 1px rgba(79, 209, 139, .35); }
.badge-changed   { background: var(--error-soft); color: var(--error); }
.tag { font-size: .8rem; padding: .12rem .5rem; border-radius: 4px; white-space: nowrap; }
.tag-found     { background: var(--ok-soft); color: var(--ok); }
.tag-not_found { background: var(--warn-soft); color: var(--warn); }
.tag-unchecked { background: var(--surface-3); color: var(--muted); }

/* ---------- Tabellen ---------- */
.page-head { display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.25rem; }
.page-head h1 { margin: 0; }
.page-head > div { min-width: 0; }
.page-head .lead { margin: .4rem 0 0; }
.count { font-size: .95rem; font-weight: 500; color: var(--muted); margin-left: .4rem; text-transform: none; letter-spacing: 0; font-family: var(--font); }
.search { display: flex; gap: .5rem; align-items: center; margin: 0 0 1rem; max-width: 660px; }
.filters { display: flex; flex-wrap: wrap; gap: 1rem; align-items: flex-end; margin: 0 0 1.25rem; }
.filters label { display: flex; flex-direction: column; gap: .3rem; font-size: .88rem; font-weight: 550; color: #cfcfcf; }
.filters select, .filters input:not([type="checkbox"]) { min-width: 9rem; width: auto; }
.filters .check-inline { flex-direction: row; padding-bottom: .7rem; }
.empty { padding: 2rem; background: rgba(255, 255, 255, .02); border: 1px dashed var(--line-strong); border-radius: var(--radius); color: var(--muted); text-align: center; }
.table-wrap { overflow: auto; max-height: 75vh; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
table.data { border-collapse: collapse; width: 100%; font-size: .9rem; }
.data th, .data td { padding: .6rem .8rem; border-bottom: 1px solid #242424; text-align: left; vertical-align: top; }
.data th {
  position: sticky; top: 0; z-index: 1; white-space: nowrap;
  background: #1f1f1f; color: #d9d9d9; font-weight: 600; font-size: .85rem; text-transform: uppercase; letter-spacing: .05em;
  box-shadow: inset 0 -2px 0 var(--orange);
}
.data td:first-child, .data th:first-child { position: sticky; left: 0; }
.data th:first-child { z-index: 2; }
.data tbody tr { background: var(--surface); }
.data tbody tr:nth-child(even) { background: #181818; }
.data tbody tr:hover { background: #222; }
.data td:first-child { background: inherit; }
.data td.num, .data th.num, .num { text-align: right; }
.nowrap { white-space: nowrap; }
.mono-ish { font-variant-numeric: tabular-nums; letter-spacing: .02em; font-size: .84rem; color: var(--muted); }
.row-actions { display: flex; gap: .9rem; align-items: center; flex-wrap: wrap; }
.inline-note { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; margin: 0 0 1rem; padding: .7rem 1rem; background: var(--warn-soft); border-radius: var(--radius); }
.pre { white-space: pre-wrap; word-break: break-all; font-size: .82rem; background: var(--field); color: #d6d6d6; padding: 1rem; border-radius: var(--radius); margin: 0; border: 1px solid var(--line); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- Eingabetabelle Flurstücke ---------- */
.grid-wrap { max-height: none; margin-top: 1rem; }
.entry-grid { border-collapse: collapse; width: 100%; min-width: 760px; }
.entry-grid th {
  background: #1f1f1f; color: #d9d9d9; font-size: .85rem; font-weight: 600; text-align: left; line-height: 1.2;
  padding: .6rem .65rem; border: 1px solid #2c2c2c; vertical-align: bottom; text-transform: uppercase; letter-spacing: .04em;
  box-shadow: inset 0 -2px 0 var(--orange);
}
.entry-grid td { border: 1px solid #2a2a2a; padding: 0; background: var(--field); }
.entry-grid input:not([type="checkbox"]) {
  width: 100%; border: 0; border-radius: 0; background: transparent; padding: .75rem .65rem; font: inherit; color: var(--ink-strong); box-shadow: none;
}
.entry-grid input:not([type="checkbox"]):focus { outline: 2px solid var(--orange); outline-offset: -2px; box-shadow: none; background: #161616; }
.entry-grid td.cb { text-align: center; }
.entry-grid td.cb input { width: 1.3rem; height: 1.3rem; margin: .65rem 0; cursor: pointer; }
.entry-grid th:nth-child(-n+4) { width: 13%; }
.entry-grid th:nth-child(6), .entry-grid th:nth-child(7) { width: 10%; text-align: center; }
.entry-grid th:last-child, .entry-grid td:last-child { width: 2.6rem; text-align: center; }
.entry-grid .cell-error { background: var(--error-soft); }
.entry-grid .cell-error input { color: var(--error) !important; font-weight: 600; }
.entry-grid tr.has-problem td { border-color: rgba(255, 106, 92, .35); }
.entry-grid tr.row-msg td { text-align: left; width: auto; padding: .5rem .7rem .65rem; font-size: .88rem; background: var(--warn-soft); color: #fbe7c0; border-top: 0; }
.entry-grid tr.row-msg .check-inline { margin-left: 1rem; color: var(--ink-strong); }
.row-del { border: 0; background: none; color: #777; font-size: 1.25rem; cursor: pointer; padding: .3rem .5rem; line-height: 1; }
.row-del:hover { color: var(--error); }
.grid-footer { display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap; margin: .85rem 0 1rem; }
.grid-total { font-size: 1.05rem; }
.grid-total strong { color: var(--amber); }

/* ---------- Karte ---------- */
.map { width: 100%; height: 480px; border-radius: var(--radius); background: #1a1a1a; border: 1px solid var(--line); }
.map-missing { padding: 2.25rem; text-align: center; color: var(--muted); background: rgba(255, 255, 255, .02); border: 1px dashed var(--line-strong); border-radius: var(--radius); }
.map-note { font-size: .82rem; color: var(--muted); margin: .65rem 0 0; }
.legend { display: inline-block; width: .9rem; height: .9rem; border-radius: 3px; vertical-align: -2px; margin: 0 .3rem 0 .7rem; }
.legend:first-child { margin-left: 0; }
.legend-normal { background: #5fd38d; border: 2px solid #d8ffe6; }
.legend-near   { background: #f2b631; border: 2px solid #ffd166; }
.map-info { font: 14px/1.45 var(--font); color: #1a1a1a; max-width: 260px; }
.map-info strong { display: block; margin-bottom: .25rem; }
.map .leaflet-popup-content { margin: .75rem 1rem; }
.map .leaflet-control-layers-expanded { font: 14px/1.5 var(--font); color: #1a1a1a; }
.map .leaflet-bar a { color: #1a1a1a; }

/* ---------- Abgabe ---------- */
.plot-summary { list-style: none; margin: 0; padding: 0; }
.plot-summary li { display: flex; justify-content: space-between; gap: 1rem; padding: .55rem 0; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.plot-summary li:last-child { border-bottom: 0; }
.terms { max-height: 280px; overflow: auto; padding: 1rem 1.1rem; background: var(--field); border: 1px solid var(--line); border-radius: var(--radius); margin-bottom: 1rem; font-size: .93rem; color: #d6d6d6; }
.terms-details { margin-top: 1rem; }
.terms-details summary { cursor: pointer; color: var(--orange-hi); }
.sig-wrap { position: relative; }
#sig { display: block; width: 100%; height: 200px; background: #fafafa; border: 1px solid var(--line-strong); border-bottom: 3px solid var(--orange); border-radius: var(--radius) var(--radius) 0 0; touch-action: none; cursor: crosshair; }
.sig-clear { position: absolute; top: .55rem; right: .8rem; color: #555 !important; }
.signature-img { display: block; max-width: 100%; max-height: 160px; background: #fafafa; border-radius: 6px; border-bottom: 3px solid var(--orange); margin-top: .75rem; padding: .25rem; }

/* ---------- Mobil ---------- */
@media (max-width: 900px) {
  .grid-plot { grid-template-columns: 1fr 1fr; }
  .two-col { grid-template-columns: 1fr; }
  .brand-sub { display: none; }
}
@media (max-width: 640px) {
  .page { padding: 1.5rem 1rem 2.5rem; }
  .topbar-inner { padding: .5rem 1rem; }
  .brand img { height: 42px; }
  .nav { width: 100%; overflow-x: auto; flex-wrap: nowrap; }
  .grid, .grid-address { grid-template-columns: 1fr; }
  .facts { grid-template-columns: 1fr; gap: .1rem; }
  .facts dd { margin-bottom: .65rem; }
  .copy { flex-direction: column; }
  .hero-content { padding: 1.5rem; }
  .map { height: 360px; }
  .auth-card { padding: 1.5rem; }
  body.auth {
    background:
      linear-gradient(180deg, rgba(5, 5, 5, .55) 0%, rgba(5, 5, 5, .9) 55%),
      url("img/mosel-drohne-mobil.jpg") 70% top / cover no-repeat;
  }
}


/* =========================================================
   Ergänzungen Runde 4
   ========================================================= */

/* Begrüßung ohne Foto */
.hero-plain {
  background:
    radial-gradient(120% 140% at 100% 0%, rgba(242, 107, 29, .22), transparent 55%),
    linear-gradient(135deg, #1d1d1d, #111);
  justify-content: space-between; align-items: center; gap: 1.5rem; flex-wrap: wrap;
}
.hero-plain .hero-content { padding: 1.9rem 2.25rem; }
.hero-plain .countdown { margin: 0 2.25rem 1.6rem; }

/* Countdown bis zur Frist */
.countdown {
  display: inline-flex; flex-direction: column; gap: .35rem; align-self: center;
  padding: .7rem 1rem .8rem; border-radius: 12px; min-width: 15rem;
  background: rgba(0, 0, 0, .45); border: 1px solid rgba(242, 107, 29, .45);
}
.countdown-label { font: 600 .74rem/1 var(--font-display); text-transform: uppercase; letter-spacing: .16em; color: var(--orange-hi); }
.countdown-time { display: flex; gap: .9rem; color: var(--muted); font-size: .85rem; }
.countdown-time b { font: 700 1.7rem/1 var(--font-display); color: var(--ink-strong); margin-right: .2rem; font-variant-numeric: tabular-nums; }
.countdown.is-close { border-color: var(--error); }
.countdown.is-close .countdown-time b { color: var(--error); }
.countdown.is-over .countdown-time { color: var(--error); font-weight: 600; }
.page-head h1 .badge { vertical-align: middle; margin-left: .5rem; font-size: .8rem; }

/* Hinweiskästen */
.notice-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; margin: 0 0 1.25rem; }
.notice {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: .9rem 1.1rem; font-size: .92rem; margin: 0 0 1.25rem;
}
.notice-grid .notice { margin: 0; }
.notice strong { display: block; color: var(--ink-strong); margin-bottom: .3rem; font-family: var(--font-display); text-transform: uppercase; letter-spacing: .05em; font-size: .9rem; }
.notice p { margin: 0; color: #cfcfcf; }
.notice-legal { border-left: 4px solid var(--orange); background: linear-gradient(90deg, var(--orange-soft), var(--surface) 60%); }
.panel-warn { border-color: rgba(245, 185, 66, .35); }

/* Tabellenzeile → Karte */
tr[data-plot] { cursor: pointer; }
.data tbody tr.is-selected, .data tbody tr.is-selected:hover { background: rgba(242, 107, 29, .18); box-shadow: inset 3px 0 0 var(--orange); }
.data tbody tr.is-missing { background: var(--warn-soft); }

/* Saisondaten */
.coming-soon { display: flex; gap: 1.5rem; align-items: center; padding: 2rem; }
.coming-icon { flex-shrink: 0; width: 88px; height: 88px; border-radius: 50%; display: grid; place-items: center;
  background: radial-gradient(circle, rgba(242, 107, 29, .25), transparent 70%); border: 1px solid rgba(242, 107, 29, .4); }

/* Spritzgemeinschaften */
.chips { display: flex; flex-wrap: wrap; gap: .5rem; }
.chip { background: var(--surface-3); border: 1px solid var(--line-strong); border-radius: 999px; padding: .3rem .8rem; font-size: .88rem; }
.chip strong { color: var(--amber); }
.sg-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(460px, 1fr)); gap: 1.25rem; }
.sg-list .panel { margin: 0; }
.sg-gem { margin: .25rem 0 1rem; color: var(--muted); }
.sg-gem strong { color: var(--ink-strong); }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: .75rem; margin-bottom: 1rem; }
.stats div { background: var(--field); border: 1px solid var(--line); border-radius: 8px; padding: .7rem .8rem; }
.stats b { display: block; font: 700 1.5rem/1.1 var(--font-display); color: var(--ink-strong); }
.stats span { font-size: .8rem; color: var(--muted); }

@media (max-width: 900px) {
  .notice-grid { grid-template-columns: 1fr; }
  .sg-list { grid-template-columns: 1fr; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .coming-soon { flex-direction: column; text-align: center; }
}
td.row-actions { display: table-cell; white-space: nowrap; }
td.row-actions > * + * { margin-left: .9rem; }


/* =========================================================
   Hintergrund: Carbon links, orange Diagonale, graue Bänder
   ========================================================= */
html {
  background:
    linear-gradient(125deg, transparent 32%, rgba(255, 255, 255, .028) 32%, rgba(255, 255, 255, .028) 52%, transparent 52%),
    linear-gradient(125deg, transparent 52%, rgba(255, 255, 255, .018) 52%, rgba(255, 255, 255, .018) 60%, transparent 60%),
    radial-gradient(90% 80% at 85% 90%, #191b1d 0%, transparent 70%),
    linear-gradient(125deg, #131416 0%, #0f1011 55%, #121315 100%);
  background-color: #0f1011;
  min-height: 100%;
}
body::before, body::after {
  content: ""; position: fixed; inset: 0; pointer-events: none;
}
/* Carbon-Struktur links der orangen Linie */
body::before {
  z-index: -2;
  background: var(--carbon); background-color: #121212; background-size: 18px 18px;
  -webkit-mask-image: linear-gradient(125deg, #000 0%, #000 25%, rgba(0, 0, 0, .55) 28.6%, transparent 28.9%);
          mask-image: linear-gradient(125deg, #000 0%, #000 25%, rgba(0, 0, 0, .55) 28.6%, transparent 28.9%);
}
/* Waben im grauen Band, orange Linie mit Glühen, feine helle Linie */
body::after {
  z-index: -1;
  background:
    linear-gradient(125deg, transparent 77.92%, rgba(255, 255, 255, .16) 78%, transparent 78.08%),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='28' height='49' viewBox='0 0 28 49'%3E%3Cg fill='none' stroke='%23ffffff' stroke-opacity='.07' stroke-width='1'%3E%3Cpath d='M14 9.5l12.5 7.2v14.6L14 38.5 1.5 31.3V16.7z'/%3E%3Cpath d='M14 0v9.5M14 38.5V49'/%3E%3C/g%3E%3C/svg%3E");
  background-size: auto, 28px 49px;
  -webkit-mask-image: linear-gradient(125deg, transparent 0%, transparent 28.4%, #000 28.5%, #000 45%, rgba(0, 0, 0, .35) 58%, rgba(0, 0, 0, .9) 77%, #000 79%, transparent 82%);
          mask-image: linear-gradient(125deg, transparent 0%, transparent 28.4%, #000 28.5%, #000 45%, rgba(0, 0, 0, .35) 58%, rgba(0, 0, 0, .9) 77%, #000 79%, transparent 82%);
}
body.auth::before, body.auth::after { display: none; }
.topbar { background: linear-gradient(180deg, rgba(8, 8, 8, .97), rgba(12, 12, 12, .94)); }

/* Texte-Seite */
.text-tabs { display: flex; gap: .5rem; flex-wrap: wrap; margin: 0 0 1.25rem; }
.text-tabs a { padding: .4rem .9rem; border-radius: 999px; background: var(--surface-3); border: 1px solid var(--line-strong); color: var(--ink); text-decoration: none; font-size: .9rem; }
.text-tabs a:hover { border-color: var(--orange); color: #fff; }
.text-field label { display: flex; align-items: center; gap: .6rem; }
.text-field.is-custom textarea { border-color: rgba(79, 209, 139, .45); }
.text-field .hint { margin-top: .2rem; }
.text-field .reset-text { margin-left: .5rem; font-size: .85rem; }


/* =========================================================
   Entwurf 3: Agrardrohnenportal mit großer Drohne rechts
   ========================================================= */
.brand { gap: 1.1rem; }
.brand img { height: 60px; }
.brand-title {
  font: 700 2.1rem/1 var(--font-display); letter-spacing: .06em; text-transform: uppercase; color: #fff;
  white-space: nowrap;
}
.brand-title span { color: var(--orange); }

.side-drone {
  position: fixed; right: -22vw; top: 50%; width: 78vw; max-width: 1500px; z-index: -1; pointer-events: none;
  transform: translateY(-40%) rotate(-8deg); opacity: .55;
  filter: drop-shadow(0 40px 60px rgba(0, 0, 0, .85));
  -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 35%);
          mask-image: linear-gradient(90deg, transparent 0%, #000 35%);
}
/* Seiten mittig (die frühere Verschiebung nach links für die Hintergrund-Drohne ist entfallen) */
@media (max-width: 1199px) {
  .side-drone { right: -40vw; width: 110vw; opacity: .25; }
}
@media (max-width: 1100px) { .brand-title { font-size: 1.6rem; } }
@media (max-width: 640px) {
  .brand-title { font-size: 1.15rem; letter-spacing: .03em; }
  .brand img { height: 40px; }
  .side-drone { display: none; }
}

/* =========================================================
   Runde 6: Hinweise, Dokumente, SEPA, Konto
   ========================================================= */
.topbar-inner { max-width: 1840px; }
.nav { gap: .15rem; }
.nav a, .nav .linkbtn { padding: .45rem .7rem; font-size: .92rem; }
.nav a[data-alert]::after { content: ""; display: inline-block; width: .5rem; height: .5rem; border-radius: 50%; background: var(--error); margin-left: .35rem; vertical-align: .1rem; box-shadow: 0 0 0 3px rgba(255, 106, 92, .25); }

/* Hinweisfelder vom Admin */
.admin-notice {
  border-radius: var(--radius); padding: .95rem 1.2rem; margin: 0 0 1.1rem;
  background: var(--surface-2); border: 1px solid var(--line); border-left: 4px solid var(--muted);
}
.admin-notice strong { display: block; font-family: var(--font-display); text-transform: uppercase; letter-spacing: .05em; color: var(--ink-strong); margin-bottom: .25rem; }
.admin-notice p { margin: 0; color: #d6d6d6; }
.admin-notice-info { border-left-color: #7fb2ff; }
.admin-notice-warn { border-left-color: var(--warn); background: var(--warn-soft); }
.admin-notice-important { border-left-color: var(--orange); background: linear-gradient(90deg, rgba(242, 107, 29, .2), var(--surface-2) 70%); border-color: rgba(242, 107, 29, .4); }
.notice-row .admin-notice { margin-bottom: .75rem; }
.notice-row.is-off { opacity: .55; }
.notice-meta { display: flex; gap: 1rem; align-items: center; flex-wrap: wrap; color: var(--muted); font-size: .88rem; }
.notice-meta .row-actions { margin-left: auto; }

/* PDF-Dokumente */
a.doc-link { font-weight: 600; }
.doc-card {
  display: inline-flex; align-items: center; gap: .9rem; margin: .25rem 0 1rem; padding: .75rem 1.1rem .75rem .8rem;
  border-radius: 10px; background: var(--field); border: 1px solid var(--line-strong); text-decoration: none; color: var(--ink);
  transition: border-color .15s, transform .15s;
}
.doc-card:hover { border-color: var(--orange); color: #fff; transform: translateY(-1px); }
.doc-card strong { display: block; color: var(--ink-strong); }
.doc-card small { color: var(--muted); }
.doc-icon {
  display: grid; place-items: center; width: 2.6rem; height: 3.1rem; border-radius: 4px 12px 4px 4px; flex-shrink: 0;
  background: linear-gradient(135deg, var(--amber), var(--orange)); color: #111; font: 700 .75rem/1 var(--font-display); letter-spacing: .06em;
}
.doc-card-small { margin: 0; padding: .45rem .9rem .45rem .5rem; }
.doc-card-small .doc-icon { width: 2rem; height: 2.4rem; font-size: .65rem; }
.doc-upload-row { display: flex; gap: 1.25rem; align-items: center; flex-wrap: wrap; }
input[type="file"] { color: var(--muted); font: inherit; font-size: .9rem; }
input[type="file"]::file-selector-button { font: inherit; margin-right: .75rem; padding: .5rem .9rem; border-radius: 8px; border: 1px solid var(--line-strong); background: var(--surface-3); color: var(--ink-strong); cursor: pointer; }

/* Countdown-Hinweis, Summen */
.countdown { max-width: 22rem; }
.countdown-hint { font-size: .78rem; line-height: 1.35; color: var(--muted); margin-top: .2rem; }
.area-total { font-size: 1.05rem; }
.area-total strong { color: var(--amber); font-weight: 700; }

/* SEPA */
.mandate-text p { color: #d9d9d9; }
.mandate-text .facts { margin-bottom: 1rem; }

/* =========================================================
   Runde 7: Kurz erklärt, Hilfe, Spritzgemeinschaft, Umriss-Editor
   ========================================================= */
.hero-dash { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(280px, 1fr); align-items: stretch; gap: 0; }
.hero-dash .hero-content { padding: 2rem 2.25rem 2.1rem; max-width: none; }
.hero-dash .countdown { margin: 1.4rem 0 0; }
.guide {
  margin: 1.4rem 1.4rem 1.6rem 0; padding: 1.1rem 1.3rem; border-radius: 12px;
  background: rgba(0, 0, 0, .38); border: 1px solid rgba(255, 255, 255, .08); align-self: center;
}
.guide h2 { font-size: 1rem; margin: 0 0 .6rem; color: var(--orange-hi); letter-spacing: .12em; }
.guide dl { margin: 0; display: grid; gap: .55rem; }
.guide dl > div { display: grid; grid-template-columns: 11.5rem 1fr; gap: .75rem; align-items: baseline; padding-bottom: .5rem; border-bottom: 1px solid rgba(255, 255, 255, .06); }
.guide dl > div:last-child { border-bottom: 0; padding-bottom: 0; }
.guide dt a { color: var(--ink-strong); font-weight: 600; text-decoration: none; }
.guide dt a::after { content: " →"; color: var(--orange); }
.guide dt a:hover { color: var(--amber); }
.guide dd { margin: 0; color: #c9c9c9; font-size: .9rem; line-height: 1.4; }

/* Frist abgelaufen: deutlich rot */
.countdown.is-over {
  border: 2px solid var(--error); background: linear-gradient(135deg, rgba(255, 106, 92, .28), rgba(120, 20, 15, .35));
  box-shadow: 0 0 0 4px rgba(255, 106, 92, .12);
}
.countdown.is-over .countdown-label { color: #ffb3aa; font-size: .85rem; }
.countdown-over { font: 700 1.5rem/1.1 var(--font-display); color: #fff; text-transform: uppercase; letter-spacing: .03em; }
.countdown.is-over .countdown-hint { color: #ffd9d4; }

/* Hilfe */
.help-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.25rem; }
.help-grid .panel { margin: 0; display: flex; flex-direction: column; }
.help-card p { flex: 1; }
.help-card .btn { align-self: flex-start; word-break: break-all; }
.help-num { display: grid; place-items: center; width: 2.2rem; height: 2.2rem; border-radius: 50%; margin-bottom: .8rem;
  background: linear-gradient(135deg, var(--amber), var(--orange)); color: #111; font: 700 1.1rem/1 var(--font-display); }

/* Meine Spritzgemeinschaft */
.sg-public h3 { font: 600 .95rem/1.2 var(--font-display); text-transform: uppercase; letter-spacing: .08em; color: var(--orange-hi); margin: 0 0 .6rem; }
.sg-public-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 1.5rem; margin-top: .5rem; }
.sg-news { background: var(--field); border: 1px solid var(--line); border-left: 3px solid var(--orange); border-radius: 8px; padding: .9rem 1rem; }
.contact-card { display: flex; flex-direction: column; gap: .1rem; padding: .7rem .9rem; margin-bottom: .6rem; background: var(--field); border: 1px solid var(--line); border-radius: 8px; }
.contact-card strong { color: var(--ink-strong); }
.contact-rows { display: grid; gap: .5rem; }
.contact-row { display: grid; grid-template-columns: 1.2fr 1.2fr 1fr 1.4fr; gap: .5rem; }

/* Umriss-Editor */
.map-editor { height: 68vh; min-height: 420px; }
.editor-wrap { position: relative; margin-bottom: 1rem; }
.editor-tools { position: absolute; left: 12px; top: 12px; z-index: 500; display: flex; gap: .5rem; }
.editor-tools .btn { background: rgba(20, 20, 20, .9); }
.editor-help { display: flex; flex-wrap: wrap; gap: .5rem 1.5rem; margin: 0 0 .9rem; font-size: .88rem; color: #cfcfcf; }
.editor-help b { color: var(--orange-hi); font-weight: 600; }
.area-live { text-align: right; color: var(--muted); font-size: .85rem; }
.area-live strong { display: block; font: 700 1.8rem/1.1 var(--font-display); color: var(--amber); }
.vx { background: #fff; border: 3px solid var(--orange); border-radius: 3px; box-shadow: 0 1px 4px rgba(0, 0, 0, .6); cursor: move; }
.vx-mid { background: rgba(255, 255, 255, .55); border: 2px solid #fff; border-radius: 50%; cursor: copy; }

@media (max-width: 1100px) {
  .hero-dash { grid-template-columns: 1fr; }
  .guide { margin: 0 1.4rem 1.6rem; }
  .help-grid, .sg-public-grid { grid-template-columns: 1fr; }
  .contact-row { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 640px) { .guide dl > div { grid-template-columns: 1fr; gap: .1rem; } }
.hero-dash .hero-content { min-width: 0; }
.hero-dash h1 { overflow-wrap: anywhere; }
.guide dl > div { grid-template-columns: 10.5rem 1fr; }

/* =========================================================
   Runde 8: Drohne in der Kopfzeile (Entwurf A)
   ========================================================= */
.side-drone { display: none !important; }
body:not(.auth) .page { margin-left: auto; margin-right: auto; }
.topbar { overflow: hidden; }
.topbar::after {
  content: ""; position: absolute; right: 0; top: 0; bottom: 0; width: 45%; pointer-events: none;
  background: radial-gradient(60% 90% at 72% 45%, rgba(242, 107, 29, .2), transparent 70%);
}
.topbar-inner { position: relative; flex-wrap: wrap; padding-top: .7rem; padding-bottom: .55rem; row-gap: .35rem; }
.brand, .nav { position: relative; z-index: 1; }
.nav { order: 3; width: 100%; }
.head-drone {
  position: absolute; right: 2.5%; top: 4px; height: 92px; width: auto; transform: rotate(-4deg);
  pointer-events: none; z-index: 0; filter: drop-shadow(0 8px 14px rgba(0, 0, 0, .8));
}
@media (max-width: 900px) { .head-drone { height: 90px; opacity: .6; } }
@media (max-width: 640px) { .head-drone { display: none; } }

/* Keine abgehackten Wörter */
.help-card .btn { word-break: normal; }
.hero-dash h1 { overflow-wrap: break-word; hyphens: manual; }
.guide dt a::after { content: none; }
.guide dt a .arr { color: var(--orange); white-space: nowrap; }
.mail-line { font-weight: 600; color: var(--ink-strong); overflow-wrap: anywhere; margin: 0 0 .9rem; }

/* Über uns */
.about.has-images { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 2rem; align-items: start; }
.about-text { font-size: 1.05rem; line-height: 1.7; color: #e0e0e0; }
.about-images { display: grid; gap: 1rem; }
.about-images figure { margin: 0; }
.about-images img { width: 100%; height: auto; display: block; border-radius: 10px; border: 1px solid var(--line); box-shadow: 0 14px 30px rgba(0, 0, 0, .45); }
.about-images figcaption { color: var(--muted); font-size: .88rem; margin-top: .4rem; }
.about-admin-images { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 1rem; margin-bottom: 1.25rem; }
.about-admin-img { display: grid; gap: .5rem; background: var(--field); border: 1px solid var(--line); border-radius: 10px; padding: .75rem; }
.about-admin-img img { width: 100%; height: 170px; object-fit: cover; border-radius: 6px; }
@media (max-width: 900px) { .about.has-images { grid-template-columns: 1fr; } }

/* Runde 9: größere Drohne in der Kopfzeile, IBAN-Prüfung, Zuordnung */
.topbar-inner { min-height: 128px; align-content: space-between; }
.head-drone { height: 120px; top: 4px; right: 2%; }
@media (max-width: 900px) { .topbar-inner { min-height: 0; } .head-drone { height: 90px; } }
.iban-note { margin: .25rem 0 0; font-size: .88rem; font-weight: 600; }
.iban-note.ok { color: var(--ok); }
.iban-note.bad { color: var(--error); }
input.is-valid { border-color: var(--ok) !important; }
input.is-invalid { border-color: var(--error) !important; }
.sg-assign { display: flex; flex-wrap: wrap; gap: .6rem; }
.sg-chip { padding: .5rem .85rem; border: 1px solid var(--line-strong); border-radius: 999px; background: var(--field); }
.sg-chip.is-auto { border-color: rgba(79, 209, 139, .4); }
.sg-assign .actions { width: 100%; }
.sg-pick { border: 0; padding: 0; margin: 0; }
@media (max-width: 1400px) { .head-drone { height: 104px; right: -1.5%; } }
.nav .logout { text-shadow: 0 1px 6px rgba(0, 0, 0, .9); }

/* Runde 10: Filterleiste, Löschen */
.filter-bar { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: .9rem 1rem; }
.filter-bar select { min-width: 8.5rem; }
.filter-search { flex: 1 1 260px; }
.filter-search input { width: 100% !important; min-width: 220px; }
.panel-danger { border-color: rgba(255, 106, 92, .35); }
.panel-danger .inline-form .field { min-width: 18rem; display: flex; flex-direction: column; gap: .3rem; font-size: .9rem; }
.btn-danger { background: linear-gradient(135deg, #ff7a6b, #d63a2c); color: #fff; box-shadow: 0 6px 18px rgba(214, 58, 44, .3); }
.btn-danger:hover { color: #fff; }
.no-profile summary { cursor: pointer; color: var(--muted); }
.no-profile[open] summary { margin-bottom: .75rem; }
.bulk-bar { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; margin: 0 0 .75rem; }
.bulk-bar .btn { padding: .5rem 1rem; }
.bulk-bar .btn:disabled { opacity: .4; box-shadow: none; cursor: not-allowed; transform: none; filter: grayscale(.6); }
.sel-col { width: 2.5rem; text-align: center !important; }
.sel-col input { width: 1.15rem; height: 1.15rem; cursor: pointer; }
.data tbody tr.is-checked { background: rgba(255, 106, 92, .1); }
/* Ebenen-Auswahl der Karte */
.leaflet-control-layers-expanded { padding: .5rem .75rem; border-radius: 8px; font: 13px/1.4 var(--font); color: #1a1a1a; }
.leaflet-control-layers-separator { margin: .35rem 0; }
.leaflet-control-layers label { margin: .15rem 0; cursor: pointer; }
/* Hinweis zum Mausrad-Zoom */
.map { position: relative; }
.map-zoom-hint {
  position: absolute; inset: 0; z-index: 900; display: grid; place-items: center; pointer-events: none;
  background: rgba(0, 0, 0, .45); color: #fff; font: 600 1rem/1.3 var(--font); text-align: center; padding: 1rem;
  opacity: 0; transition: opacity .2s;
}
.map.show-hint .map-zoom-hint { opacity: 1; }

/* =========================================================
   Runde 11: Statuskarte, Hilfe, Flächenkopf, Dialoge
   ========================================================= */
.status-card { display: grid; grid-template-columns: 1fr auto; gap: 1.2rem 2rem; align-items: center; padding: 1.8rem 2rem; position: relative; overflow: hidden; }
.status-card::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 6px; }
.status-ok::before { background: var(--ok); }
.status-bad::before { background: var(--error); }
.status-main { display: flex; gap: 1.2rem; align-items: center; min-width: 0; }
.status-icon { width: 64px; height: 64px; border-radius: 50%; display: grid; place-items: center; font: 700 2rem/1 var(--font-display); flex-shrink: 0; }
.status-ok .status-icon { background: var(--ok-soft); color: var(--ok); box-shadow: 0 0 0 2px rgba(79, 209, 139, .4); }
.status-bad .status-icon { background: var(--error-soft); color: var(--error); box-shadow: 0 0 0 2px rgba(255, 106, 92, .45); }
.status-main .eyebrow { margin: 0 0 .2rem; }
.status-title { font-size: 2.1rem; margin: 0; text-transform: uppercase; letter-spacing: .02em; line-height: 1.1; }
.status-ok .status-title { color: var(--ok); }
.status-bad .status-title { color: var(--error); }
.status-sub { margin: .3rem 0 0; color: #cfcfcf; }
.status-stats { display: flex; gap: .75rem; flex-wrap: wrap; }
.status-stats div { background: var(--field); border: 1px solid var(--line); border-radius: 10px; padding: .7rem 1rem; min-width: 7.5rem; text-align: center; }
.status-stats b { display: block; font: 700 1.6rem/1.1 var(--font-display); color: #fff; }
.status-stats span { font-size: .8rem; color: var(--muted); }
.status-note { grid-column: 1 / -1; margin: 0; padding: .8rem 1rem; border-radius: 8px; background: var(--warn-soft); color: #fbe7c0; }
.status-actions { grid-column: 1 / -1; margin: 0; }
@media (max-width: 900px) { .status-card { grid-template-columns: 1fr; } .status-title { font-size: 1.6rem; } }

/* Hilfe */
.help-wide .help-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.5rem; }
.help-wide .help-card { padding: 1.8rem 2rem; }
.help-wide .help-card h2 { font-size: 1.25rem; line-height: 1.2; }
.help-sg { background: var(--field); border: 1px solid var(--line); border-left: 3px solid var(--orange); border-radius: 10px; padding: .9rem 1rem; margin: 0 0 .9rem; }
.help-sg-label { display: block; font: 600 .72rem/1 var(--font-display); text-transform: uppercase; letter-spacing: .14em; color: var(--orange-hi); margin-bottom: .35rem; }
.help-sg-name { display: block; font: 700 1.25rem/1.2 var(--font-display); color: #fff; margin-bottom: .6rem; }
.help-contact { display: flex; flex-direction: column; gap: .1rem; font-size: .92rem; }
.help-contact + .help-contact { margin-top: .6rem; padding-top: .6rem; border-top: 1px solid var(--line); }
.help-contact span { color: var(--muted); }
.help-card .actions-bottom { margin-top: auto; padding-top: .4rem; }

/* Kopf der Flächenseite */
.plots-head { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: 1.5rem; margin-bottom: 1.5rem;
  background: linear-gradient(135deg, #1d1d1d, #121212); border: 1px solid var(--line); border-radius: 16px; padding: 1.8rem 2rem; }
.plots-head h1 { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem; }
.plots-head h1 .badge { font-size: 1rem; padding: .45rem 1rem; margin: 0; }
.plots-head .lead { margin-bottom: 1rem; }
.plots-head .countdown { max-width: none; }
.plots-head-notes { display: flex; flex-direction: column; gap: .75rem; }
.plots-head-notes .notice { margin: 0; padding: .8rem 1rem; }
.plots-head-notes .notice p { font-size: .88rem; }
@media (max-width: 900px) { .plots-head { grid-template-columns: 1fr; } }

/* Rückfragen im Portal-Design */
.modal-back { position: fixed; inset: 0; z-index: 5000; background: rgba(0, 0, 0, .65); backdrop-filter: blur(4px); display: grid; place-items: center; padding: 1rem; animation: fadeIn .15s ease-out; }
.modal { width: min(470px, 100%); background: linear-gradient(180deg, #1f1f1f, #151515); border: 1px solid var(--line-strong); border-top: 3px solid var(--orange);
  border-radius: 14px; padding: 1.8rem 1.8rem 1.5rem; box-shadow: 0 30px 80px rgba(0, 0, 0, .7); text-align: center; animation: popIn .18s ease-out; }
.modal-icon { width: 56px; height: 56px; margin: 0 auto .9rem; border-radius: 50%; display: grid; place-items: center; font: 700 1.8rem/1 var(--font-display);
  background: var(--orange-soft); color: var(--orange-hi); box-shadow: 0 0 0 2px rgba(242, 107, 29, .45); }
.modal.is-danger .modal-icon { background: var(--error-soft); color: var(--error); box-shadow: 0 0 0 2px rgba(255, 106, 92, .4); }
.modal h2 { font-size: 1.4rem; margin-bottom: .6rem; }
.modal p { color: #d6d6d6; margin: 0 0 .6rem; white-space: pre-line; }
.modal-hint { font-size: .88rem; color: var(--warn) !important; }
.modal input { margin-top: .4rem; text-align: center; font-weight: 600; letter-spacing: .08em; }
.modal-actions { display: flex; gap: .75rem; justify-content: center; margin-top: 1.2rem; flex-wrap: wrap; }
@keyframes fadeIn { from { opacity: 0; } }
@keyframes popIn { from { opacity: 0; transform: translateY(8px) scale(.98); } }
/* Import */
.progress { height: 12px; border-radius: 999px; background: var(--field); border: 1px solid var(--line); overflow: hidden; margin: .5rem 0; }
.progress-bar { height: 100%; background: linear-gradient(90deg, var(--amber), var(--orange)); transition: width .3s; }
.data tbody tr.row-skip { opacity: .65; }
.login-edit { display: flex; gap: .5rem; align-items: center; flex-wrap: wrap; }
.login-edit input { max-width: 20rem; padding: .45rem .6rem; }
.login-edit .btn { padding: .45rem .9rem; }
/* Dokumente */
.doc-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 1rem; }
.doc-tile { display: flex; gap: 1rem; align-items: flex-start; padding: 1.2rem 1.3rem; border-radius: 12px; text-decoration: none; color: var(--ink);
  background: linear-gradient(180deg, rgba(28,28,28,.96), rgba(19,19,19,.96)); border: 1px solid var(--line); transition: border-color .15s, transform .15s; }
.doc-tile:hover { border-color: var(--orange); transform: translateY(-2px); color: #fff; }
.doc-tile .doc-icon { width: 3rem; height: 3.6rem; font-size: .8rem; }
.doc-tile-text { display: flex; flex-direction: column; gap: .25rem; min-width: 0; }
.doc-tile-text strong { color: #fff; font-size: 1.02rem; line-height: 1.3; }
.doc-tile-text small { color: #bdbdbd; font-size: .88rem; line-height: 1.4; }
.doc-tile-text .doc-meta { color: var(--muted); font-size: .8rem; }
.doc-admin-row { display: flex; gap: 1rem; align-items: center; flex-wrap: wrap; padding: .8rem 0; border-bottom: 1px solid var(--line); }
.doc-admin-row:last-child { border-bottom: 0; }
.doc-admin-form { display: flex; gap: .5rem; flex: 1; flex-wrap: wrap; align-items: center; }
.doc-admin-form input, .doc-admin-form select { width: auto; flex: 1 1 160px; padding: .45rem .6rem; }
.doc-admin-form .sort-input { flex: 0 0 4.5rem; }
.doc-admin-form .btn { padding: .45rem .9rem; }
.legend-vine { background: rgba(157, 78, 221, .45); border: 2px dashed #c77dff; }
.vine-hint { background: rgba(20, 20, 20, .85); color: #eee; padding: .35rem .6rem; border-radius: 6px; font: 12px/1.3 var(--font); }
.legend-normal { background: rgba(242, 107, 29, .55) !important; border: 2px solid #ff8a3d !important; }
.legend-near { background: rgba(242, 107, 29, .55) !important; border: 2px solid #ffd166 !important; }
.legend-parcel { background: transparent; border: 2px dashed #ff8a3d; }
.legend-partial { background: rgba(242, 107, 29, .55); border: 2px solid #2f8cff; }
.legend-near { background: rgba(242, 107, 29, .55) !important; border: 2px solid #ff3b30 !important; }
.legend-parcel { background: rgba(255, 255, 255, .08) !important; border: 2px solid #ffb27a !important; }
.legend-normal { background: rgba(242, 107, 29, .6) !important; border: 1px solid #ffd0ad !important; }
.legend-partial { background: transparent !important; border: 2px solid #2f8cff !important; }
.legend-near { background: transparent !important; border: 2px solid #ff3b30 !important; }
td.cb { text-align: center; }
.flag-form input[type="checkbox"] { width: 1.2rem; height: 1.2rem; cursor: pointer; accent-color: var(--orange); }
/* Legende: grün = Flurstück komplett, orange = Flurstück Nutzung */
.legend-parcel { background: rgba(95, 211, 141, .45) !important; border: 2px solid #d8ffe6 !important; }
.legend-normal { background: rgba(242, 107, 29, .65) !important; border: 1px solid #ffd0ad !important; }
.leaflet-control-layers .layers-note { margin-top: .35rem; padding-top: .35rem; border-top: 1px solid #ddd; font-size: 11.5px; color: #555; max-width: 12rem; }
.small-text { font-size: .8rem; line-height: 1.35; color: #c9c9c9; min-width: 11rem; }
.map-info div { white-space: pre-wrap; }

/* Spaltenfilter wie in Excel */
.data th { white-space: nowrap; }
.tf-btn { margin-left: .35rem; padding: .15rem .25rem; border: 1px solid transparent; border-radius: 4px; background: rgba(255,255,255,.06);
  color: #9b9b9b; cursor: pointer; vertical-align: middle; line-height: 0; }
.tf-btn:hover { color: #fff; border-color: var(--line-strong); }
.tf-btn.is-active { color: #111; background: var(--orange); }
.data tbody tr.tf-hidden { display: none; }
.tf-counter { margin: 0 0 .5rem; font-size: .88rem; color: var(--orange-hi); }
.tf-menu { position: absolute; z-index: 6000; width: 270px; padding: .6rem; border-radius: 10px; background: #1d1d1d; border: 1px solid var(--line-strong);
  box-shadow: 0 18px 50px rgba(0,0,0,.6); font-size: .88rem; color: var(--ink); display: flex; flex-direction: column; gap: .4rem; }
.tf-menu .tf-sort { text-align: left; background: none; border: 0; color: var(--ink); padding: .35rem .4rem; border-radius: 6px; cursor: pointer; font: inherit; }
.tf-menu .tf-sort:hover { background: rgba(255,255,255,.07); }
.tf-menu .tf-search { padding: .4rem .55rem; font-size: .88rem; }
.tf-menu .tf-all { padding: .2rem .4rem; font-weight: 600; cursor: pointer; }
.tf-menu .tf-list { max-height: 240px; overflow: auto; border: 1px solid var(--line); border-radius: 6px; padding: .3rem; background: var(--field); }
.tf-menu .tf-list label { display: block; padding: .2rem .3rem; cursor: pointer; border-radius: 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tf-menu .tf-list label:hover { background: rgba(255,255,255,.06); }
.tf-menu input[type=checkbox] { accent-color: var(--orange); vertical-align: middle; }
.tf-menu .tf-count { color: var(--muted); font-size: .8rem; }
.tf-menu .tf-actions { display: flex; gap: .5rem; justify-content: flex-end; }
.tf-menu .tf-actions .btn { padding: .4rem .8rem; font-size: .85rem; }

/* Ausgeblendete Elemente wirklich ausblenden (z. B. Knopf „Fertig“ im Umriss-Editor) */
[hidden] { display: none !important; }

/* Vollbild für Karten und Tabellen */
.fs-bar { display: flex; justify-content: flex-end; margin: 0 0 .35rem; }
.fs-btn { display: inline-flex; align-items: center; gap: .35rem; padding: .3rem .7rem; border-radius: 6px; border: 1px solid var(--line-strong);
  background: rgba(255,255,255,.04); color: #cfcfcf; font: 600 .8rem/1 var(--font); cursor: pointer; }
.fs-btn:hover { color: #fff; border-color: var(--orange); }
.fs-close { position: sticky; top: .5rem; left: 100%; float: right; z-index: 5; margin: .5rem; background: #1d1d1d; }
.table-wrap:fullscreen, .table-wrap.is-fs { background: var(--bg, #111); padding: 1rem; overflow: auto; max-height: none; border-radius: 0; }
.table-wrap.is-fs { position: fixed; inset: 0; z-index: 7000; }
.table-wrap:fullscreen table.data, .table-wrap.is-fs table.data { min-width: 100%; }
.map:fullscreen, .map.is-fs { width: 100vw !important; height: 100vh !important; max-height: none !important; border-radius: 0 !important; }
.map.is-fs { position: fixed !important; inset: 0; z-index: 7000; }
body.fs-lock { overflow: hidden; }
.map-fs-btn { font-size: 17px; line-height: 30px !important; text-align: center; font-weight: 700; }
/* Admin: Kundendaten bearbeiten */
.admin-edit { margin-top: 1rem; }
.admin-edit > summary { list-style: none; display: inline-flex; cursor: pointer; }
.admin-edit > summary::-webkit-details-marker { display: none; }
.admin-edit[open] > summary { margin-bottom: 1rem; }
.plot-edit-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: .75rem 1rem; align-items: end; }
.plot-edit-grid label { display: flex; flex-direction: column; gap: .3rem; font-size: .88rem; color: var(--muted); }
.plot-edit-grid label.check-inline { flex-direction: row; align-items: center; color: var(--ink); }
/* Kundenliste: ganze Zeile klickbar */
.data tbody tr.row-link { cursor: pointer; }
.data tbody tr.row-link:hover td { background: rgba(242, 107, 29, .08); }
/* Hinweis bei Bewirtschaftung */
.farming-note { flex: 1 1 260px; margin: 0; align-self: center; font-size: .85rem; line-height: 1.45; color: var(--muted); }
.esri-test { display: flex; gap: 1rem; flex-wrap: wrap; }
.esri-test figure { margin: 0; width: 256px; border: 2px solid var(--line); border-radius: 8px; overflow: hidden;
  background: #3a4a3a url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16'%3E%3Crect width='8' height='8' fill='%23445544'/%3E%3Crect x='8' y='8' width='8' height='8' fill='%23445544'/%3E%3C/svg%3E"); }
.esri-test figure.fail { border-color: var(--error); }
.esri-test img { display: block; width: 256px; height: 256px; }
.esri-test .stack { position: relative; display: block; width: 256px; height: 256px; }
.esri-test .stack img { position: absolute; inset: 0; }
.esri-test figcaption { padding: .4rem .6rem; font-size: .82rem; background: #1b1b1b; color: #ddd; }
.login-list { margin-top: .35rem; font-size: .88rem; }
.login-list summary { cursor: pointer; color: var(--orange-hi); }
.login-list ul { margin: .35rem 0 0; padding-left: 1.1rem; color: #cfcfcf; }
/* Spritzvorstand */
.board-card { border: 1px solid var(--line); border-radius: 12px; padding: 1rem 1.2rem; margin-bottom: 1rem; background: rgba(255,255,255,.02); }
.board-head { display: flex; gap: .75rem; align-items: baseline; flex-wrap: wrap; margin-bottom: .5rem; }
.board-head strong { font-size: 1.05rem; color: #fff; }
.perm-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: .35rem 1rem; margin: .4rem 0 .6rem; }
.perm-grid .check-inline { font-size: .92rem; }
/* Formatierungsleiste und formatierte Texte */
.rt-bar { display: flex; flex-wrap: wrap; gap: .3rem; align-items: center; margin: 0 0 .3rem; }
.rt-bar button { min-width: 2.1rem; padding: .25rem .55rem; border-radius: 5px; border: 1px solid var(--line-strong); background: #222; color: #eee; cursor: pointer; font: 600 .85rem/1.2 var(--font); }
.rt-bar button:hover { border-color: var(--orange); color: #fff; }
.rt-bar .rt-help { margin-left: .4rem; font-size: .76rem; color: var(--muted); }
.rt-list { margin: .3rem 0 .5rem; padding-left: 1.3rem; }
.rt-list li { margin: .15rem 0; }
.rt-h { display: block; margin: .6rem 0 .2rem; font: 700 1.02rem/1.3 var(--font-display); text-transform: uppercase; letter-spacing: .04em; color: #fff; }
.sg-area { margin: 0 0 1rem; padding: .8rem 1rem; border-radius: 10px; background: var(--field); border: 1px solid var(--line); }
.sg-area h3 { margin: 0 0 .35rem; }
/* Spritzgemeinschaft: Gemarkungen/Fluren auswählen */
.rule-picker { display: flex; flex-wrap: wrap; gap: .6rem; align-items: flex-start; margin-bottom: .6rem; }
.rule-picker select { width: auto; min-width: 16rem; }
.rp-fluren { display: flex; flex-wrap: wrap; gap: .3rem 1rem; padding: .5rem .7rem; border: 1px solid var(--line); border-radius: 8px; background: var(--field); max-width: 40rem; }
.rp-fluren .rp-extra { width: 4.5rem; padding: .25rem .4rem; }
.chip-x { margin-left: .2rem; border: 0; background: none; color: var(--muted); cursor: pointer; font-size: 1rem; line-height: 1; }
.chip-x:hover { color: var(--error); }

/* Drohne in der Kopfzeile etwas kleiner, Menü darf nicht darunter liegen */
.topbar-inner { min-height: 108px; }
.head-drone { height: 96px; top: 6px; right: 1.5%; }
.nav a { text-shadow: 0 1px 6px rgba(0, 0, 0, .9); }
@media (min-width: 1500px) { .nav { padding-right: 300px; } }
@media (max-width: 1499px) { .head-drone { height: 82px; right: 1%; opacity: .55; } }
@media (max-width: 900px)  { .topbar-inner { min-height: 0; } .head-drone { height: 70px; opacity: .45; } }
@media (max-width: 640px)  { .head-drone { display: none; } }

/* =========================================================
   Statusleiste der Winzer
   ========================================================= */
.sbar { max-width: var(--page-max, 1240px); margin: 1.1rem auto 0; padding: 0 1.5rem; }
.sbar-in { display: flex; align-items: stretch; border-radius: 14px; overflow: hidden; border: 1px solid var(--line-strong);
  background: linear-gradient(180deg, #1e1e1e, #151515); box-shadow: 0 10px 30px rgba(0, 0, 0, .45); }
.sbar-title { padding: .9rem 1.2rem; display: flex; flex-direction: column; justify-content: center; border-right: 1px solid var(--line); min-width: 150px; }
.sbar-title small { font: 700 .72rem/1 var(--font-display); letter-spacing: .16em; text-transform: uppercase; color: var(--orange-hi); }
.sbar-title b { font: 700 1.15rem/1.2 var(--font-display); text-transform: uppercase; color: #fff; margin-top: .25rem; }
.sbar .steps { display: flex; flex: 1; min-width: 0; }
.sbar .step { flex: 1; display: flex; gap: .6rem; align-items: center; padding: .75rem .8rem; min-width: 0; color: inherit; text-decoration: none; }
.sbar a.step:hover { background: rgba(255, 255, 255, .04); }
.sbar .step + .step { border-left: 1px solid var(--line); }
.sbar .ic { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; font: 700 1rem/1 var(--font-display); flex-shrink: 0; }
.sbar .ok .ic { background: var(--ok-soft); color: var(--ok); box-shadow: 0 0 0 2px rgba(79, 209, 139, .45); }
.sbar .bad .ic { background: var(--error-soft); color: var(--error); box-shadow: 0 0 0 2px rgba(255, 106, 92, .45); }
.sbar .wait .ic { background: rgba(255, 255, 255, .06); color: #aaa; box-shadow: 0 0 0 2px rgba(255, 255, 255, .14); }
.sbar .tx { min-width: 0; }
.sbar .tx b { display: block; color: #fff; font-size: .92rem; white-space: nowrap; }
.sbar .tx span { display: block; font-size: .8rem; color: var(--muted); line-height: 1.35; }
.sbar .bad .tx b { color: #ffb4ab; }
.sbar-act { display: flex; flex-direction: column; justify-content: center; align-items: flex-end; gap: .4rem; padding: .7rem 1.1rem;
  border-left: 1px solid var(--line); background: rgba(242, 107, 29, .06); min-width: 200px; }
.sbar-act .cd, .sbar-slim .cd { font-size: .8rem; color: #ffb4ab; }
.sbar-act .cd b, .sbar-slim .cd b { font: 700 1.05rem var(--font-display); color: #ff8a7a; }
.sbar-act .btn { padding: .6rem 1.1rem; font-size: .92rem; }
.sbar-act.done { background: rgba(79, 209, 139, .06); }
.sbar-act.done .cd { color: #9fe3bd; }
.sbar-act.done .cd b { color: var(--ok); }
/* schmale Leiste auf den anderen Seiten */
.sbar-slim { margin-top: .8rem; }
.sbar-slim .sbar-in { align-items: center; gap: .9rem; padding: .45rem .6rem .45rem 1rem; border-radius: 10px; box-shadow: none; flex-wrap: wrap; }
.sbar-label { font: 700 .78rem/1 var(--font-display); letter-spacing: .12em; text-transform: uppercase; color: var(--orange-hi); white-space: nowrap; }
.sb-minis { display: flex; gap: .4rem; flex-wrap: wrap; flex: 1; }
.sb-mini { font-size: .78rem; padding: .2rem .55rem; border-radius: 999px; border: 1px solid var(--line-strong); color: #ccc; white-space: nowrap; }
.sb-mini.ok { border-color: rgba(79, 209, 139, .45); color: #9fe3bd; }
.sb-mini.bad { border-color: rgba(255, 106, 92, .55); color: #ffb4ab; }
.sbar-slim .btn { padding: .4rem .9rem; font-size: .85rem; }
@media (max-width: 760px) {
  .sbar { padding: 0 .8rem; }
  .sbar-in { flex-direction: column; }
  .sbar-title { border-right: 0; border-bottom: 1px solid var(--line); padding: .7rem 1rem; }
  .sbar .steps { display: grid; grid-template-columns: 1fr 1fr; }
  .sbar .step + .step { border-left: 0; }
  .sbar .step { border-top: 1px solid var(--line); }
  .sbar .step:nth-child(odd) { border-right: 1px solid var(--line); }
  .sbar .step:nth-child(-n+2) { border-top: 0; }
  .sbar .ic { width: 28px; height: 28px; font-size: .85rem; }
  .sbar-act { flex-direction: row; align-items: center; justify-content: space-between; border-left: 0; border-top: 1px solid var(--line); min-width: 0; }
  .sbar-slim .sb-minis { display: none; }
}
.sbar-act .btn, .sbar-slim .btn { white-space: nowrap; }
/* Ansprechpartner mit Zuständigkeitsbereich */
.contact-row { grid-template-columns: 1.1fr 1.1fr 1fr 1.3fr; }
.contact-row .contact-area { grid-column: 1 / -1; }
.contact-rows .contact-row + .contact-row { padding-top: .5rem; border-top: 1px dashed var(--line); }
.ct-area { display: block; font-size: .85rem; color: var(--muted); margin-top: .15rem; }

/* Runde 45: Kopfzeile mit mehr Luft, flachere Statusleiste, schmale Leiste mit Abstand */
.topbar-inner { row-gap: 1.1rem; padding-top: 1rem; padding-bottom: .7rem; }
.nav { margin-top: .2rem; }
.head-drone { height: 88px; top: 8px; }
@media (max-width: 1499px) { .head-drone { height: 74px; top: 10px; opacity: .75; } }
@media (max-width: 900px)  { .head-drone { height: 62px; opacity: .45; } }
@media (max-width: 640px)  { .head-drone { display: none; } }

.sbar-title { padding: .55rem 1.3rem; min-width: 200px; }
.sbar-title small { font-size: .8rem; }
.sbar-title b { font-size: 1.55rem; margin-top: .2rem; }
.sbar .step { padding: .5rem .8rem; }
.sbar .ic { width: 30px; height: 30px; }
.sbar .tx b { white-space: normal; }
.sbar-act { padding: .5rem 1.1rem; }
.sbar-act .btn { padding: .5rem 1.1rem; }
@media (max-width: 1100px) and (min-width: 761px) {
  .sbar-in { flex-wrap: wrap; }
  .sbar-title { flex: 1 1 100%; flex-direction: row; align-items: baseline; justify-content: center; gap: .8rem; border-right: 0; border-bottom: 1px solid var(--line); }
  .sbar .steps { flex: 1 1 60%; }
  .sbar-act { flex: 1 1 220px; }
}
.sbar-slim { margin-top: 1rem; margin-bottom: 1.6rem; }
.sbar-slim .sbar-in { padding: .4rem .6rem .4rem 1rem; flex-wrap: nowrap; }
.sbar-slim .sbar-label { font-size: .85rem; }
.sbar-slim .sb-minis { flex-wrap: nowrap; overflow: hidden; }
.sbar-slim .cd { white-space: nowrap; margin-left: auto; }
@media (max-width: 1000px) { .sbar-slim .sb-minis { display: none; } }
@media (max-width: 600px)  { .sbar-slim .sbar-in { flex-wrap: wrap; } .sbar-slim .sbar-label { flex: 1 1 100%; } }
.map-info .map-edit { display: inline-block; margin-top: .5rem; padding: .3rem .8rem; border-radius: 6px; background: linear-gradient(135deg, #f9a51a, #f26b1d);
  color: #111 !important; font-weight: 700; text-decoration: none; }
.panel-edit .plot-edit-grid { margin-bottom: .8rem; }
.panel-edit .plot-edit-grid input { width: 100%; }
.map-info .map-actions { display: flex; gap: .4rem; margin-top: .5rem; }
.map-info .map-actions .map-edit { margin-top: 0; }
.map-info .map-del { padding: .3rem .8rem; border-radius: 6px; border: 1px solid #d63a2c; background: #fff; color: #c0281b; font: 700 12px/1.4 inherit; cursor: pointer; }
.map-info .map-del:hover { background: #d63a2c; color: #fff; }
/* Karte: nur ausgewählte Flurstücke */
.map-info .map-only { display: block; margin-top: .5rem; padding: .3rem .8rem; border-radius: 6px; border: 1px solid #999; background: #f4f4f4; color: #222; font: 600 12px/1.4 inherit; cursor: pointer; }
.map-info .map-only:hover { background: #e8e8e8; }
.map-showall { background: #1b1b1b; border: 1px solid var(--orange); border-radius: 8px; padding: .35rem .5rem; color: #fff; font: 12px/1.3 var(--font); display: flex; gap: .5rem; align-items: center; box-shadow: 0 4px 14px rgba(0,0,0,.5); }
.map-showall button { border: 0; border-radius: 6px; padding: .3rem .6rem; background: linear-gradient(135deg, #f9a51a, #f26b1d); color: #111; font-weight: 700; cursor: pointer; }

/* Info-Fenster in der Karte: fester Kopf, scrollbare Infos, Knöpfe unten */
.leaflet-popup-content { margin: 10px 12px; }
.map-info { display: flex; flex-direction: column; max-height: 260px; min-width: 210px; }
.map-info .mi-head { flex-shrink: 0; padding-bottom: .35rem; border-bottom: 1px solid #e3e3e3; }
.map-info .mi-head strong { display: block; font-size: 13px; line-height: 1.35; }
.map-info .mi-extra { font-size: 11px; text-transform: uppercase; letter-spacing: .06em; color: #b24c0d; margin-top: .1rem; }
.map-info .mi-area { font-weight: 600; margin-top: .2rem; }
.map-info .mi-body { flex: 1 1 auto; overflow-y: auto; max-height: 120px; padding: .35rem 0; font-size: 12px; line-height: 1.45; color: #333; }
.map-info .mi-body div { white-space: pre-wrap; }
.map-info .mi-foot { flex-shrink: 0; display: flex; flex-wrap: wrap; gap: .35rem; padding-top: .45rem; border-top: 1px solid #e3e3e3; }
.map-info .mi-foot .map-edit, .map-info .mi-foot .map-del, .map-info .mi-foot .map-only { margin: 0; display: inline-block; padding: .28rem .65rem; font-size: 12px; }
/* Neues Fenster für Karte oder Tabelle */
body.popout > *:not(.popout-target):not(.popout-bar):not(.modal-back):not(.tf-menu):not(script) { display: none !important; }
body.popout { background: var(--bg, #111); padding: 0; }
.popout-bar { position: sticky; top: 0; z-index: 10; display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: .55rem 1rem; background: #151515; border-bottom: 1px solid var(--orange); color: #fff; }
.popout-bar strong { font: 700 1rem/1.2 var(--font-display); text-transform: uppercase; letter-spacing: .04em; }
.map.popout-target { height: calc(100vh - 48px) !important; max-height: none !important; border-radius: 0 !important; margin: 0 !important; }
.table-wrap.popout-target { margin: 0; border-radius: 0; max-height: none; padding: .8rem; overflow: auto; }
.popout .fs-bar, .popout .fs-close { display: none !important; }
.data tfoot .sum-row td { font-weight: 700; color: #fff; border-top: 2px solid var(--orange); background: rgba(242, 107, 29, .06); }

/* =========================================================
   Flächenseite der Winzer (neu)
   ========================================================= */
.fm-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 1rem 1.5rem; flex-wrap: wrap; margin-bottom: 1rem; }
.fm-head h1 { margin: 0; display: flex; flex-wrap: wrap; align-items: center; gap: .75rem; }
.fm-head h1 .badge { font-size: .95rem; padding: .4rem .9rem; }
.fm-head .countdown { margin: 0; max-width: 330px; }
.chips-sum { display: flex; gap: .5rem; flex-wrap: wrap; margin-top: .6rem; }
.chips-sum span { padding: .3rem .75rem; border-radius: 999px; background: var(--field); border: 1px solid var(--line); font-size: .86rem; color: #ddd; }
.chips-sum b { color: #fff; }
.chips-sum .chip-bad { border-color: rgba(255, 106, 92, .5); color: #ffb4ab; }
.hint-row { display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: .75rem; margin: 0 0 1rem; }
.hint-row .notice { margin: 0; padding: .7rem .95rem; }
.hint-row .notice p { font-size: .86rem; line-height: 1.45; }
@media (max-width: 900px) { .hint-row { grid-template-columns: 1fr; } }
.actionbar { position: sticky; top: 0; z-index: 400; display: flex; gap: .6rem; align-items: center; flex-wrap: wrap; padding: .65rem .85rem; margin: 0 0 1rem;
  border-radius: 12px; background: rgba(20, 20, 20, .94); border: 1px solid var(--line-strong); backdrop-filter: blur(6px); box-shadow: 0 8px 24px rgba(0, 0, 0, .35); }
.actionbar .btn { padding: .55rem 1rem; }
.actionbar .btn.is-on { border-color: var(--orange); color: #fff; background: rgba(242, 107, 29, .15); }
.actionbar .grow { flex: 1; }
.jump { display: flex; gap: .4rem; }
.jump a { padding: .35rem .8rem; border-radius: 999px; border: 1px solid var(--line-strong); color: #ddd; font-size: .86rem; text-decoration: none; }
.jump a:hover { border-color: var(--orange); color: #fff; }
.fm-tip { font-size: .85rem; }
/* Eingabefenster */
.fm-modal { z-index: 6500; overflow-y: auto; align-items: start; padding-top: 4vh; }
.modal-big { width: min(1100px, 96vw); text-align: left; padding: 1.4rem 1.6rem 1.2rem; position: relative; }
.modal-big h2 { text-align: left; }
.modal-big p { white-space: normal; }
.modal-x { position: absolute; top: .6rem; right: .8rem; border: 0; background: none; color: #aaa; font-size: 1.8rem; line-height: 1; cursor: pointer; }
.modal-x:hover { color: #fff; }
/* Bearbeitungsmodus */
.edit-table td { background: rgba(242, 107, 29, .04); }
.edit-table input.n { width: 100%; min-width: 4.2rem; max-width: 7.5rem; padding: .35rem .45rem; font-size: .92rem; }
.edit-table .gem-cell { white-space: nowrap; }
.edit-table .gem-cell input { display: inline-block; width: 5rem; }
.edit-table .gem-cell small { display: block; color: var(--muted); font-size: .76rem; margin-top: .15rem; }
.edit-table tr.row-focus td { background: rgba(242, 107, 29, .16); box-shadow: inset 0 1px 0 var(--orange), inset 0 -1px 0 var(--orange); }
.edit-table tr.row-delete td { opacity: .5; text-decoration: line-through; }
.savebar { position: sticky; bottom: .6rem; z-index: 300; display: flex; gap: .6rem; flex-wrap: wrap; justify-content: flex-end; align-items: center; padding: .7rem 1rem; margin-top: .8rem;
  border-radius: 10px; background: #1b1b1b; border: 1px solid var(--orange); box-shadow: 0 8px 26px rgba(0, 0, 0, .55); }
.savebar .grow { flex: 1 1 260px; color: #ffcfb3; font-size: .88rem; }

/* Hinweis „Weiter unten: …“ auf allen Seiten */
.scroll-hint { position: fixed; left: 50%; bottom: 18px; transform: translateX(-50%); z-index: 450; padding: .55rem 1.1rem; border-radius: 999px; border: 0;
  background: linear-gradient(135deg, #f9a51a, #f26b1d); color: #111; font: 700 .9rem/1.2 var(--font); cursor: pointer;
  box-shadow: 0 8px 24px rgba(0, 0, 0, .5); transition: opacity .25s, transform .25s; animation: hintBob 2.4s ease-in-out infinite; }
.scroll-hint[hidden] { display: none !important; }
@keyframes hintBob { 50% { transform: translate(-50%, -4px); } }
@media print { .scroll-hint, .actionbar { display: none !important; } }

/* Tabellen: Suche + Vollbild in einer Leiste */
.tbl-tools { display: flex; gap: .5rem; align-items: center; flex-wrap: wrap; margin: 0 0 .45rem; }
.tbl-tools .tbl-search { flex: 0 1 280px; padding: .38rem .7rem; font-size: .88rem; }
.tbl-tools .grow { flex: 1; }
.tbl-tools .fs-btn { margin-left: 0; }
/* Anmeldeseite: Hinweis auf Registrierung */
.register-box { margin-top: 1.4rem; padding-top: 1.1rem; border-top: 1px solid var(--line); text-align: center; }
.register-box strong { display: block; font: 700 1.05rem/1.2 var(--font-display); text-transform: uppercase; letter-spacing: .04em; color: #fff; margin-bottom: .35rem; }
.register-box p { margin: 0 0 .8rem; font-size: .88rem; color: var(--muted); line-height: 1.45; }
.register-box .btn { width: 100%; justify-content: center; }
.register-line { margin: 1.2rem 0 0; padding-top: 1rem; border-top: 1px solid var(--line); text-align: center; color: var(--muted); }
.register-line a { font-weight: 700; }
.map-info .mi-foot .map-outline { background: #fff; color: #b24c0d !important; border: 1px solid #f26b1d; }
.plot-row-panel { margin-bottom: 1rem; }
.plot-row-panel .actions { margin-top: .6rem; }

/* Arbeitsliste Umrisse einzeichnen */
.queue-bar { display: flex; flex-wrap: wrap; gap: .75rem; align-items: center; justify-content: space-between;
  padding: .7rem 1rem; margin: 0 0 1rem; border: 1px solid var(--accent, #f26b1d); border-radius: 8px; background: rgba(242,107,29,.08); }
.queue-bar .row-actions { display: flex; gap: .75rem; align-items: center; }

/* Flurstücke in Klärung (Winzer-Ansicht) */
.chips-sum .chip-wait { border-color: rgba(240, 180, 60, .5); color: #f3cf86; }
.notice-wait { border-left-color: var(--warn); background: var(--warn-soft); margin: 0 0 1rem; }
.tag-wait { background: rgba(240, 180, 60, .14); color: #f3cf86; }
.tag-drawn, .tag-lea { background: var(--ok-soft); color: var(--ok); }
.tag-dup { display: inline-block; margin-top: .25rem; background: rgba(120, 160, 255, .14); color: #a9c1ff; text-decoration: none; }
.footer-version { opacity: .7; font-size: .8rem; }

/* Admin-Bereich: volle Bildschirmbreite (wegen der Tabellen), ohne Drohne im Hintergrund */
body.admin-full .page,
body.admin-full.wide .page,
body.admin-full.medium .page { max-width: none; margin-left: 0; margin-right: 0; padding-left: 2rem; padding-right: 2rem; }
body.admin-full .side-drone { display: none; }
@media (max-width: 640px) { body.admin-full .page { padding-left: 1rem; padding-right: 1rem; } }

/* Winzer: Flächenmeldung mit Tabelle und Karte auf voller Breite */
body.fm-page .page { max-width: none; padding-left: 2rem; padding-right: 2rem; }
@media (max-width: 640px) { body.fm-page .page { padding-left: 1rem; padding-right: 1rem; } }

/* Spalten ausblenden (Admin) */
.tf-colhide { display: none !important; }
.tf-cols-btn.is-active { border-color: var(--orange); color: var(--orange); }
.tf-cols-menu { width: 300px; }
.tf-cols-menu .tf-cols-title { display: block; margin: .1rem .2rem .5rem; font-size: .9rem; }
.tf-cols-menu .tf-list { max-height: 55vh; }
.tf-cols-note { margin: .5rem .2rem 0; font-size: .78rem; color: var(--muted); }
.tf-menu .tf-hidecol { border-top: 1px solid var(--line); margin-top: .2rem; padding-top: .45rem; }

/* Karten größer: Winzer etwas höher, Admin deutlich größer */
.map { height: max(560px, 62vh); }
body.admin-full .map { height: max(640px, 78vh); }
body.admin-full .map-editor { height: 80vh; }
@media (max-width: 640px) { .map, body.admin-full .map { height: 420px; } }

/* Kennzeichnung „Weinbau“ neben dem Schriftzug */
.brand-title { display: inline-flex; align-items: center; }
.brand-title .brand-tag {
  font-style: normal; font-size: .83em; letter-spacing: .12em; color: #111; margin-left: .9rem;
  background: linear-gradient(135deg, #f9a51a, #f26b1d); padding: .2em .55em .18em;
  clip-path: polygon(.3em 0, 100% 0, calc(100% - .3em) 100%, 0 100%);
  box-shadow: 0 0 18px rgba(242, 107, 29, .45);
}
@media (max-width: 640px) {
  .brand-title { flex-wrap: wrap; row-gap: .3rem; }
  .brand-title .brand-tag { margin-left: 0; font-size: .75em; }
}

/* =========================================================
   Kopf: Untertitel + Winzer-Menü (Entwurf 2) mit Betrieb-Menü
   ========================================================= */
.topbar { overflow: visible; z-index: 20; }
.brand-text { display: flex; flex-direction: column; gap: .4rem; }
.brand-text .brand-sub {
  border-left: 0; padding-left: 0; color: #f9a15a; font-size: .74rem; letter-spacing: .2em; font-weight: 600;
  font-family: var(--font-display); text-shadow: 0 1px 6px rgba(0, 0, 0, .9);
}
@media (max-width: 900px) { .brand-text .brand-sub { display: block; font-size: .6rem; letter-spacing: .12em; } }
@media (max-width: 480px) { .brand-text .brand-sub { display: none; } }

.nav-badge { display: inline-block; min-width: 1.2rem; padding: 0 .35rem; margin-left: .25rem; border-radius: 999px; background: var(--orange); color: #111; font-size: .72rem; font-weight: 800; text-align: center; line-height: 1.2rem; }

.nav.nav-winzer { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; overflow: visible; }
.nav-winzer .nav-main { display: flex; align-items: center; gap: 0 1.1rem; flex: 1 1 auto; min-width: 0; flex-wrap: wrap; }
.nav-winzer .nav-main a {
  background: none !important; box-shadow: none !important; border-radius: 0; color: #dcdcdc; padding: .5rem .1rem .45rem;
  border-bottom: 3px solid transparent; font-weight: 500;
}
.nav-winzer .nav-main a:hover { color: #fff; border-bottom-color: rgba(242, 107, 29, .45); }
.nav-winzer .nav-main a.active { color: #fff !important; border-bottom-color: var(--orange); font-weight: 650; }
.nav-winzer .nav-right { display: flex; align-items: center; gap: .6rem; margin-left: auto; }
.nav-winzer a.nav-help { border: 1px solid #3a3a3a; border-radius: 999px; padding: .45rem .9rem; color: #eee; background: rgba(20, 20, 20, .6); font-weight: 600; }
.nav-winzer a.nav-help.active { color: #111; }

.acct { position: relative; }
.acct > summary {
  list-style: none; cursor: pointer; display: inline-flex; align-items: center; gap: .5rem; white-space: nowrap;
  border: 1px solid var(--orange); border-radius: 999px; padding: .45rem .95rem; color: #fff; font-weight: 600; font-size: .92rem;
  background: rgba(20, 20, 20, .6); max-width: 18rem; overflow: hidden; text-overflow: ellipsis;
}
.acct > summary::-webkit-details-marker { display: none; }
.acct > summary b { color: var(--orange); transition: transform .15s; }
.acct[open] > summary b { transform: rotate(180deg); }
.acct.is-active > summary { background: rgba(242, 107, 29, .15); }
.acct > summary[data-alert]::after { content: ""; width: .5rem; height: .5rem; border-radius: 50%; background: var(--error); box-shadow: 0 0 0 3px rgba(255, 106, 92, .25); }
.acct-menu {
  position: absolute; right: 0; top: calc(100% + 8px); min-width: 230px; z-index: 60; padding: .4rem;
  background: #181818; border: 1px solid #3a3a3a; border-radius: 12px; box-shadow: 0 14px 34px rgba(0, 0, 0, .65);
}
.acct-menu a, .acct-menu .linkbtn {
  display: block; width: 100%; text-align: left; padding: .6rem .8rem !important; border-radius: 8px; color: #eee !important;
  background: none !important; font-weight: 500; text-decoration: none; font-size: .95rem; border: 0;
}
.acct-menu a:hover, .acct-menu .linkbtn:hover { background: var(--surface-3) !important; }
.acct-menu a.active { background: rgba(242, 107, 29, .15) !important; color: #fff !important; }
.acct-menu hr { border: 0; border-top: 1px solid #333; margin: .3rem 0; }
.acct-menu .logout { color: #ff8a7a !important; cursor: pointer; }
.acct-menu form { margin: 0; }

@media (max-width: 640px) {
  .nav.nav-winzer { overflow: visible; gap: .5rem; }
  .nav-winzer .nav-main { flex: 1 1 100%; flex-wrap: nowrap; overflow-x: auto; gap: 0 .9rem; }
  .nav-winzer .nav-right { margin-left: 0; width: 100%; justify-content: space-between; }
  .acct-menu { right: 0; }
}

/* =========================================================
   Zusatzleistungen
   ========================================================= */
.tabs { display: flex; gap: .5rem; margin: 0 0 1.2rem; border-bottom: 1px solid #2c2c2c; }
.tabs a { padding: .7rem 1.1rem; color: #bbb; text-decoration: none; font-weight: 600; border-bottom: 3px solid transparent; margin-bottom: -1px; }
.tabs a.on { color: #fff; border-bottom-color: var(--orange); }
.tabs .cnt { display: inline-block; margin-left: .35rem; background: var(--orange); color: #111; border-radius: 999px; font-size: .75rem; padding: 0 .45rem; }
.sec-h { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin: 1.4rem 0 .8rem; }
.sec-h h2 { margin: 0; }
.svc-grid { display: grid; gap: 1rem; }
.svc-grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.svc-grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .8rem; }
.svc { position: relative; display: flex; flex-direction: column; background: linear-gradient(180deg, #1d1d1d, #161616); border: 1px solid #2e2e2e; border-radius: 14px; padding: 1.15rem 1.15rem 1rem; }
.svc .svc-ic { font-size: 1.9rem; line-height: 1; }
.svc h3 { margin: .55rem 0 .3rem; font-size: 1.1rem; }
.svc p { margin: 0 0 .9rem; color: #b5b5b5; font-size: .92rem; flex: 1; }
.svc .btn { align-self: flex-start; }
.svc-drone { position: absolute; top: .9rem; right: .9rem; font: 700 .66rem var(--font-display); letter-spacing: .12em; text-transform: uppercase; color: #111; background: linear-gradient(135deg, #f9a51a, #f26b1d); padding: .2rem .5rem; border-radius: 4px; }
.svc-small { padding: .9rem 1rem; }
.svc-small h3 { font-size: 1rem; margin: .3rem 0 .2rem; }
.svc-small p { font-size: .85rem; margin-bottom: .6rem; }
.svc-acts { display: flex; align-items: center; gap: .9rem; flex-wrap: wrap; font-size: .88rem; }
.svc-more { margin-top: 1.4rem; }
.svc-more > summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 1rem; font-size: 1.05rem; }
.svc-more > summary::-webkit-details-marker { display: none; }
.svc-more-ic { color: var(--orange); font-size: 1.2rem; transition: transform .15s; }
.svc-more[open] .svc-more-ic { transform: rotate(180deg); }
.svc-more[open] > summary { margin-bottom: .6rem; }
@media (max-width: 1100px) { .svc-grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .svc-grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .svc-grid-4, .svc-grid-3 { grid-template-columns: 1fr; } }

.st { display: inline-block; font-weight: 700; font-size: .78rem; padding: .2rem .6rem; border-radius: 999px; white-space: nowrap; }
.st-new { background: rgba(120, 160, 255, .16); color: #a9c1ff; }
.st-offr { background: rgba(245, 185, 66, .18); color: #f3cf86; }
.st-ok { background: rgba(79, 209, 139, .15); color: #7fe0aa; }
.st-plan { background: rgba(242, 107, 29, .18); color: #ffb27a; }
.st-done { background: #2a2a2a; color: #bbb; }
.tag-newmsg { background: var(--orange); color: #111; font-weight: 700; }
tr.row-new td { background: rgba(242, 107, 29, .06); }

.req-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem 1.2rem; }
.req-grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.fld { display: flex; flex-direction: column; gap: .35rem; font-weight: 600; font-size: .92rem; }
.fld-wide { grid-column: 1 / -1; }
.fld small { font-weight: 400; color: var(--muted); font-size: .8rem; }
.fld .chips .chip { cursor: pointer; display: inline-flex; align-items: center; gap: .4rem; padding: .45rem .9rem; font-weight: 500; }
.fld .chips .chip:has(input:checked) { border-color: var(--orange); background: rgba(242, 107, 29, .15); color: #fff; }
.fld .chips .chip input { accent-color: var(--orange); margin: 0; }
@media (max-width: 900px) { .req-grid, .req-grid-2 { grid-template-columns: 1fr; } }
.split-2 { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 1rem; align-items: start; }
.split-2 > .panel, .split-2 > div > .panel:first-child { margin-top: 0; }
.req-split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: 1rem; align-items: start; }
@media (max-width: 1000px) { .split-2, .req-split { grid-template-columns: 1fr; } }
.take-box { border: 1px solid rgba(242, 107, 29, .35); background: rgba(242, 107, 29, .06); border-radius: 10px; padding: .7rem .9rem; margin-bottom: 1rem; }
.take-box > summary { cursor: pointer; }
.take-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: .3rem 1rem; margin: .7rem 0; max-height: 320px; overflow: auto; font-size: .9rem; }
.take-list label { display: flex; gap: .5rem; align-items: center; }
.take-list .take-all { grid-column: 1 / -1; font-weight: 600; }
.add-plot { margin-top: 1rem; padding: .9rem 1rem; border: 1px dashed #3a3a3a; border-radius: 10px; }
.add-plot h3 { margin: 0 0 .6rem; font-size: 1rem; }
.add-plot-row { display: flex; flex-wrap: wrap; gap: .6rem; align-items: flex-end; }
.add-plot-row label { display: flex; flex-direction: column; gap: .25rem; font-size: .82rem; color: var(--muted); }
.add-plot-row input:not([type=checkbox]) { width: 6.2rem; }
.add-plot-row .check-inline { flex-direction: row; padding-bottom: .55rem; color: var(--ink); }
.sumbar { display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; padding: .9rem 1.1rem; border-radius: 12px; background: #171717; border: 1px solid #2c2c2c; margin: 1rem 0; position: sticky; bottom: .5rem; z-index: 5; box-shadow: 0 8px 24px rgba(0, 0, 0, .5); }
.sumbar .grow { flex: 1; }
.sr-default { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.req-steps p { margin: 0 0 .5rem; }
.req-reply { margin-top: 1.2rem; border-top: 1px solid #2c2c2c; padding-top: 1rem; }
.req-reply h3 { margin: 0 0 .7rem; }
.req-reply .fld { margin-bottom: .8rem; }
.timeline { list-style: none; margin: 0; padding: 0 0 0 1.2rem; border-left: 2px solid #333; }
.timeline li { position: relative; margin: 0 0 1.1rem; padding-left: .9rem; }
.timeline li::before { content: ""; position: absolute; left: -1.62rem; top: .25rem; width: .9rem; height: .9rem; border-radius: 50%; background: #4fd18b; border: 2px solid #111; }
.timeline li.now::before { background: var(--orange); box-shadow: 0 0 10px var(--orange); }
.timeline li.tl-admin .box { border-color: rgba(242, 107, 29, .35); }
.timeline .when { color: #999; font-size: .8rem; }
.timeline .box { margin-top: .4rem; background: #171717; border: 1px solid #2c2c2c; border-radius: 10px; padding: .65rem .9rem; font-size: .92rem; overflow-wrap: anywhere; }
.timeline .box.attach a { font-weight: 600; }
.muted.small, p.small { font-size: .85rem; }

/* =========================================================
   Winzer-Ansicht für den Admin (Texte direkt bearbeiten)
   ========================================================= */
.preview-bar {
  position: sticky; top: 0; z-index: 100; display: flex; flex-wrap: wrap; gap: .6rem 1.2rem; align-items: center; justify-content: space-between;
  padding: .55rem 1.2rem; background: linear-gradient(90deg, #3a1d07, #2a1606); border-bottom: 2px solid var(--orange); color: #ffd7b8; font-size: .9rem;
}
.preview-bar .preview-acts { display: flex; gap: 1rem; align-items: center; }
.preview-bar .btn { padding: .35rem .8rem; font-size: .85rem; }
body.is-preview .te { outline: 1.5px dashed rgba(242, 107, 29, .75); outline-offset: 2px; border-radius: 3px; cursor: pointer; position: relative; }
body.is-preview .te:hover { outline-style: solid; background: rgba(242, 107, 29, .1); }
body.is-preview .te::after { content: "✎"; font-size: .75rem; margin-left: .3rem; color: var(--orange); font-weight: 700; }
body.is-preview .te.te-saved { outline-color: #4fd18b; }
.te-modal { position: fixed; inset: 0; z-index: 200; background: rgba(0, 0, 0, .65); display: flex; align-items: center; justify-content: center; padding: 1rem; }
.te-modal[hidden] { display: none; }
.te-box { width: min(760px, 100%); background: #171717; border: 1px solid #3a3a3a; border-radius: 14px; padding: 1.2rem 1.3rem; box-shadow: 0 20px 50px rgba(0, 0, 0, .7); }
.te-box h2 { margin: 0 0 .2rem; }
.te-box textarea { width: 100%; min-height: 9rem; }
.te-acts { display: flex; gap: .8rem; align-items: center; flex-wrap: wrap; }
.te-acts .linkbtn { margin-left: auto; }

/* =========================================================
   Erinnerung Flächenmeldung: Menü-Zeichen, Pop-up, Kasten unten rechts
   ========================================================= */
.nv-ok, .nv-warn { display: inline-grid; place-items: center; width: 1.05rem; height: 1.05rem; border-radius: 50%; font-size: .7rem; font-weight: 900; margin-left: .3rem; vertical-align: 1px; line-height: 1; }
.nv-ok { background: #2fb36b; color: #08140d; }
.nv-warn { background: #ff5a4a; color: #fff; animation: nvpulse 1.6s infinite; }
@keyframes nvpulse { 0% { box-shadow: 0 0 0 0 rgba(255, 90, 74, .6); } 70% { box-shadow: 0 0 0 8px rgba(255, 90, 74, 0); } 100% { box-shadow: 0 0 0 0 rgba(255, 90, 74, 0); } }
@media (prefers-reduced-motion: reduce) { .nv-warn { animation: none; } }

.fmr-overlay { position: fixed; inset: 0; z-index: 300; background: rgba(0, 0, 0, .68); display: flex; align-items: center; justify-content: center; padding: 1rem; backdrop-filter: blur(2px); }
.fmr-pop { position: relative; width: min(620px, 100%); max-height: 92vh; overflow: auto; background: linear-gradient(180deg, #1f1f1f, #151515); border: 1px solid #3a3a3a; border-top: 4px solid #ff5a4a; border-radius: 16px; padding: 1.6rem 1.8rem 1.4rem; box-shadow: 0 30px 70px rgba(0, 0, 0, .8); }
.fmr-pop.fmr-amber { border-top-color: #f5b942; }
.fmr-x { position: absolute; right: .9rem; top: .6rem; background: none; border: 0; color: #999; font-size: 1.6rem; cursor: pointer; }
.fmr-ico { width: 64px; height: 64px; border-radius: 50%; display: grid; place-items: center; font-size: 2rem; font-weight: 800; background: rgba(255, 90, 74, .15); color: #ff7a6b; margin-bottom: .8rem; }
.fmr-amber .fmr-ico { background: rgba(245, 185, 66, .15); color: #f5b942; }
.fmr-pop h2 { margin: 0 0 .4rem; font-size: 1.7rem; }
.fmr-text { color: #d2d2d2; font-size: 1rem; line-height: 1.5; margin-bottom: .9rem; }
.fmr-text p { margin: 0 0 .5rem; }
.fmr-steps { display: flex; gap: .5rem; margin: .2rem 0 1rem; }
.fmr-steps div { flex: 1; border: 1px solid #333; border-radius: 10px; padding: .55rem .7rem; font-size: .85rem; color: #aaa; background: #141414; }
.fmr-steps div b { display: block; color: #eee; }
.fmr-steps .ok { border-color: #2fb36b; }
.fmr-steps .ok b::before { content: "✓ "; color: #2fb36b; }
.fmr-steps .now { border-color: #ff5a4a; background: rgba(255, 90, 74, .08); }
.fmr-amber .fmr-steps .now { border-color: #f5b942; background: rgba(245, 185, 66, .08); }
.fmr-dl { background: #111; border: 1px solid #333; border-radius: 10px; padding: .7rem .9rem; margin: 0 0 1.1rem; font-size: .95rem; }
.fmr-dl b { color: #ff8a3d; font-size: 1.15rem; }
.fmr-acts { display: flex; gap: .8rem; align-items: center; flex-wrap: wrap; }
.fmr-later { margin-left: auto; color: #aaa !important; }
@media (max-width: 560px) { .fmr-steps { flex-direction: column; } .fmr-pop { padding: 1.2rem; } .fmr-pop h2 { font-size: 1.35rem; } }

.fmr-card { position: fixed; right: 22px; bottom: 22px; z-index: 250; width: 340px; background: #181818; border: 1px solid #3a3a3a; border-left: 5px solid #ff5a4a; border-radius: 14px; padding: 1rem 1.1rem; box-shadow: 0 18px 40px rgba(0, 0, 0, .7); }
.fmr-card.fmr-amber { border-left-color: #f5b942; }
.fmr-card h3 { margin: 0 1.4rem .35rem 0; font-size: 1.05rem; }
.fmr-card p { margin: 0 0 .75rem; color: #c8c8c8; font-size: .9rem; }
.fmr-card p b { color: #ff8a3d; }
.fmr-min { position: absolute; right: .55rem; top: .4rem; background: none; border: 0; color: #999; font-size: 1.3rem; cursor: pointer; line-height: 1; }
.fmr-pill { position: fixed; right: 22px; bottom: 22px; z-index: 250; border: 0; border-radius: 999px; padding: .6rem 1rem; font-weight: 700; cursor: pointer; background: #ff5a4a; color: #fff; box-shadow: 0 10px 24px rgba(0, 0, 0, .6); }
.fmr-pill.fmr-amber { background: #f5b942; color: #1a1200; }
.fmr-card[hidden], .fmr-pill[hidden] { display: none; }
@media (max-width: 640px) { .fmr-card { left: 12px; right: 12px; bottom: 12px; width: auto; } .fmr-pill { right: 12px; bottom: 12px; } }
.grp-pick { position: relative; flex: 1 1 220px; }
.grp-pick > summary { list-style: none; cursor: pointer; border: 1px solid var(--line); border-radius: 8px; padding: .45rem .6rem; background: var(--field, #0f0f0f); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.grp-pick > summary::-webkit-details-marker { display: none; }
.grp-pick-menu { position: absolute; z-index: 40; left: 0; top: calc(100% + 4px); min-width: 260px; max-height: 320px; overflow: auto; background: #181818; border: 1px solid #3a3a3a; border-radius: 10px; padding: .6rem .8rem; box-shadow: 0 14px 30px rgba(0, 0, 0, .6); }
.grp-pick-menu label { display: flex; gap: .5rem; align-items: center; padding: .25rem 0; font-weight: 500; }
.grp-pick-menu p { margin: 0 0 .4rem; }
.field > .grp-pick { flex: 0 0 auto; }

/* LEA-Referenzdaten */
.lea-upload { display: flex; flex-wrap: wrap; gap: .75rem; align-items: center; margin: .75rem 0 .25rem; }
.lea-upload input[type=file] { flex: 1 1 320px; padding: .6rem; border: 1px dashed var(--line, #ccc); border-radius: 10px; background: var(--card, #fff); }

/* ---------- Update 76: Admin-Menü in Gruppen ---------- */
.nav-admin { gap: .3rem; }
.ndd { position: relative; }
.ndd > summary {
  list-style: none; cursor: pointer; display: inline-flex; align-items: center; gap: .35rem; white-space: nowrap;
  padding: .5rem .9rem; border-radius: 999px; color: #eee; font-weight: 600; font-size: .95rem; text-shadow: 0 1px 6px rgba(0, 0, 0, .9);
}
.ndd > summary::-webkit-details-marker { display: none; }
.ndd > summary b { color: var(--orange); font-size: .8rem; transition: transform .15s; }
.ndd[open] > summary b { transform: rotate(180deg); }
.ndd > summary:hover { background: var(--surface-3); }
.ndd.is-active > summary { color: #111; background: linear-gradient(135deg, var(--amber), var(--orange)); text-shadow: none; }
.ndd.is-active > summary b { color: #111; }
.ndd-menu {
  position: absolute; left: 0; top: calc(100% + 8px); min-width: 270px; z-index: 80; padding: .4rem;
  background: #1a1a1a; border: 1px solid #3a3a3a; border-radius: 12px; box-shadow: 0 18px 40px rgba(0, 0, 0, .7);
}
.nav .ndd-menu a { display: flex !important; justify-content: space-between; align-items: center; gap: .8rem; padding: .6rem .8rem !important; border-radius: 8px; color: #eee !important; background: none !important; text-shadow: none; font-weight: 600; }
.nav .ndd-menu a small { display: block; color: #8a8a8a; font-weight: 400; font-size: .78rem; }
.nav .ndd-menu a:hover { background: var(--surface-3) !important; }
.nav .ndd-menu a.active { background: rgba(242, 107, 29, .16) !important; color: #fff !important; }
.nav-logout { margin-left: auto; }
@media (max-width: 640px) { .ndd-menu { position: fixed; left: 12px; right: 12px; top: auto; min-width: 0; } }

/* ---------- Nachrichten ---------- */
.chat { display: flex; flex-direction: column; gap: .9rem; margin: .4rem 0 1rem; }
.bub { max-width: min(78%, 760px); border-radius: 16px; padding: .9rem 1.1rem; line-height: 1.55; }
.bub .meta { font-size: .8rem; color: #9a9a9a; margin-bottom: .3rem; }
.bub.in { background: #1d1d1d; border: 1px solid #333; border-top-left-radius: 4px; align-self: flex-start; }
.bub.in .meta b { color: var(--orange-hi); }
.bub.out { background: rgba(242, 107, 29, .11); border: 1px solid rgba(242, 107, 29, .35); border-top-right-radius: 4px; align-self: flex-end; }
.msg-sys { align-self: center; max-width: 92%; background: #141b16; border: 1px solid #2c4a37; border-radius: 12px; padding: .7rem 1rem; font-size: .95rem; }
.msg-sys .meta { color: #8fbf9f; font-size: .78rem; margin-bottom: .2rem; }
.msg-sys.warn { background: #1b1712; border-color: #5a4520; }
.msg-sys.warn .meta { color: #d9b46a; }
.msg-plots { display: flex; flex-wrap: wrap; gap: .4rem; margin: .6rem 0 .1rem; }
.msg-plots span { background: #111; border: 1px solid #3a3a3a; border-radius: 8px; padding: .25rem .55rem; font-size: .86rem; }
.msg-plots span i { font-style: normal; color: var(--ok); margin-right: .3rem; }
.reply { display: flex; flex-direction: column; gap: .7rem; margin-top: 1rem; }
.reply textarea { width: 100%; min-height: 96px; background: var(--field); border: 1px solid var(--line-strong); border-radius: 12px; color: var(--ink); padding: .8rem .9rem; font: inherit; box-sizing: border-box; }
.reply-row { display: flex; flex-wrap: wrap; gap: .8rem 1.2rem; align-items: center; }
.tpl-chips { display: flex; flex-wrap: wrap; gap: .4rem; align-items: center; }
button.chip { cursor: pointer; color: var(--ink); border-style: dashed; }
button.chip:hover { border-color: var(--orange); }
.msg-layout, .rv-layout { display: grid; grid-template-columns: 340px minmax(0, 1fr); gap: 1.2rem; align-items: start; }
.msg-threads ul, .rv-queue ul { list-style: none; margin: 0; padding: 0; }
.msg-threads li a, .rv-queue li a { display: block; padding: .75rem .8rem; border-radius: 10px; color: var(--ink); text-decoration: none; border-left: 3px solid transparent; }
.rv-queue li a { display: flex; gap: .7rem; align-items: flex-start; }
.msg-threads li a:hover, .rv-queue li a:hover { background: var(--surface-3); }
.msg-threads li.on a, .rv-queue li.on a { background: rgba(242, 107, 29, .1); border-left-color: var(--orange); }
.msg-threads b, .rv-queue b { display: block; }
.msg-threads small, .rv-queue small { display: block; color: var(--muted); font-size: .82rem; }
.msg-threads .nav-badge { float: right; background: var(--error); color: #fff; }
.msg-main .chat { max-height: 62vh; overflow: auto; padding-right: .4rem; }
.msg-new { display: flex; gap: .5rem; align-items: center; }
.msg-new select { max-width: 340px; }
.msg-attach { margin: .2rem 0; }
.msg-attach summary { cursor: pointer; font-weight: 600; }
.chk-list { display: flex; flex-direction: column; gap: .35rem; max-height: 240px; overflow: auto; background: var(--field); border: 1px solid var(--line-strong); border-radius: 10px; padding: .7rem .9rem; margin: .4rem 0 .6rem; }
.chk-list label { display: flex; gap: .55rem; align-items: center; font-weight: 400; }
.chk-list input { width: 1.1rem; height: 1.1rem; margin: 0; flex: none; }
@media (max-width: 900px) { .msg-layout, .rv-layout { grid-template-columns: 1fr; } .bub { max-width: 92%; } }

/* ---------- To-do-Kasten Flächenmeldung ---------- */
.todo-card { display: flex; gap: 1rem; align-items: center; flex-wrap: wrap; padding: 1rem 1.2rem; margin: 0 0 1.2rem; border-radius: 14px;
  background: linear-gradient(90deg, rgba(245, 185, 66, .16), rgba(245, 185, 66, .03)); border: 1px solid rgba(245, 185, 66, .45); }
.todo-card .ic { font-size: 1.6rem; }
.todo-card > div { flex: 1 1 360px; }
.todo-card strong { display: block; font-size: 1.1rem; color: #fff; }
.todo-card span { color: #d9cbb3; }
.todo-acts { display: flex; gap: .6rem; flex-wrap: wrap; }
a.tf-cell { text-decoration: none; }

/* ---------- Teilfläche einzeichnen ---------- */
.tf-split { display: grid; grid-template-columns: 370px minmax(0, 1fr); gap: 1.2rem; align-items: start; }
.tf-side h2 { margin-bottom: .3rem; }
.tf-how-list { margin: .8rem 0; padding-left: 1.3rem; line-height: 1.7; }
.tf-hint { background: rgba(79, 209, 139, .09); border: 1px solid rgba(79, 209, 139, .38); border-radius: 10px; padding: .65rem .85rem; color: #c3ecd3; font-size: .93rem; margin: .6rem 0; }
.tf-compare { border-radius: 10px; padding: .6rem .85rem; font-size: .93rem; margin: .6rem 0; }
.tf-compare.ok { background: rgba(79, 209, 139, .09); border: 1px solid rgba(79, 209, 139, .38); color: #c3ecd3; }
.tf-compare.warn { background: var(--warn-soft); border: 1px solid rgba(245, 185, 66, .45); color: #f3dba6; }
.tf-side textarea { width: 100%; box-sizing: border-box; background: var(--field); border: 1px solid var(--line-strong); border-radius: 10px; color: var(--ink); padding: .6rem; font: inherit; margin-top: .25rem; }
.tf-acts { display: flex; flex-direction: column; gap: .6rem; margin-top: 1rem; }
.tfs-list-h { margin: 1.4rem 0 .5rem; font-size: 1rem; }
.tfs-list { list-style: none; margin: 0; padding: 0; }
.tfs-list li a { display: flex; justify-content: space-between; gap: .5rem; align-items: center; padding: .6rem .7rem; border: 1px solid #2f2f2f; border-radius: 10px; margin-bottom: .45rem; color: var(--ink); text-decoration: none; background: #161616; }
.tfs-list li.on a { border-color: var(--orange); background: rgba(242, 107, 29, .08); }
.tf-toolbar { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; margin-bottom: .6rem; }
.tf-area { margin-left: auto; color: var(--muted); }
.tf-area strong { color: #fff; font-size: 1.1rem; }
.tf-map { height: max(560px, calc(100vh - 290px)) !important; min-height: 460px; }
.tf-map-solo { height: calc(100vh - 330px) !important; }
.vx.vx-first { background: #ffd24a; border-color: #ffd24a; transform: scale(1.25); }
@media (max-width: 960px) { .tf-split { grid-template-columns: 1fr; } .tf-mapbox { order: -1; } .tf-map { height: 62vh !important; } }

/* Teilflächen-Pop-up */
.tf-pop { width: min(760px, 100%); border-top-color: var(--orange); }
#tf-pop { z-index: 450; }
.tf-prog { display: flex; gap: .35rem; margin: .3rem 0 .9rem; }
.tf-prog i { flex: 1; height: 7px; border-radius: 4px; background: #333; }
.tf-prog i.d { background: #2fb36b; }
.tf-prog i.c { background: var(--orange); }
.tf-how { display: grid; grid-template-columns: repeat(3, 1fr); gap: .7rem; margin: 1rem 0; }
.tf-how div { background: #121212; border: 1px solid #333; border-radius: 12px; padding: .8rem; font-size: .92rem; color: #bbb; }
.tf-how b { display: block; color: #fff; margin: .35rem 0 .2rem; }
.tf-how .n, .tfg-steps .n { display: inline-grid; place-items: center; width: 1.7rem; height: 1.7rem; border-radius: 50%; background: var(--orange); color: #111; font-weight: 900; flex: none; }
@media (max-width: 560px) { .tf-how { grid-template-columns: 1fr; } }

/* Anleitung Teilfläche */
.tfg-overlay { position: fixed; inset: 0; z-index: 400; background: rgba(0, 0, 0, .75); display: flex; align-items: flex-start; justify-content: center; padding: 3vh 1rem; overflow: auto; }
.tfg-overlay[hidden] { display: none; }
.tfg-box { position: relative; width: min(1200px, 100%); background: linear-gradient(180deg, #1f1f1f, #151515); border: 1px solid #3a3a3a; border-top: 4px solid var(--orange); border-radius: 16px; padding: 1.5rem 1.7rem; box-shadow: 0 30px 70px rgba(0, 0, 0, .8); }
.tfg-x { position: absolute; right: .9rem; top: .6rem; border: 0; background: none; color: #aaa; font-size: 1.7rem; cursor: pointer; }
.tfg-steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem; margin: 1rem 0; }
.tfg-steps > div { background: #141414; border: 1px solid #333; border-radius: 14px; padding: .8rem; }
.tfg-steps svg { width: 100%; display: block; border-radius: 10px; }
.tfg-steps b { display: flex; gap: .5rem; align-items: center; margin: .7rem 0 .3rem; font-size: 1.05rem; color: #fff; }
.tfg-steps p { margin: 0; color: #bbb; font-size: .93rem; line-height: 1.5; }
.tfg-precise { background: rgba(79, 209, 139, .09); border: 1px solid rgba(79, 209, 139, .38); border-radius: 10px; padding: .65rem .9rem; color: #c3ecd3; }
.tfg-dd { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.tfg-dd > div { border-radius: 14px; padding: .9rem 1.1rem; }
.tfg-dd .yes { background: rgba(79, 209, 139, .07); border: 1px solid rgba(79, 209, 139, .4); }
.tfg-dd .no { background: rgba(255, 106, 92, .07); border: 1px solid rgba(255, 106, 92, .35); }
.tfg-acts { margin-top: 1rem; }
@media (max-width: 900px) { .tfg-steps { grid-template-columns: 1fr 1fr; } .tfg-dd { grid-template-columns: 1fr; } }
@media (max-width: 520px) { .tfg-steps { grid-template-columns: 1fr; } }

/* ---------- Einverständniserklärung ---------- */
.sig-pad { position: relative; background: #fff; border: 2px dashed #999; border-radius: 12px; height: 190px; touch-action: none; }
.sig-pad canvas { width: 100%; height: 100%; display: block; border-radius: 10px; cursor: crosshair; touch-action: none; }
.sig-ph { position: absolute; left: 14px; bottom: 10px; color: #888; font-size: .85rem; pointer-events: none; }
.sig-pad .linkbtn { position: absolute; right: 12px; top: 8px; color: #555 !important; }
.consent-text { background: #f4f1ea; color: #222; border-radius: 12px; padding: .9rem 1.2rem; margin: 1rem 0; line-height: 1.55; }
.consent-text summary { cursor: pointer; color: #222; }
.consent-text h3, .consent-text h4 { color: #222; text-transform: none; letter-spacing: 0; margin: .9rem 0 .4rem; }
.consent-text .rt-h { display: block; margin-top: .8rem; color: #222; text-transform: uppercase; letter-spacing: .04em; }
.consent-text a { color: #a4430b; }
.consent-agree { margin: .2rem 0 1rem; }
.upload-big { padding: 1rem; border: 2px dashed var(--line-strong); border-radius: 12px; background: var(--field); width: 100%; box-sizing: border-box; }
.switch-row { display: flex; gap: .9rem; align-items: center; padding: .9rem 0; border-bottom: 1px solid var(--line); cursor: pointer; }
.switch-row input { appearance: none; width: 52px; height: 30px; border-radius: 999px; background: #444; position: relative; flex: none; cursor: pointer; transition: background .15s; margin: 0; }
.switch-row input::after { content: ""; position: absolute; left: 4px; top: 4px; width: 22px; height: 22px; border-radius: 50%; background: #fff; transition: left .15s; }
.switch-row input:checked { background: #2fb36b; }
.switch-row input:checked::after { left: 26px; }
.switch-row.is-locked { opacity: .75; cursor: default; }
.switch-row small { display: block; color: var(--muted); }
.consent-list { margin: .3rem 0 1rem; padding-left: 1.1rem; line-height: 1.9; }
.consent-upload { margin-top: 1rem; }
.consent-upload summary { cursor: pointer; font-weight: 600; }

/* ---------- Prüfen ---------- */
.rv-ic { font-size: 1.1rem; }
.rv-note { max-width: 100%; margin: .3rem 0 .8rem; }
.rv-doc { width: 100%; height: 72vh; border: 1px solid var(--line-strong); border-radius: 10px; background: #fff; object-fit: contain; }
img.rv-doc { height: auto; max-height: 80vh; }
.kv { display: grid; grid-template-columns: 140px 1fr; gap: .35rem 1rem; margin: .5rem 0 1rem; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; }
body.solo .topbar, body.solo .footer { display: none; }
body.solo .page { padding-top: 1rem; }

/* Update 76: Kopf über Karten und Kennzeichnung „Admin“ */
.topbar { z-index: 1100; }
.fmr-overlay { z-index: 2000; }
#tf-pop { z-index: 2050; }
.tfg-overlay { z-index: 2100; }
.brand-title .brand-tag.brand-tag-admin { margin-left: .45rem; background: linear-gradient(135deg, #f3f3f3, #cfcfcf); color: #111; box-shadow: 0 0 14px rgba(255, 255, 255, .18); }
@media (max-width: 640px) { .brand-title .brand-tag.brand-tag-admin { margin-left: .3rem; } }
.tfg-lead { color: #d0d0d0; line-height: 1.55; margin: .2rem 0 .8rem; }
.tfg-sub { margin: 1rem 0 .5rem; font-size: 1rem; text-transform: uppercase; letter-spacing: .04em; }
.tfg-acts { display: flex; flex-wrap: wrap; gap: 1rem 1.4rem; align-items: center; }
.tfg-mail { margin-left: auto; font-size: .92rem; }
.tf-email { margin-top: 1.1rem; border-top: 1px solid var(--line); padding-top: .8rem; }
.tf-email summary { cursor: pointer; font-weight: 600; color: var(--orange-hi); }
.rv-split { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.rv-pane-h { display: flex; justify-content: space-between; gap: 1rem; align-items: baseline; margin-bottom: .5rem; }
.rv-pane .tf-toolbar { min-height: 3.1rem; }
.rv-split .rv-pane:first-child .rv-pane-h { margin-bottom: calc(.5rem + 3.1rem + .6rem); }
.rv-map { height: max(520px, calc(100vh - 380px)) !important; }
@media (max-width: 1100px) { .rv-split { grid-template-columns: 1fr; } .rv-split .rv-pane:first-child .rv-pane-h { margin-bottom: .5rem; } }
/* Lücken zwischen Kartenkacheln dunkel statt hellgrau */
.map.leaflet-container { background: #1a1a1a; }
/* Winzer-Menü: aktiver Punkt ohne Breitenänderung (kein Springen der Knöpfe rechts) */
.nav-winzer .nav-main a.active { font-weight: inherit; text-shadow: .35px 0 0 #fff, -.35px 0 0 #fff; }
.nav-winzer .nav-main { gap: 0 1rem; }
.nav-winzer .nav-main a .nav-badge { position: absolute; margin: -.55rem 0 0 .15rem; min-width: 1.05rem; line-height: 1.05rem; font-size: .66rem; }
.nav-winzer .nav-main a { position: relative; }

/* ---------- Flächenmeldung: Aufgaben + Wichtig zu wissen ---------- */
.fmb-head { display: flex; align-items: center; gap: .8rem 1rem; flex-wrap: wrap; margin: .3rem 0 1.2rem; }
.fmb-head h1 { margin: 0; }
.fmb-head .badge { font-size: .9rem; padding: .4rem .9rem; }
.fmb-head .grow { flex: 1 1 auto; }
.fmb-head .countdown { max-width: none; flex-direction: row; display: flex; align-items: center; gap: .9rem; padding: .55rem .95rem; margin: 0; }
.fmb-head .countdown .countdown-hint { display: none; }
.fmb-head .countdown-time b { font-size: 1.45rem; }
.fmb-cta { padding: .85rem 1.3rem; }
.fmb-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(300px, 400px); gap: 1.3rem; align-items: start; margin-bottom: 1.3rem; }
.fmb-label { font: 600 .8rem/1 var(--font-display); text-transform: uppercase; letter-spacing: .12em; color: var(--muted); margin: 0 0 .6rem; }
.fmb-tasks { display: flex; flex-direction: column; gap: .55rem; }
.fmb-task { display: flex; align-items: center; gap: 1rem; padding: .85rem 1rem; border: 1px solid var(--line-strong); border-radius: 12px; background: var(--surface); }
.fmb-task .ic { width: 2.1rem; height: 2.1rem; border-radius: 50%; display: grid; place-items: center; font-weight: 900; flex: none; }
.fmb-task .grow { flex: 1; min-width: 0; }
.fmb-task b { display: block; color: #fff; font-size: 1.05rem; }
.fmb-task small { display: block; color: var(--muted); font-size: .9rem; margin-top: .1rem; }
.fmb-task .btn { flex: none; }
.fmb-task.is-ok .ic { background: rgba(79, 209, 139, .16); color: var(--ok); }
.fmb-task.is-ok b { color: #d8d8d8; }
.fmb-task.is-wait .ic { background: rgba(170, 170, 170, .14); color: #ccc; }
.fmb-task.is-open { border-color: rgba(245, 185, 66, .55); background: linear-gradient(90deg, rgba(245, 185, 66, .09), var(--surface) 60%); }
.fmb-task.is-open .ic { background: rgba(245, 185, 66, .18); color: #f5c96a; }
.fmb-task.is-red { border-color: rgba(255, 106, 92, .55); background: linear-gradient(90deg, rgba(255, 106, 92, .09), var(--surface) 60%); }
.fmb-task.is-red .ic { background: rgba(255, 106, 92, .18); color: #ff8a7d; }
.fmb-infos { display: flex; flex-direction: column; gap: .5rem; }
.fmb-info { border: 1px solid var(--line-strong); border-radius: 12px; background: var(--surface); }
.fmb-info summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; gap: .8rem; align-items: center; padding: .75rem 1rem; font-weight: 600; color: #eee; }
.fmb-info summary::-webkit-details-marker { display: none; }
.fmb-info summary b { color: var(--orange); font-size: .8rem; transition: transform .15s; }
.fmb-info[open] summary b { transform: rotate(180deg); }
.fmb-info-body { padding: 0 1rem .9rem; color: #c9c9c9; font-size: .93rem; line-height: 1.55; }
.fmb-info.is-important { border-color: rgba(242, 107, 29, .55); background: linear-gradient(180deg, rgba(242, 107, 29, .1), var(--surface)); }
@media (max-width: 980px) { .fmb-grid { grid-template-columns: 1fr; } .fmb-head .grow { display: none; } }
@media (max-width: 560px) { .fmb-task { flex-wrap: wrap; } .fmb-task .btn { width: 100%; } }

/* ---------- Dokumente auf der Spritzgemeinschaft ---------- */
.docs-box > summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: 1rem; }
.docs-box > summary::-webkit-details-marker { display: none; }
.docs-ic { font-size: 1.6rem; }
.docs-box summary strong { display: block; color: #fff; font-size: 1.1rem; }
.docs-box summary small { display: block; color: var(--muted); }
.docs-cnt { margin-left: auto; color: var(--orange-hi); white-space: nowrap; font-weight: 600; font-size: .92rem; }
.docs-box[open] > summary { margin-bottom: 1rem; }
.docs-box[open] .docs-cnt { opacity: .6; }

/* ---------- „Neu im Portal“ auf der Übersicht ---------- */
.news-box > summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: .7rem; }
.news-box > summary::-webkit-details-marker { display: none; }
.news-tag { background: linear-gradient(135deg, var(--amber), var(--orange)); color: #111; font-weight: 800; border-radius: 6px; padding: .15rem .5rem; font-size: .8rem; text-transform: uppercase; letter-spacing: .06em; }
.news-hide { margin-left: auto; color: var(--muted); font-size: .88rem; }
.news-box:not([open]) .news-hide::after { content: ""; }
.news-box:not([open]) .news-hide { font-size: 0; }
.news-box:not([open]) .news-hide::before { content: "anzeigen ▾"; font-size: .88rem; }
.news-body { margin-top: .7rem; color: #d0d0d0; }
.news-body ul { margin: 0; padding-left: 1.2rem; line-height: 1.8; }

/* ---------- Winzer-Menü in einer Zeile ---------- */
@media (min-width: 1101px) {
  .nav.nav-winzer { flex-wrap: nowrap; }
  .nav-winzer .nav-main { flex-wrap: nowrap; white-space: nowrap; }
  .nav-winzer .nav-right { flex: none; }
  .nav-winzer a.nav-help { padding: .4rem .8rem; }
}
@media (min-width: 1101px) and (max-width: 1360px) {
  .nav-winzer .nav-main { gap: 0 .75rem; font-size: .95rem; }
  .nav-winzer .nav-right { gap: .4rem; }
}

/* Admin: Teilflächen & Einverständnis – Sammelaktionen */
.tfu-show { margin-top: -.4rem; }
.tfu-bar { position: sticky; top: 0; z-index: 30; display: flex; flex-wrap: wrap; gap: .7rem 1.4rem; align-items: center; padding: .7rem 1rem; margin: 0 0 1rem;
  background: rgba(20, 20, 20, .96); border: 1px solid var(--line-strong); border-radius: 12px; backdrop-filter: blur(6px); }
.tfu-sel b { color: var(--orange-hi); font-size: 1.15rem; }
.tfu-group { display: inline-flex; gap: .45rem; align-items: center; }
.tfu-chk { width: 2.2rem; text-align: center; }
.tfu-chk input { width: 1.15rem; height: 1.15rem; }

/* Bilder in Nachrichten */
.mi-bar { display: flex; flex-wrap: wrap; gap: .5rem .9rem; align-items: center; }
.mi-btn { padding: .45rem .8rem; }
.mi-status { color: var(--orange-hi); }
.mi-prev { display: flex; flex-wrap: wrap; gap: .5rem; }
.mi-prev:empty { display: none; }
.mi-thumb { position: relative; display: inline-block; }
.mi-thumb img { height: 84px; max-width: 160px; object-fit: cover; border-radius: 8px; border: 1px solid var(--line-strong); display: block; }
.mi-thumb button { position: absolute; top: -8px; right: -8px; width: 22px; height: 22px; border-radius: 50%; border: 0; background: #e5484d; color: #fff; font-weight: 800; cursor: pointer; line-height: 1; }
textarea.mi-drop { outline: 2px dashed var(--orange); outline-offset: 2px; }
a.msg-img { display: block; margin: .5rem 0; }
a.msg-img img { max-width: min(100%, 520px); max-height: 420px; border-radius: 10px; border: 1px solid var(--line-strong); display: block; }
.consent-state { border-radius: 12px; padding: .9rem 1.1rem; margin: .8rem 0; }
.consent-state.is-ok { background: rgba(79, 209, 139, .09); border: 1px solid rgba(79, 209, 139, .4); color: #c3ecd3; }
.consent-state.is-missing { display: flex; flex-wrap: wrap; gap: .8rem 1.2rem; align-items: center; background: rgba(255, 106, 92, .08); border: 2px solid rgba(255, 106, 92, .55); }
.consent-state.is-missing > div { flex: 1 1 380px; }
.consent-state.is-missing strong { display: block; color: #ffb0a6; font-size: 1.08rem; margin-bottom: .2rem; }
.consent-state.is-missing span { color: #e6d0cc; }
.fx-search { width: 100%; max-width: 360px; margin: .3rem 0; }
.fx-list { max-height: 260px; }
.fx-list label.is-on { color: #fff; font-weight: 600; }
.sg-fixed { margin: .6rem 0; }
/* Handy: Kopfzeile nicht feststehend – sonst verdeckt sie bei geöffneter Tastatur das Eingabefeld */
@media (max-width: 900px) { .topbar { position: relative; } }
/* Handy/Tablet: Admin-Menü umbrechen, aufgeklappte Gruppe direkt darunter (kein Überlagern, nichts wird abgeschnitten) */
@media (max-width: 900px) {
  .nav.nav-admin { flex-wrap: wrap !important; overflow: visible !important; gap: .35rem; }
  .ndd[open] { flex: 1 1 100%; }
  .ndd[open] > summary { width: 100%; justify-content: space-between; box-sizing: border-box; }
  .ndd-menu, .ndd[open] .ndd-menu { position: static !important; left: auto; right: auto; top: auto; min-width: 0; margin-top: .35rem; box-shadow: none; }
  .nav .ndd-menu a { padding: .8rem .9rem !important; }
}

/* ---------- Abrechnung ---------- */
.small { font-size: .82rem; }
.back-link { margin: 0 0 .5rem; font-size: .9rem; }
.btn-ok { background: var(--ok); border-color: var(--ok); color: #08140d; }
.btn-ok:hover { filter: brightness(1.08); }
.badge-test { background: rgba(127, 178, 255, .16); color: #9cc3ff; }
.badge-overdue { background: var(--error); color: #fff; }
.inv-stats a, .inv-stats > div { background: var(--field); border: 1px solid var(--line); border-radius: 8px; padding: .7rem .8rem; color: inherit; text-decoration: none; }
.inv-stats a:hover { border-color: var(--orange); }
.inv-stats a.is-warn b { color: var(--error); }
.inv-create > summary { cursor: pointer; list-style: none; }
.inv-create > summary::-webkit-details-marker { display: none; }
.inv-create > summary h2 { display: inline; margin: 0; color: var(--orange-hi); }
.inv-create[open] > summary { margin-bottom: 1rem; }
.inv-create h3 { margin: 0 0 .4rem; }
.inv-create-form { background: rgba(255, 255, 255, .02); border: 1px solid var(--line); border-radius: var(--radius); padding: 1rem; }
.inv-create-form .hint { margin-bottom: 1rem; }
.bulk-bar { display: flex; gap: .8rem; align-items: center; flex-wrap: wrap; margin: 0 0 .8rem; }
.inv-table tbody tr[data-href] { cursor: pointer; }
.inv-addr { line-height: 1.5; margin: 0 0 .5rem; }
.inv-plots { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: .35rem 1rem; max-height: 320px; overflow: auto; }
.il-table td { vertical-align: top; }
.il-table textarea { min-width: 18rem; width: 100%; resize: vertical; }
.il-table input.num { width: 7.5rem; text-align: right; }
.il-table select { width: auto; }
.il-move button { display: block; background: none; border: 0; color: var(--muted); cursor: pointer; font-size: .7rem; padding: .1rem .2rem; }
.il-move button:hover { color: var(--orange-hi); }
.il-auto { margin-top: .35rem; font-size: .8rem; }
.il-mode + .il-qty { margin-top: .35rem; display: block; }
.il-sums { text-align: right; display: flex; justify-content: flex-end; gap: 1.5rem; flex-wrap: wrap; }
.il-sums b { color: var(--ink-strong); margin-left: .3rem; }
.il-sums .il-gross b { color: var(--amber); font-size: 1.1rem; }
.il-wrap { max-height: none; margin-bottom: .75rem; }
.sticky-actions { position: sticky; bottom: 0; z-index: 5; background: var(--bg, #111); padding: .8rem 0; border-top: 1px solid var(--line); }
table.kv { border-collapse: collapse; width: 100%; font-size: .92rem; }
.kv th { text-align: left; font-weight: 500; color: var(--muted); padding: .35rem 1rem .35rem 0; white-space: nowrap; vertical-align: top; width: 1%; }
.kv td { padding: .35rem 0; }
.inv-pay-row { display: flex; gap: .8rem; align-items: flex-end; flex-wrap: wrap; margin: 1rem 0 .4rem; }
.inv-pay-row label { display: flex; flex-direction: column; gap: .3rem; font-size: .85rem; color: #cfcfcf; }
.inv-pay-row input, .inv-pay-row select { width: auto; }
.inv-pay-row input[name="amount"] { width: 8rem; text-align: right; }
.inv-pay-row .grow { flex: 1 1 14rem; }
.inv-pay-row .grow input { width: 100%; }
.inv-log { list-style: none; margin: 0; padding: 0; font-size: .9rem; }
.inv-log li { padding: .3rem 0; border-bottom: 1px solid var(--line); }
.inv-plotlist { margin-top: .8rem; font-size: .9rem; }
.inv-plotlist ul { columns: 2; margin: .5rem 0 0; }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.chip.is-on { border-color: var(--orange); color: var(--orange-hi); }
a.chip { text-decoration: none; color: inherit; }
.pw-show code { font-size: 1.4rem; letter-spacing: .08em; background: #000; padding: .3rem .8rem; border-radius: 6px; user-select: all; }
.staff-name { display: flex !important; gap: .5rem; align-items: center; flex-wrap: wrap; margin-top: .35rem; }
.staff-name input { width: 14rem; padding: .3rem .5rem; font-size: .85rem; }
.staff-name select { width: auto; padding: .3rem .5rem; font-size: .85rem; }
@media (max-width: 900px) {
  .grid-4 { grid-template-columns: 1fr 1fr; }
  .il-table textarea { min-width: 12rem; }
}
.kv tr { display: grid; grid-template-columns: 10.5rem minmax(0, 1fr); gap: .8rem; border-bottom: 1px solid rgba(255,255,255,.04); }
.kv th { width: auto; }
.inv-cust { min-width: 14rem; }
.test-system-bar { background: repeating-linear-gradient(45deg, #7a1fa2, #7a1fa2 14px, #8e2cb8 14px, #8e2cb8 28px); color: #fff; text-align: center; font-weight: 700; padding: .45rem 1rem; letter-spacing: .03em; position: relative; z-index: 50; }
