/* Plantafel (plantafel.js) – Optik wie im Prototyp: Personen als Zeilen, Tage als Spalten, Farbe nach Art.
   Nutzt die Farben der Seite (--ink, --line, --muted, --red …). Alle Klassen mit Präfix pt-. */
.pt-seite, .pt-dlg, .pt-toast { --pt-grau: #ece8e2; --pt-gelb: #fdf1c4; --pt-gelb-ink: #6f5300; --pt-hover: #f3efeb; --pt-link: #c42a33; }
body.gerust[data-ansicht="g-plantafel"] main { max-width: none; }
.pt-seite { min-width: 0; max-width: 100%; }
.pt-nv { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; padding: 0; margin: -1px; }
.pt-seite :focus-visible, .pt-dlg :focus-visible, .pt-toast :focus-visible { outline: 3px solid var(--orange); outline-offset: 2px; }

/* Farben je Art (Hintergrund, Schrift, Rand) */
.pt-art-montage { --pt-bg: #efe3cf; --pt-ink: #5d4e33; --pt-rand: #b89668; }
.pt-art-kundendienst { --pt-bg: #fbdfe1; --pt-ink: #a8232b; --pt-rand: #e08a90; }
.pt-art-wartung { --pt-bg: #e3ecf5; --pt-ink: #2f5a85; --pt-rand: #8fb0d3; }
.pt-art-aufmass { --pt-bg: #fde7d3; --pt-ink: #8f4409; --pt-rand: #efb27c; }
.pt-art-buero { --pt-bg: #ece8e2; --pt-ink: #3b3b3b; --pt-rand: #bdb5aa; }
.pt-art-sonstiges { --pt-bg: #dcefe2; --pt-ink: #1f6a37; --pt-rand: #86c49a; }

/* Kopf und Werkzeuge */
.pt-kopf { display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: 10px 16px; margin-bottom: 12px; }
.pt-kopf .page-title { margin: 4px 0 6px; }
/* „Wird geladen …“ steht außerhalb des Textflusses: sonst wird der Titel kurz breiter und die Werkzeugleiste rutscht in die nächste Zeile und zurück */
.pt-status { font-size: 13px; color: var(--muted); margin-left: 6px; display: inline-block; width: 0; overflow: visible; white-space: nowrap; vertical-align: baseline; }
.pt-werkzeuge { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; min-width: 0; }
.pt-werkzeuge .btn.small { min-height: 36px; }
.pt-seg { display: inline-flex; border: 1px solid var(--line); border-radius: 10px; background: #fff; overflow: hidden; }
.pt-seg button { border: 0; background: none; padding: 7px 12px; font: inherit; font-size: 14px; font-weight: 600; color: var(--ink); cursor: pointer; min-height: 36px; }
.pt-seg button + button { border-left: 1px solid var(--line); }
.pt-seg button:hover { background: var(--pt-hover); }
.pt-seg button[aria-pressed="true"] { background: var(--ink); color: #fff; }
.pt-seg button:focus-visible { outline-offset: -3px; }
.pt-seg .pt-kurz { display: none; }
.pt-zeilenfirma { display: inline-flex; gap: 2px; vertical-align: 1px; }
.pt-tafel th.pt-name .pt-zeilenfirma { margin-left: 2px; }
.pt-pchip .pt-firma { vertical-align: 1px; margin-left: 2px; }
.pt-sprung input { padding: 6px 8px; border: 1px solid var(--line); border-radius: 10px; font: inherit; font-size: 14px; background: #fff; color: var(--ink); min-height: 36px; }

/* Meldungen */
.pt-meldung { display: flex; flex-wrap: wrap; gap: 8px 12px; align-items: center; background: var(--pt-gelb); color: var(--pt-gelb-ink); border-radius: 10px; padding: 10px 14px; margin: 0 0 12px; }
.pt-meldung > span { flex: 1 1 260px; }
.pt-meldung-fehler { background: #fbdfe1; color: #a8232b; }
.pt-laden { color: var(--muted); }

/* Karten: Noch nicht eingeplant, Fahrzeug-Abgleich */
.pt-karte { background: #fff; border: 1px solid var(--line); border-radius: var(--r, 12px); padding: 12px 14px; margin: 0 0 12px; min-width: 0; }
.pt-offen-kopf { display: flex; flex-wrap: wrap; gap: 4px 12px; align-items: baseline; margin-bottom: 8px; }
.pt-offen-kopf h2, .pt-fz-kopf h2 { font-size: 16px; margin: 0; }
.pt-anzahl { background: var(--red); color: #fff; border-radius: 9px; padding: 0 7px; font-size: 12px; vertical-align: 2px; }
.pt-offen-liste { display: flex; flex-wrap: wrap; gap: 8px; }
.pt-chip { border: 1px dashed var(--wood-dark, #b89668); background: #efe3cf; border-radius: 10px; padding: 7px 11px; text-align: left; cursor: pointer; display: grid; font: inherit; color: var(--ink); max-width: 100%; min-width: 0; }
.pt-chip[draggable="true"] { cursor: grab; }
.pt-chip b { font-size: 14px; overflow-wrap: anywhere; }
.pt-chip small { color: var(--brown, #6b5b3e); font-size: 12px; overflow-wrap: anywhere; }
.pt-chip[aria-pressed="true"] { border-style: solid; box-shadow: 0 0 0 2px var(--ink); }
.pt-chip-wartung { background: #e3ecf5; border-color: #7d9cc0; }
.pt-chip-wartung small { color: #2f5a85; }

/* Legende */
.pt-legende { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 12.5px; color: var(--muted); margin: 0 0 10px; align-items: center; }
.pt-legende i { display: inline-block; width: 12px; height: 12px; border-radius: 3px; margin-right: 5px; vertical-align: -1px; background: var(--pt-bg); border: 1px solid var(--pt-rand); }
.pt-legende i.pt-leg-abw { background: repeating-linear-gradient(45deg, #d9d1c6 0 3px, #fff 3px 6px); border-color: #cfc6ba; }
.pt-legende i.pt-leg-fei { background: var(--pt-gelb); border-color: #e9d38a; }
.pt-legende i.pt-leg-geist { background: #fff; border: 1px dashed #2f5a85; }

/* Tafel */
.pt-wrap { overflow-x: auto; background: #fff; border: 1px solid var(--line); border-radius: var(--r, 12px); max-width: 100%; margin-bottom: 14px; -webkit-overflow-scrolling: touch; }
.pt-wrap.pt-alt { opacity: .6; transition: opacity .2s; }
table.pt-tafel { border-collapse: separate; border-spacing: 0; width: 100%; table-layout: fixed; background: none; border-radius: 0; overflow: visible; box-shadow: none; }
table.pt-tafel.pt-woche { min-width: 860px; }
table.pt-tafel.pt-2wochen { min-width: 1120px; }
.pt-tafel th, .pt-tafel td { padding: 0; border-bottom: 1px solid var(--line); background: none; text-align: left; vertical-align: top; font-weight: inherit; color: inherit; font-size: inherit; }
.pt-tafel th.pt-ecke, .pt-tafel th.pt-name { position: sticky; left: 0; z-index: 2; background: #fff; width: 124px; padding: 8px 10px; border-right: 1px solid var(--line); font-weight: 700; overflow-wrap: anywhere; }
.pt-tafel th.pt-ecke { vertical-align: bottom; font-size: 12px; color: var(--muted); }
.pt-tafel th.pt-name.pt-frei { color: var(--brown, #6b5b3e); }
.pt-tafel tr.pt-weitere th.pt-name { color: var(--muted); font-weight: 600; }
.pt-tafel th.pt-kw { font-size: 12px; color: var(--muted); font-weight: 700; padding: 8px 6px 2px; border-left: 1px solid var(--line); border-bottom: 0; }
.pt-tafel th.pt-tag { font-weight: 600; font-size: 11.5px; color: var(--muted); padding: 2px 2px 6px; border-left: 1px solid var(--line); text-align: center; }
.pt-tafel th.pt-tag b { display: block; font-size: 14px; color: var(--ink); width: 26px; line-height: 22px; margin: 0 auto; border-radius: 7px; }
.pt-tafel th.pt-tag.pt-heute b { background: var(--red); color: #fff; }
.pt-tafel th.pt-tag em { display: block; font-style: normal; font-size: 10px; color: var(--pt-gelb-ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; padding: 0 2px; }
.pt-tafel td.pt-z { border-left: 1px solid var(--line); height: 74px; padding: 3px; }
.pt-tafel .pt-we { background: #f5f2ee; }
.pt-tafel .pt-fei { background: #fdf7dc; }
.pt-tafel td.pt-heute { background: #fffbea; }
.pt-tafel td.pt-z-abw { background-image: repeating-linear-gradient(45deg, rgba(0, 0, 0, .045) 0 6px, transparent 6px 12px); }
.pt-tafel tbody tr:last-child > * { border-bottom: 0; }
td.pt-ziel { cursor: copy; }
td.pt-ueber { background: var(--pt-gelb) !important; outline: 2px dashed var(--orange); outline-offset: -3px; }

/* Einsätze in der Tafel */
.pt-ev { background: var(--pt-bg); color: var(--pt-ink); border-radius: 6px; border-left: 3px solid var(--pt-rand); margin-bottom: 3px; min-width: 0; }
.pt-ev-knopf { display: block; width: 100%; border: 0; background: none; color: inherit; text-align: left; padding: 3px 5px; font: inherit; font-size: 11.5px; line-height: 1.25; cursor: pointer; border-radius: 6px; }
.pt-ev-knopf[draggable="true"] { cursor: grab; }
.pt-ev-knopf:hover { background: rgba(255, 255, 255, .35); }
.pt-ev-zeit { display: block; font-weight: 800; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pt-ev-titel .pt-firma { margin-right: 2px; vertical-align: 1px; }
.pt-ev-titel { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; font-weight: 600; overflow-wrap: anywhere; }
.pt-ev-klein { display: block; font-size: 10.5px; opacity: .85; }
.pt-firma { flex: none; font-size: 9.5px; font-weight: 800; letter-spacing: .03em; line-height: 14px; border-radius: 4px; padding: 0 3px; background: #fff; color: #6b5b3e; border: 1px solid #cdbb9c; }
.pt-firma-369 { background: #3a3b3d; color: #fff; border-color: #3a3b3d; }
.pt-ev-fz { font-size: 10.5px; line-height: 1.3; padding: 2px 5px 4px; border-top: 1px dashed var(--pt-rand); color: var(--ink); margin: 0; }
.pt-ev-fz-ab { color: #8f4409; font-weight: 700; }
.pt-mini { display: block; margin-top: 3px; border: 1px solid currentColor; background: #fff; color: inherit; border-radius: 6px; padding: 2px 6px; font: inherit; font-size: 10.5px; font-weight: 700; cursor: pointer; }
.pt-geist { background: #fff; border: 1px dashed var(--pt-rand); border-left-width: 1px; }
.pt-gewaehlt { box-shadow: 0 0 0 2px var(--ink); }
.pt-zieht { opacity: .45; }
.pt-abw { display: block; width: 100%; border: 1px solid #cfc6ba; background: repeating-linear-gradient(45deg, var(--pt-grau) 0 6px, #fff 6px 12px); color: #5f5952; border-radius: 6px; padding: 2px 5px; margin-bottom: 3px; font: inherit; font-size: 11px; font-weight: 700; text-align: left; cursor: pointer; }
span.pt-abw { cursor: default; }
.pt-plus { display: block; width: 100%; min-height: 22px; border: 1px dashed transparent; background: none; color: var(--muted); border-radius: 6px; font: inherit; font-size: 14px; line-height: 1; cursor: pointer; opacity: 0; }
td.pt-z:hover .pt-plus, .pt-plus:focus-visible { opacity: 1; border-color: var(--line); }
@media (hover: none) { .pt-plus { opacity: .5; } }
td.pt-ziel .pt-plus { opacity: 1; border-color: var(--orange); color: #8f4409; font-size: 12px; font-weight: 700; }
.pt-monat .pt-ev-titel { -webkit-line-clamp: 1; }
.pt-monat .pt-ev-knopf { font-size: 10.5px; padding: 2px 3px; }
.pt-monat .pt-ev-fz, .pt-monat .pt-ev-klein, .pt-monat .pt-firma, .pt-monat th.pt-tag em { display: none; }
.pt-monat td.pt-z { height: 60px; padding: 2px; }

/* Fahrzeug-Abgleich */
.pt-fz-kopf { display: flex; flex-wrap: wrap; gap: 6px 14px; align-items: center; justify-content: space-between; margin-bottom: 4px; }
.pt-fz h3 { font-size: 14px; margin: 14px 0 6px; }
.pt-fz p { margin: 4px 0; }
.pt-fz-liste { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.pt-fz-liste li { display: flex; flex-wrap: wrap; gap: 4px 12px; align-items: center; border: 1px solid var(--line); border-radius: 10px; padding: 8px 10px; }
.pt-fz-liste li > span { flex: 1 1 240px; min-width: 0; overflow-wrap: anywhere; }
.pt-schalter { display: inline-flex; gap: 6px; align-items: center; font-size: 14px; cursor: pointer; }
.pt-schalter input { width: 18px; height: 18px; }

/* Mein Tag / Meine Woche */
.pt-mein { display: grid; gap: 12px; max-width: 760px; }
.pt-mein-tag { background: #fff; border: 1px solid var(--line); border-radius: var(--r, 12px); padding: 12px 14px; min-width: 0; }
.pt-mein-tag.pt-heute { border-color: var(--ink); }
.pt-mein-tag h2 { font-size: 16px; margin: 0 0 8px; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.pt-marke { font-size: 11.5px; font-weight: 700; background: var(--red); color: #fff; border-radius: 9px; padding: 1px 8px; }
.pt-marke-fei { background: var(--pt-gelb); color: var(--pt-gelb-ink); }
.pt-mein-ev { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 10px; border-left: 4px solid var(--pt-rand); padding: 8px 0 8px 10px; margin-top: 8px; }
.pt-mein-zeit { font-weight: 800; font-size: 15px; }
.pt-mein-inhalt { display: grid; gap: 4px; min-width: 0; }
.pt-mein-inhalt small { color: var(--muted); }
.pt-mein-zeile { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.pt-pille { background: var(--pt-bg); color: var(--pt-ink); border-radius: 999px; padding: 1px 9px; font-size: 12px; font-weight: 700; }
.pt-mein-titel { font-size: 16px; overflow-wrap: anywhere; }
.pt-mein-adr { display: inline-flex; gap: 5px; align-items: flex-start; color: var(--pt-link); font-weight: 600; text-decoration: underline; text-underline-offset: 2px; overflow-wrap: anywhere; min-height: 24px; }
.pt-mein-adr svg { flex: none; margin-top: 3px; }
.pt-mein-notiz { margin: 2px 0 0; background: #f5f2ee; border-radius: 8px; padding: 6px 9px; white-space: pre-wrap; font-size: 14px; overflow-wrap: anywhere; }
.pt-mein-knoepfe { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 4px; }
.pt-mein-abw { background: repeating-linear-gradient(45deg, var(--pt-grau) 0 6px, #fff 6px 12px); border: 1px solid #cfc6ba; border-radius: 8px; padding: 6px 10px; font-weight: 700; color: #5f5952; margin: 0 0 6px; }
.pt-mein-frei { color: var(--muted); margin: 0; }

/* Fenster */
dialog.pt-dlg { width: min(560px, calc(100vw - 24px)); max-height: calc(100vh - 24px); max-height: calc(100dvh - 24px); padding: 0; overflow: hidden; color: var(--ink); }
dialog.pt-dlg.pt-dlg-breit { width: min(720px, calc(100vw - 24px)); }
dialog.pt-dlg-frage { width: min(460px, calc(100vw - 24px)); }
.pt-dlg-form { display: flex; flex-direction: column; max-height: calc(100vh - 24px); max-height: calc(100dvh - 24px); margin: 0; }
.pt-dlg .dk { flex: none; }
.pt-dlg-inhalt { flex: 1 1 auto; min-height: 0; overflow: auto; padding: 14px 16px; overscroll-behavior: contain; }
.pt-dlg-inhalt > p:first-child { margin-top: 0; }
.pt-dlg-fuss { flex: none; display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px; padding: 12px 16px; border-top: 1px solid var(--line); background: #faf8f5; }
.pt-dlg .pt-meldung { margin-bottom: 12px; }
.pt-feld { display: grid; gap: 4px; margin: 0 0 12px; border: 0; padding: 0; min-width: 0; }
.pt-feld > legend, .pt-lbl { font-size: 13px; font-weight: 700; color: var(--muted); padding: 0; margin: 0 0 4px; }
.pt-dlg input[type=text], .pt-dlg input[type=tel], .pt-dlg input[type=search], .pt-dlg input[type=date], .pt-dlg input[type=time], .pt-dlg select, .pt-dlg textarea { font: inherit; font-size: 15px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px; background: #fff; color: var(--ink); width: 100%; min-width: 0; box-sizing: border-box; min-height: 40px; margin: 0; }
.pt-dlg textarea { resize: vertical; }
.pt-dlg input:focus, .pt-dlg select:focus, .pt-dlg textarea:focus { border-color: var(--ink); }
.pt-dlg [aria-invalid="true"] { border-color: var(--bad) !important; box-shadow: 0 0 0 2px #fbdfe1; }
.pt-artwahl, .pt-wahlreihe, .pt-personen { display: flex; flex-wrap: wrap; gap: 6px; }
.pt-artchip, .pt-pchip { position: relative; cursor: pointer; }
.pt-artchip input, .pt-pchip input { position: absolute; opacity: 0; width: 1px; height: 1px; margin: 0; }
.pt-artchip span, .pt-pchip span { display: inline-block; border: 1px solid var(--line); border-radius: 999px; padding: 6px 12px; font-size: 14px; line-height: 20px; background: #fff; color: var(--ink); }
.pt-artchip input:checked + span { background: var(--pt-bg); color: var(--pt-ink); border-color: var(--pt-rand); box-shadow: inset 0 0 0 1px var(--pt-rand); font-weight: 700; }
.pt-pchip input:checked + span { background: var(--ink); color: #fff; border-color: var(--ink); }
.pt-artchip input:focus-visible + span, .pt-pchip input:focus-visible + span { outline: 3px solid var(--orange); outline-offset: 2px; }
.pt-abs { border: 1px solid var(--line); border-radius: 10px; padding: 10px; margin-bottom: 8px; display: grid; gap: 8px; min-width: 0; }
.pt-abs p { margin: 0; }
.pt-abs-zeit { display: flex; flex-wrap: wrap; gap: 8px; align-items: flex-end; }
.pt-abs-zeit label { display: grid; gap: 2px; font-size: 12.5px; color: var(--muted); font-weight: 600; flex: 1 1 110px; min-width: 0; }
.pt-abs-zeit label:first-child { flex-basis: 150px; }
.pt-x { border: 1px solid var(--line); background: #fff; border-radius: 8px; min-width: 34px; height: 34px; font: inherit; font-size: 16px; cursor: pointer; color: var(--muted); }
.pt-x:hover:not([disabled]) { color: var(--bad); border-color: var(--bad); }
.pt-x[disabled] { opacity: .35; cursor: default; }
.pt-x-platz { width: 34px; }
.pt-zwei { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 0 14px; }
.pt-adr { display: flex; gap: 8px; align-items: center; }
.pt-adr input { flex: 1; }
.pt-adr .btn { display: inline-flex; gap: 4px; align-items: center; }
.pt-vgsel { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; border: 1px solid var(--line); border-radius: 10px; padding: 8px 10px; background: #faf8f5; }
.pt-vgsel > div { flex: 1 1 200px; min-width: 0; display: grid; }
.pt-vgsel small { color: var(--muted); overflow-wrap: anywhere; }
.pt-vgtreffer { display: grid; gap: 2px; max-height: 260px; overflow: auto; }
.pt-vgtreffer p { margin: 4px 0; }
.pt-vgopt { display: grid; text-align: left; border: 0; background: none; border-radius: 8px; padding: 7px 10px; cursor: pointer; font: inherit; color: var(--ink); }
.pt-vgopt:hover, .pt-vgopt:focus-visible { background: var(--pt-hover); }
.pt-vgopt small { color: var(--muted); }
.pt-haken { display: flex; gap: 8px; align-items: flex-start; font-size: 14px; cursor: pointer; margin: 0 0 12px; }
.pt-haken input { width: 18px; height: 18px; margin: 2px 0 0; flex: none; }
.pt-warn { background: #fde7d3; color: #7a3a08; border: 1px solid #efb27c; border-radius: 10px; padding: 9px 12px; margin: 0 0 8px; }
.pt-hinw { background: #f5f2ee; color: #5f5952; border-radius: 10px; padding: 8px 12px; margin: 0 0 8px; font-size: 13.5px; }
.pt-knoepfe { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; justify-content: flex-end; margin-left: auto; }
.pt-knoepfe-links { display: flex; flex-wrap: wrap; gap: 8px; }
.pt-knoepfe-start { justify-content: flex-start; margin: 12px 0 0; }
.pt-frage-text { margin: 0; flex: 1 1 200px; }
.btn.pt-gefahr { background: var(--bad); }
.btn.sec.pt-gefahr-text { color: var(--bad); }
.pt-link { border: 0; background: none; color: var(--pt-link); font: inherit; font-size: 13.5px; text-decoration: underline; text-underline-offset: 2px; cursor: pointer; padding: 4px 0; text-align: left; }
.pt-dl { display: grid; grid-template-columns: 90px minmax(0, 1fr); gap: 8px 12px; margin: 0; }
.pt-dl dt { color: var(--muted); font-weight: 600; font-size: 13px; }
.pt-dl dd { margin: 0; overflow-wrap: anywhere; }
.pt-umbruch { white-space: pre-wrap; }
.pt-h3 { font-size: 15px; margin: 4px 0 6px; }
.pt-h3 ~ .pt-h3 { margin-top: 20px; }
.pt-zeilen { list-style: none; margin: 8px 0 10px; padding: 0; display: grid; gap: 4px; }
.pt-zeile { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; border: 1px solid var(--line); border-radius: 10px; padding: 6px 8px; }
.pt-zeile.pt-aus { opacity: .6; }
.pt-zeile-pfeile { display: flex; gap: 4px; }
.pt-zeile-name { flex: 1 1 140px; font-weight: 600; min-width: 0; }
.pt-dlg .pt-zeile input[type=text] { flex: 1 1 140px; width: auto; }
.pt-zeile .pt-haken { margin: 0; }
.pt-dlg .pt-zeile select { width: auto; min-height: 36px; padding: 5px 8px; font-size: 14px; }
.pt-dlg .pt-zeile input.pt-kurzfeld { flex: 0 1 90px; width: 90px; }
.pt-dlg .pt-zeile input.pt-telfeld { flex: 1 1 150px; width: auto; }
.pt-zeile-ma { background: #f7f7f8; }
.pt-teamquelle { display: block; font-weight: 400; font-size: 12px; color: var(--muted); }
.pt-teaminfo { border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; margin: 10px 0 8px; background: #faf8f5; }
.pt-teaminfo p { margin: 0 0 8px; }
.pt-teaminfo .pt-haken { margin: 0; }
.pt-abos { list-style: none; margin: 8px 0 0; padding: 0; display: grid; gap: 6px; }
.pt-abos li { display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: center; justify-content: space-between; border: 1px solid var(--line); border-radius: 10px; padding: 8px 10px; }
.pt-abos li > span:first-child { display: grid; min-width: 0; }
.pt-abos small { color: var(--muted); }
.pt-abos .pt-knoepfe { margin-left: 0; }
.pt-abolink { display: flex; gap: 8px; flex-wrap: wrap; }
.pt-dlg input.pt-linkfeld { flex: 1 1 100%; font-size: 13px; }
.pt-dlg .pt-abolink input { flex: 1 1 220px; width: auto; font-size: 13px; }
.pt-anleitung { border: 1px solid var(--line); border-radius: 10px; padding: 8px 12px; margin: 8px 0; }
.pt-anleitung summary { cursor: pointer; font-weight: 700; }
.pt-anleitung ol { margin: 8px 0 2px; padding-left: 20px; display: grid; gap: 4px; }

/* Meldung unten */
.pt-toast { position: fixed; left: 50%; bottom: calc(20px + env(safe-area-inset-bottom)); transform: translateX(-50%); z-index: 95; background: var(--ink); color: #fff; border-radius: 12px; box-shadow: 0 12px 30px rgba(0, 0, 0, .25);
  padding: 10px 10px 10px 16px; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; width: max-content; max-width: min(680px, calc(100vw - 24px)); font-size: 14px; }
.pt-toast > span { flex: 1 1 220px; }
.pt-toast button { border: 1px solid rgba(255, 255, 255, .55); background: none; color: #fff; border-radius: 8px; padding: 6px 10px; font: inherit; font-weight: 700; cursor: pointer; min-height: 34px; }
.pt-toast .pt-toast-zu { border: 0; font-size: 20px; padding: 0 8px; }

/* Handy */
@media (max-width: 860px) {
  .pt-toast { bottom: calc(80px + env(safe-area-inset-bottom)); }
}
@media (max-width: 700px) {
  .pt-kopf { margin-bottom: 8px; }
  .pt-seg .pt-lang { display: none; }
  .pt-seg .pt-kurz { display: inline; }
  .pt-seg-firma button { padding: 7px 10px; }
  .pt-werkzeuge { gap: 6px; }
  .pt-tafel th.pt-ecke, .pt-tafel th.pt-name { width: 92px; padding: 6px; font-size: 13px; }
  .pt-dlg-inhalt { padding: 12px; }
  .pt-dlg-fuss { padding: 10px 12px; }
  .pt-mein-ev { grid-template-columns: minmax(0, 1fr); gap: 4px; }
  .pt-dl { grid-template-columns: minmax(0, 1fr); gap: 2px; }
  .pt-dl dd { margin-bottom: 8px; }
}
@media print {
  .pt-werkzeuge, .pt-offen, .pt-fz, .pt-plus, .pt-legende, .pt-toast { display: none !important; }
  .pt-wrap { overflow: visible; border: 0; }
}
@media (prefers-reduced-motion: reduce) { .pt-wrap { transition: none; } }

/* Persönliche Ansicht (14.10.2026) */
.pt-ansicht { width: min(640px, 96vw); }
.pt-an-schnell { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0 12px; }
.pt-an-gruppe { border: 1px solid var(--line, #e3ded8); border-radius: 12px; margin: 0 0 10px; padding: 6px 12px 8px; }
.pt-an-gruppe legend { padding: 0 6px; }
.pt-an-zeile { display: flex; align-items: center; gap: 8px; padding: 6px 0; min-height: 36px; }

/* Geräte und Anhänger (HERO-Punkt 5) */
.pt-ev-res { color: #5a5148; }
.pt-res-doppelt .pt-ev-knopf { box-shadow: inset 0 0 0 2px #d12f39; }
.pt-res-doppelt .pt-ev-res { color: #a3201f; font-weight: 700; }
.pt-res .pt-wahlreihe { display: flex; flex-wrap: wrap; gap: 6px; }
#ptRes .pt-zeile input[type=text] { flex: 1 1 200px; min-width: 0; }
@media (max-width: 720px) { .pt-res .pt-pchip { min-height: 42px; display: inline-flex; align-items: center; } #ptRes .pt-zeile select, #ptRes .pt-zeile input[type=text] { font-size: 16px; min-height: 42px; } }
