/* ════════ Funktions- und Wissensseiten (0.36.0) ════════
   Aufbau: Brotkrumen, Kopf mit Kurzantwort und großer Abbildung, Eckdaten, Inhalt mit Inhaltsverzeichnis,
   Schritte, Fragen, verwandte Seiten. Farben der Belegarten (k-…) aus public.css: --c Farbe, --t Tönung. */
.tp-wrap { max-width: 1160px; margin: 0 auto; padding: 0 32px; }
.crumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: 4px 0; margin: 0; padding: 22px 0 0; font-size: 13.5px; color: var(--slate); }
.crumbs li + li::before { content: "›"; margin: 0 9px; color: #9fb0a7; }
.crumbs a { color: var(--slate); text-decoration: none; }
.crumbs a:hover { color: var(--green); text-decoration: underline; }
.crumbs [aria-current] { color: var(--ink); font-weight: 600; }

/* Kopf */
.tp-hero, .tp-hubhead { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.08fr); gap: 56px; align-items: center; padding: 26px 0 44px; }
.topic h1 { font-family: var(--display); font-weight: 600; font-size: clamp(36px, 4.6vw, 56px); line-height: 1; letter-spacing: 0; margin: 14px 0 22px; max-width: 17ch; color: var(--ink); text-wrap: balance; }
.topic-hub h1 { margin-top: 6px; }
.tp-group-link { display: inline-flex; align-items: center; gap: 10px; font-size: 14px; font-weight: 600; color: var(--c); text-decoration: none; }
.tp-group-link .bi { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 10px; background: var(--t); font-size: 17px; }
.tp-group-link:hover { text-decoration: underline; }
.tp-answer { background: var(--t); border-left: 5px solid var(--c); border-radius: 0 14px 14px 0; padding: 16px 20px 18px; }
.tp-answer h2 { font: 700 14px var(--sans); color: var(--c); margin: 0 0 6px; }
.tp-answer p { font-size: 17px; line-height: 1.6; margin: 0; color: var(--ink); }
.tp-hero .pub-cta { margin-top: 22px; }
.tp-hero .vis-art { box-shadow: 14px 14px 0 var(--t), 0 26px 50px -34px #13211c80; }
.topic-hub .lp-lead { font-size: 18px; color: var(--slate); max-width: 56ch; }
.tp-jump { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 24px; }
.tp-jump a { padding: 7px 14px; border-radius: 999px; border: 1px solid var(--line-strong); color: var(--ink); text-decoration: none; font-size: 14px; font-weight: 600; background: #fff; }
.tp-jump a:hover { border-color: var(--green); color: var(--green); }

/* Eckdaten */
.tp-facts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; margin: 0 0 18px; border: 1px solid var(--line); border-top: 5px solid var(--c); border-radius: 14px; background: #fff; overflow: hidden; }
.tp-facts > div { padding: 16px 20px; }
.tp-facts > div + div { border-left: 1px solid var(--line); }
.tp-facts dt { font-size: 13px; font-weight: 600; color: var(--slate); }
.tp-facts dd { margin: 4px 0 0; font-family: var(--display); font-size: 22px; font-weight: 600; line-height: 1.15; color: var(--c); }

/* Inhalt mit Inhaltsverzeichnis */
.tp-body { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 56px; padding: 30px 0 20px; }
.tp-toc nav { position: sticky; top: 20px; }
.tp-toc p { font-size: 13px; font-weight: 700; color: var(--slate); margin: 6px 0 10px; }
.tp-toc ol { list-style: none; margin: 0; padding: 0; border-left: 2px solid var(--line); }
.tp-toc a { display: block; padding: 6px 0 6px 14px; margin-left: -2px; border-left: 2px solid transparent; color: var(--slate); text-decoration: none; font-size: 14.5px; line-height: 1.35; }
.tp-toc a:hover { color: var(--ink); border-left-color: var(--green); }
.tp-article { max-width: 780px; min-width: 0; }
.tp-article > section { scroll-margin-top: 16px; }
.tp-article h2 { font-family: var(--display); font-weight: 600; font-size: clamp(28px, 3vw, 36px); line-height: 1.05; margin: 44px 0 14px; color: var(--ink); }
.tp-article > section:first-of-type h2, .tp-term + section h2 { margin-top: 6px; }
.tp-article p { font-size: 17px; line-height: 1.68; color: #26352f; margin: 0 0 14px; max-width: 70ch; }
.tp-term { background: var(--sheet); border-radius: 12px; padding: 14px 18px; font-size: 16px !important; margin-bottom: 30px !important; }
.tp-term dfn { font-style: normal; font-weight: 700; }
.tp-list { list-style: none; margin: 4px 0 18px; padding: 0; display: grid; gap: 8px; }
.tp-list li { position: relative; padding-left: 28px; font-size: 16.5px; line-height: 1.5; }
.tp-list li::before { content: ""; position: absolute; left: 4px; top: .5em; width: 10px; height: 10px; border-radius: 3px; background: var(--green); transform: rotate(45deg); }
.tp-numbered { counter-reset: n; }
.tp-numbered li { counter-increment: n; padding-left: 38px; }
.tp-numbered li::before { content: counter(n); top: .05em; left: 0; width: 26px; height: 26px; border-radius: 50%; transform: none; background: var(--c-quote); color: #fff; font: 700 13px/26px var(--sans); text-align: center; }
.tp-article .vis { margin: 26px 0 8px; }

/* Schritte: echte Reihenfolge, deshalb nummeriert */
.tp-steps { list-style: none; margin: 8px 0 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; counter-reset: s; }
.tp-steps li { counter-increment: s; position: relative; background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 18px 18px 16px 70px; scroll-margin-top: 16px; }
.tp-steps li::before { content: counter(s); position: absolute; left: 18px; top: 16px; width: 36px; height: 36px; border-radius: 50%; background: var(--c); color: #fff; font: 600 20px/36px var(--display); text-align: center; }
.tp-steps h3 { font-size: 16.5px; margin: 0 0 4px; }
.tp-steps p { font-size: 15px !important; line-height: 1.5 !important; color: var(--slate) !important; margin: 0 !important; }
.tp-article .faq { margin-top: 6px; }
.tp-article .faq summary h3 { font-size: 17px; }
.tp-article .faq p { font-size: 16px; }
.tp-sources { margin: 0; padding-left: 20px; color: var(--slate); font-size: 15px; }
.tp-stand { margin-top: 40px !important; padding-top: 14px; border-top: 1px solid var(--line); font-size: 14px !important; color: var(--slate) !important; }
.tp-pager { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin-top: 22px; }
.tp-pager a { display: flex; flex-direction: column; gap: 2px; padding: 14px 18px; border: 1px solid var(--line); border-radius: 12px; text-decoration: none; color: var(--ink); font-weight: 650; }
.tp-pager a small { color: var(--slate); font-weight: 500; font-size: 13px; }
.tp-pager .next { grid-column: 2; text-align: right; }
.tp-pager a:hover { border-color: var(--green); }

/* Karten der Übersichten und „Passend dazu“ */
.tp-group { padding: 34px 0 10px; scroll-margin-top: 10px; }
.tp-group h2 { font-family: var(--display); font-weight: 600; font-size: clamp(28px, 3vw, 38px); line-height: 1.05; margin: 0 0 18px; }
.tp-related { padding-bottom: 50px; }
.tp-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap: 14px; }
.tp-card { display: flex; gap: 14px; align-items: flex-start; padding: 18px; background: #fff; border: 1px solid var(--line); border-radius: 14px; text-decoration: none; color: var(--ink); transition: border-color .15s ease; }
.tp-card > .bi { flex: none; display: grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; background: var(--t); color: var(--c); font-size: 21px; }
.tp-card b { display: block; font-size: 16.5px; margin-bottom: 3px; }
.tp-card small { display: block; color: var(--slate); font-size: 14px; line-height: 1.45; }
.tp-card:hover { border-color: var(--c); }
.tp-card:hover b { color: var(--c); }
.tp-cta { margin-top: 10px; }

.tp-group-art { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 40px; align-items: start; padding-top: 44px; }
.tp-group-art.flip { grid-template-columns: minmax(0, 1fr) minmax(0, 1.5fr); }
.tp-group-art.flip .tp-group-vis { order: -1; }
.tp-group-art .tp-cards { grid-template-columns: repeat(auto-fill, minmax(min(100%, 250px), 1fr)); }
.tp-group-vis { padding-top: 52px; }
.tp-group-vis .vis-art { font-size: 13px; }
@media (max-width: 960px) { .tp-group-art, .tp-group-art.flip { grid-template-columns: minmax(0, 1fr); gap: 18px; } .tp-group-art.flip .tp-group-vis { order: 0; } .tp-group-vis { padding-top: 0; } }

/* ════════ Abbildungen ════════ */
.vis { margin: 0; container-type: inline-size; }
.vis-art { background: #fff; border: 1px solid var(--line); border-radius: 18px; padding: 22px; box-shadow: 0 24px 48px -34px #13211c80; overflow-x: auto; font-size: 14px; color: var(--ink); }
.vis figcaption { margin-top: 12px; font-size: 13.5px; line-height: 1.45; color: var(--slate); max-width: 64ch; }
.vis code, .vis pre { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
.v-code { margin: 0; background: #13211c; color: #d7e6dc; border-radius: 10px; padding: 14px 16px; font-size: 12.5px; line-height: 1.55; white-space: pre; overflow-x: auto; }
.v-doc { width: 34px; height: 40px; flex: none; }
.v-doc path { fill: #fff; stroke: var(--c); stroke-width: 2.5; stroke-linejoin: round; }
.v-doc .fold { fill: var(--c); }
.v-doc .ln { stroke-width: 3; stroke-linecap: round; fill: none; }
.v-badge { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 999px; font-size: 12.5px; font-weight: 650; background: var(--t, var(--green-tint)); color: var(--c, var(--green)); white-space: nowrap; }
.v-badge.bad { background: var(--red-tint); color: var(--red); }
.v-dot { display: inline-block; width: 10px; height: 10px; border-radius: 3px; background: var(--c); margin-right: 8px; vertical-align: 0; }
.v-dot.alt, .v-stack .alt { --c: #3fb4be; }
.v-y { color: var(--green); }
.v-ok { color: var(--green); font-weight: 650; }
.v-warn { color: var(--amber); font-weight: 650; }
.v-btn { display: inline-flex; align-items: center; gap: 8px; background: var(--green); color: #fff; border-radius: 999px; padding: 8px 16px; font-weight: 650; font-size: 13.5px; white-space: nowrap; }
.v-plain { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.v-plain th { text-align: left; font-size: 12px; font-weight: 650; color: var(--slate); padding: 6px 8px; border-bottom: 1.5px solid var(--ink); }
.v-plain td { padding: 7px 8px; border-bottom: 1px solid var(--line); }
.v-num td:not(:first-child), .v-num th:not(:first-child) { text-align: right; font-variant-numeric: tabular-nums; }
.v-scroll { overflow-x: auto; }

/* Fenster (Editor, E-Mail) */
.v-win { border: 1px solid var(--line-strong); border-radius: 12px; overflow: hidden; background: #fff; }
.v-bar { display: flex; align-items: center; gap: 6px; padding: 9px 12px; background: var(--sheet); border-bottom: 1px solid var(--line); }
.v-bar span { width: 10px; height: 10px; border-radius: 50%; background: #d3ddd6; }
.v-bar b { margin-left: 10px; font-size: 13px; }
.v-form { display: grid; grid-template-columns: 1.4fr 1fr; gap: 10px; padding: 14px 14px 4px; }
.v-form label { font-size: 11.5px; font-weight: 650; color: var(--slate); display: flex; flex-direction: column; gap: 4px; }
.v-input { border: 1px solid var(--line-strong); border-radius: 7px; padding: 6px 9px; font-size: 13px; font-weight: 500; color: var(--ink); background: #fff; }
.v-lines { width: calc(100% - 28px); margin: 10px 14px; border-collapse: collapse; font-size: 13px; }
.v-lines th { font-size: 11.5px; color: var(--slate); text-align: left; padding: 5px 6px; border-bottom: 1px solid var(--line-strong); }
.v-lines td { padding: 6px; border-bottom: 1px solid var(--line); }
.v-lines td:nth-child(n+2), .v-lines th:nth-child(n+2) { text-align: right; white-space: nowrap; }
.v-lines .v-head td { font-weight: 700; color: var(--c-invoice); text-align: left; }
.v-sums { display: flex; justify-content: space-between; align-items: flex-end; gap: 14px; padding: 4px 14px 14px; flex-wrap: wrap; }
.v-sums dl, .v-calc { display: grid; grid-template-columns: auto auto; gap: 3px 18px; margin: 0; font-size: 13px; }
.v-sums dl { margin-left: auto; order: 2; }
.v-sums dd, .v-calc dd { margin: 0; text-align: right; font-variant-numeric: tabular-nums; }
.v-total { font-weight: 750; font-size: 14.5px; padding-top: 5px; border-top: 1.5px solid var(--ink); }
.v-strong { font-weight: 700; }
.v-minus { color: var(--c-partial); }
.v-calc dt small { display: block; font-size: 11.5px; color: var(--slate); }

/* Papier */
.v-paper { background: #fff; border: 1px solid var(--line-strong); border-top: 6px solid var(--c); border-radius: 8px; padding: 16px 18px; }
.v-paper-head { display: flex; flex-direction: column; margin-bottom: 12px; }
.v-paper-head b { font-size: 15px; }
.v-paper-head span { font-size: 12.5px; color: var(--slate); }
.v-paper .v-calc { margin-top: 10px; grid-template-columns: 1fr auto; }

/* Zwei Dateien */
.vis-pair .vis-art { display: grid; grid-template-columns: minmax(0, 1fr) 64px minmax(0, 1.15fr); gap: 10px; align-items: center; }
.v-file { min-width: 0; }
.v-file-top { font-size: 12.5px; font-weight: 650; margin-bottom: 6px; display: flex; gap: 6px; align-items: center; }
.v-pdf .v-file-top { color: var(--c-dun); } .v-xml .v-file-top { color: var(--c-quote); }
.v-file small { display: block; margin-top: 8px; font-size: 12px; color: var(--slate); }
.v-sheet { position: relative; border: 1px solid var(--line-strong); border-radius: 8px; padding: 14px; display: flex; flex-direction: column; gap: 7px; background: #fff; min-height: 168px; }
.v-sheet b { font-size: 13px; }
.v-ln { height: 7px; border-radius: 4px; background: #e8eee9; }
.w80 { width: 80%; } .w60 { width: 60%; } .w70 { width: 70%; }
.v-amt { margin-top: auto; align-self: flex-end; font-weight: 750; font-size: 15px; }
.v-embed { position: absolute; left: -8px; bottom: -12px; background: var(--c-quote-t); color: var(--c-quote); border: 1px solid #b9cdf3; border-radius: 999px; padding: 3px 10px; font-size: 11.5px; font-weight: 650; }
.v-xml pre { margin: 0; background: #13211c; color: #b9e07a; border-radius: 8px; padding: 12px; font-size: 11.5px; line-height: 1.55; overflow-x: auto; min-height: 168px; }
.v-equal { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 4px; }
.v-equal span { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: var(--lime); color: #1d2600; font: 700 26px/1 var(--sans); }
.v-equal small { font-size: 11px; color: var(--slate); line-height: 1.25; }

/* Prüfung */
.vis-layers .layers li { grid-template-columns: 44px minmax(0, 1fr) auto; }
.vis-layers .layers-gate { margin-left: 0; }
.v-report { border: 1px solid var(--line-strong); border-radius: 12px; overflow: hidden; }
.v-report-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 12px 14px; background: var(--sheet); border-bottom: 1px solid var(--line); }
.v-report ul { list-style: none; margin: 0; padding: 0; }
.v-report li { display: grid; grid-template-columns: 20px 86px minmax(0, 1fr); gap: 10px; align-items: baseline; padding: 9px 14px; border-bottom: 1px solid var(--line); font-size: 13.5px; }
.v-report li.ok .bi { color: var(--green); } .v-report li.bad { background: var(--red-tint); } .v-report li.bad .bi { color: var(--red); }
.v-report code { font-size: 12px; font-weight: 700; background: none !important; padding: 0; }
.v-report em { display: block; font-style: normal; color: #7c211c; font-weight: 600; margin-top: 2px; }
.v-report-foot { padding: 10px 14px; font-size: 13px; font-weight: 650; color: var(--red); display: flex; gap: 8px; align-items: center; }

/* Angebot */
.v-quote { display: flex; gap: 14px; align-items: center; padding: 14px; border: 1px solid var(--line); border-radius: 12px; }
.v-quote b { display: block; font-size: 15px; } .v-quote span { display: block; font-size: 13px; color: var(--slate); }
.v-quote .v-valid { color: var(--c-delivery); font-weight: 650; margin-top: 2px; }
.v-track { list-style: none; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); margin: 22px 0 0; padding: 0; counter-reset: t; }
.v-track li { position: relative; text-align: center; font-size: 12.5px; font-weight: 650; padding-top: 30px; color: var(--slate); }
.v-track li::before { content: ""; position: absolute; top: 4px; left: 50%; transform: translateX(-50%); width: 18px; height: 18px; border-radius: 50%; background: #fff; border: 3px solid #c9d4cc; z-index: 1; }
.v-track li::after { content: ""; position: absolute; top: 12px; left: -50%; width: 100%; height: 3px; background: #c9d4cc; }
.v-track li:first-child::after { display: none; }
.v-track .done, .v-track .now { color: var(--ink); }
.v-track .done::before { background: var(--c-quote); border-color: var(--c-quote); }
.v-track .done::after, .v-track .now::after { background: var(--c-quote); }
.v-track .now::before { background: var(--lime); border-color: var(--c-pay); width: 24px; height: 24px; top: 1px; }
.v-branch { display: flex; justify-content: flex-end; gap: 14px; margin-top: 10px; font-size: 12.5px; color: var(--slate); }
.v-next { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.v-next span, .v-docs span { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: 999px; background: var(--t); color: var(--c); font-size: 13px; font-weight: 650; }

/* Belegkette (klein) */
.v-chain { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.v-chain li { position: relative; display: grid; grid-template-columns: 34px minmax(0, 1fr); column-gap: 10px; align-items: center; background: var(--t); border-radius: 12px; padding: 12px; border-left: 5px solid var(--c); }
.v-chain .v-doc { grid-row: span 2; }
.v-chain b { font-size: 14px; line-height: 1.2; }
.v-chain small { font: 600 11.5px ui-monospace, SFMono-Regular, Menlo, monospace; color: var(--c); }

/* Auftrag */
.v-panel { border: 1px solid var(--line-strong); border-radius: 12px; padding: 14px; }
.v-panel-head { display: flex; gap: 12px; align-items: center; margin-bottom: 12px; }
.v-panel-head > div { flex: 1; min-width: 0; }
.v-panel-head b { display: block; font-size: 15px; } .v-panel-head span:not(.v-badge):not(.v-avatar) { display: block; font-size: 12.5px; color: var(--slate); }
.v-progress { width: 100%; border-collapse: collapse; font-size: 13px; }
.v-progress th { text-align: left; font-size: 11.5px; color: var(--slate); padding: 5px 6px; border-bottom: 1px solid var(--line-strong); }
.v-progress td { padding: 8px 6px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.v-progress td:first-child { white-space: normal; }
.v-meter { display: inline-block; width: 64px; height: 8px; border-radius: 4px; background: #e8eee9; margin-right: 8px; vertical-align: 1px; position: relative; overflow: hidden; }
.v-meter::after { content: ""; position: absolute; inset: 0 auto 0 0; width: var(--p); background: var(--c); border-radius: 4px; }
.v-meter.k-delivery { --c: var(--c-delivery-f); }
.v-docs { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }

/* Lieferschein */
.v-noprice { display: flex; align-items: center; gap: 6px; font-size: 12.5px !important; color: var(--c-delivery) !important; font-weight: 650; margin: 10px 0 0 !important; }
.v-sign { display: flex; align-items: flex-end; gap: 12px; margin-top: 18px; font-size: 12.5px; }
.v-sigline { flex: 1; border-top: 1.5px solid var(--ink); padding-top: 4px; color: var(--slate); }

/* Abschläge */
.v-total-line { font-size: 14px !important; margin: 0 0 10px !important; }
.v-stack { display: flex; height: 58px; border-radius: 12px; overflow: hidden; gap: 2px; margin-bottom: 14px; }
.v-stack span { flex: 0 0 calc(var(--w) - 2px); background: var(--c); color: #fff; display: flex; flex-direction: column; justify-content: center; padding: 0 12px; font-size: 11.5px; min-width: 0; overflow: hidden; white-space: nowrap; }
.v-stack span.alt { background: #3fb4be; }
.v-stack b { font-size: 16px; }

/* Storno und Korrektur */
.v-split { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.v-col { background: var(--t); border-radius: 12px; padding: 14px; display: flex; flex-direction: column; align-items: stretch; }
.v-col h4 { font-size: 15px; font-weight: 700; color: var(--c); margin: 0 0 10px; display: flex; gap: 8px; align-items: center; }
.v-mini { display: flex; justify-content: space-between; gap: 8px; background: #fff; border: 1px solid var(--line-strong); border-radius: 8px; padding: 8px 10px; font-size: 13px; }
.v-mini.v-neg { border-color: var(--c); color: var(--c); font-weight: 650; }
.v-strike { text-decoration: line-through; color: var(--slate); }
.v-arrow { align-self: center; color: var(--c); font-size: 18px; margin: 4px 0; }
.v-col p { font-size: 13px !important; line-height: 1.45 !important; color: var(--ink) !important; margin: 10px 0 0 !important; }

/* Offene Posten */
.v-aging { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; align-items: end; padding: 26px 4px 0; }
.v-age-bar { border-bottom: 1.5px solid var(--ink); }
.v-age { display: flex; flex-direction: column; justify-content: flex-end; height: 100%; }
.v-age-bar { height: calc(var(--h) * 1.5px); min-height: 26px; border-radius: 4px 4px 0 0; background: var(--bar); position: relative; }
.v-age-bar b { position: absolute; top: -22px; left: 0; right: 0; text-align: center; font-size: 13px; }
.v-age.a0 { --bar: var(--c-pay); } .v-age.a1 { --bar: var(--c-delivery-f); } .v-age.a2 { --bar: #e07a3a; } .v-age.a3 { --bar: var(--c-dun); }
.v-age-lab { font-size: 12px; color: var(--slate); text-align: center; line-height: 1.25; min-height: 2.5em; padding-top: 6px; }
.v-legend { list-style: none; display: flex; flex-wrap: wrap; gap: 8px 18px; padding: 0; margin: 14px 0 0; font-size: 13px; }

/* Mahnstufen */
.v-ladder { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; align-items: end; }
.v-ladder li { display: flex; flex-direction: column; justify-content: flex-end; gap: 2px; padding: 12px; border-radius: 10px 10px 0 0; min-height: calc(92px + var(--i) * 34px); background: color-mix(in srgb, var(--c-dun) calc(16% + var(--i) * 24%), #fff); color: var(--ink); }
.v-ladder li:nth-child(n+3) { color: #fff; }
.v-ladder b { font-size: 14px; line-height: 1.2; overflow-wrap: anywhere; hyphens: auto; }
.v-ladder span { font-size: 12px; opacity: .85; }
.v-ladder em { font-style: normal; font-size: 12.5px; font-weight: 700; }
.v-formula { display: flex; gap: 8px; align-items: center; margin: 14px 0 0 !important; font-size: 13px !important; color: var(--slate) !important; }

/* Serie */
.v-series-head { display: flex; gap: 12px; align-items: center; margin-bottom: 16px; }
.v-series-head > .bi { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 12px; background: var(--c-quote-t); color: var(--c-quote); font-size: 20px; flex: none; }
.v-series-head b { display: block; } .v-series-head span { font-size: 12.5px; color: var(--slate); }
.v-months { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 4px; }
.v-months li { text-align: center; font-size: 11.5px; color: var(--slate); }
.v-months i { display: block; height: 36px; margin-top: 4px; border-radius: 6px; background: #eef2ef; border: 1.5px dashed #c9d4cc; }
.v-months .done i { background: var(--c-quote); border: 0; }
.v-months .next i { background: var(--lime); border: 2px solid var(--c-pay); }
.v-months .next { color: var(--ink); font-weight: 700; }
.v-next-run { display: flex; gap: 8px; align-items: center; margin: 14px 0 0 !important; font-size: 13.5px !important; }

/* Kunde */
.v-avatar { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 50%; background: var(--c-order); color: #fff; font-weight: 700; flex: none; }
.v-kv { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 6px 16px; margin: 0; font-size: 13.5px; }
.v-kv dt { color: var(--slate); font-weight: 600; } .v-kv dd { margin: 0; }
.v-kv code { font-size: 12.5px; }
.v-due { color: var(--c-dun); font-weight: 700; }
.v-tabs { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); }
.v-tabs span { padding: 5px 11px; border-radius: 999px; font-size: 12.5px; font-weight: 650; background: var(--sheet); color: var(--slate); }
.v-tabs .on { background: var(--c-order); color: #fff; }

/* Nummernkreise */
.v-ranges code { font-weight: 700; background: none !important; }
.v-no { font: 600 12.5px ui-monospace, SFMono-Regular, Menlo, monospace; color: var(--c); background: var(--t); border-radius: 6px; padding: 3px 7px; white-space: nowrap; }

/* Design */
.v-designs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.v-thumb { text-align: center; font-size: 13px; }
.v-thumb-page { aspect-ratio: 210 / 297; border: 1px solid var(--line-strong); border-radius: 6px; padding: 10% 9%; display: flex; flex-direction: column; gap: 6%; background: #fff; margin-bottom: 8px; box-shadow: 0 10px 20px -16px #13211c80; }
.v-thumb-page span { display: block; border-radius: 2px; background: #e3e9e5; }
.v-t-logo { width: 30%; height: 7%; background: var(--brand) !important; }
.v-t-title { width: 55%; height: 5%; background: #9aa9a1 !important; }
.v-t-head { height: 6%; background: #dfe6e1 !important; border-bottom: 2px solid var(--brand); }
.v-t-row { height: 4%; }
.v-t-sum { width: 40%; height: 6%; align-self: flex-end; background: var(--brand) !important; opacity: .85; margin-top: auto; }
.v-modern .v-t-head { background: var(--brand) !important; }
.v-modern .v-thumb-page { border-top: 8px solid var(--brand); }
.v-compact .v-thumb-page { gap: 3.5%; padding: 7%; }
.v-compact .v-t-logo { width: 20%; height: 5%; align-self: flex-end; }
.v-swatches { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.v-swatches span { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; }
.v-swatches .v-bad { outline: 2px solid var(--red); outline-offset: 2px; color: var(--red); font-size: 14px; }
.v-swatches small { font-size: 12.5px; color: var(--slate); margin-left: 6px; }

/* Export */
.v-targets { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.v-targets span { display: inline-flex; align-items: center; gap: 6px; padding: 7px 12px; border-radius: 10px; border: 1.5px solid var(--c); color: var(--c); font-weight: 650; font-size: 13.5px; background: #fff; }

/* E-Mail */
.v-mailf { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 6px 12px; margin: 0; padding: 14px 14px 0; font-size: 13px; }
.v-mailf dt { color: var(--slate); font-weight: 600; } .v-mailf dd { margin: 0; border-bottom: 1px solid var(--line); padding-bottom: 6px; overflow-wrap: anywhere; }
.v-mailtext { padding: 12px 14px 0; font-size: 13.5px !important; line-height: 1.55 !important; margin: 0 !important; color: var(--ink) !important; }
.v-attach { display: flex; flex-wrap: wrap; gap: 8px; padding: 12px 14px; }
.v-attach span { display: inline-flex; gap: 6px; align-items: center; padding: 6px 10px; border-radius: 8px; font-size: 12.5px; font-weight: 650; }
.v-attach .pdf { background: var(--c-dun-t); color: var(--c-dun); } .v-attach .xml { background: var(--c-quote-t); color: var(--c-quote); }
.v-mailfoot { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; padding: 10px 14px 14px; border-top: 1px solid var(--line); font-size: 13px; }

/* API */
.v-apigrid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.v-apigrid > div { min-width: 0; }
.v-apigrid code { font-weight: 650; background: none !important; }
.v-method, .v-status { display: inline-block; margin-bottom: 8px; padding: 3px 9px; border-radius: 6px; font: 700 12px ui-monospace, monospace; background: var(--c-quote); color: #fff; }
.v-status { background: var(--green); }

/* Hinweise */
.v-hint { display: flex; gap: 8px; align-items: flex-start; margin: 14px 0 0 !important; padding: 10px 12px; border-radius: 8px; background: var(--c-pay-t); color: #33520a !important; font-size: 13px !important; font-weight: 600; line-height: 1.45 !important; }

/* Lesen */
.vis-reader .v-reader { display: grid; grid-template-columns: minmax(0, 1fr) 30px minmax(0, 1.2fr); gap: 10px; align-items: center; }
.v-turn { font-size: 26px; color: var(--c-pay); text-align: center; }
.v-verdict { display: flex; gap: 14px; flex-wrap: wrap; margin: 12px 0 0 !important; font-size: 13px !important; }

/* Pflicht-Zeitstrahl */
.v-years, .v-lanes { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.v-years span { font-family: var(--display); font-size: 24px; font-weight: 600; padding: 0 0 8px 8px; border-left: 2px solid var(--line-strong); }
.v-lanes { row-gap: 8px; }
.v-lane { grid-column: var(--from) / var(--to); background: var(--c); color: #fff; border-radius: 10px; padding: 10px 12px; min-width: 0; }
.v-lane.soft { background: var(--t); color: var(--ink); border: 1.5px dashed var(--c); }
.v-lane b { display: block; font-size: 14px; } .v-lane span { font-size: 12.5px; opacity: .92; }

/* Vergleich und Profile */
.v-compare th[scope="row"] { font-weight: 650; color: var(--slate); border-bottom: 1px solid var(--line); font-size: 13px; white-space: nowrap; }
.v-compare thead th { font-size: 14px; color: var(--ink); }
.v-compare thead th:nth-child(2) .bi { color: var(--c-quote); } .v-compare thead th:nth-child(3) .bi { color: var(--c-dun); }
.v-profiles { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.v-profiles li { display: grid; grid-template-columns: 104px minmax(0, 1fr); align-items: center; gap: 12px; }
.v-profiles b { font-size: 13px; }
.v-profiles span { display: block; width: calc(var(--n) * 20%); min-width: max-content; padding: 7px 12px; border-radius: 8px; font-size: 12.5px; font-weight: 650; }
.v-profiles .no span { background: #eef2ef; border: 1.5px dashed #b8c6bd; color: var(--slate); }
.v-profiles .ok span { background: var(--c-invoice); color: #fff; }
/* Pflichtangaben */
.v-annot { font-size: 12.5px; line-height: 1.55; }
.v-row2 { display: flex; justify-content: space-between; gap: 14px; flex-wrap: wrap; }
.v-right { text-align: right; }
.v-to { margin: 12px 0; }
.v-annot .v-n { display: inline-grid; place-items: center; width: 19px; height: 19px; border-radius: 50%; background: var(--c-quote); color: #fff; font: 700 11px var(--sans); margin-right: 6px; vertical-align: 1px; }
.v-annot .v-calc { grid-template-columns: 1fr auto; }

/* Leitweg-ID */
.v-lid { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 6px; justify-content: center; }
.v-lid > span { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.v-lid b { font: 700 clamp(17px, 2.4vw, 24px) ui-monospace, SFMono-Regular, Menlo, monospace; padding: 8px 12px; border-radius: 10px; background: var(--t); color: var(--c); border: 2px solid var(--c); }
.v-lid small { font-size: 12px; font-weight: 650; color: var(--c); }
.v-lid > i { font: 700 24px ui-monospace, monospace; font-style: normal; padding-top: 8px; color: var(--slate); }
.v-lid-to { text-align: center; font-size: 13px !important; color: var(--slate) !important; margin: 14px 0 8px !important; }

/* Weitere Abbildungen */
.v-calc dt, .v-kv dt, .v-mailf dt { font-weight: 400; }
.v-calc dt.v-total, .v-calc dt.v-strong { font-weight: 700; }
.v-kv dt, .v-mailf dt { font-weight: 600; }
.v-small { font-size: 12.5px !important; color: var(--slate) !important; line-height: 1.45 !important; margin: 10px 0 0 !important; }
.v-pad { padding: 0 14px 14px; }
.v-life { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; }
.v-life li { position: relative; background: var(--t); border-top: 5px solid var(--c); border-radius: 10px; padding: 12px 10px; display: flex; flex-direction: column; gap: 4px; }
.v-life .bi { font-size: 20px; color: var(--c); }
.v-life b { font-size: 14px; } .v-life span { font-size: 12px; color: var(--slate); line-height: 1.35; }
.v-life li.k-quote { border-style: dashed solid solid; }
.v-reason { margin: 12px 0 0 !important; font-size: 13px !important; line-height: 1.45 !important; background: var(--c-dun-t); border-radius: 8px; padding: 8px 10px; color: var(--ink) !important; }
.v-ledger { list-style: none; margin: 0; padding: 0; font-size: 13px; }
.v-ledger li { display: grid; grid-template-columns: 52px minmax(0, 1fr) auto; gap: 10px; padding: 8px 2px; border-bottom: 1px solid var(--line); }
.v-ledger time { color: var(--slate); font-variant-numeric: tabular-nums; }
.v-ledger b { font-variant-numeric: tabular-nums; color: var(--c-pay); }
.v-ledger li.rev { color: var(--slate); } .v-ledger li.rev b { color: var(--slate); text-decoration: line-through; text-decoration-color: #b8c6bd; }
.v-meter-big { height: 10px; border-radius: 5px; background: #e8eee9; margin-top: 12px; overflow: hidden; }
.v-meter-big span { display: block; height: 100%; width: var(--p); background: var(--c-pay); }
.v-letter { font-size: 13px !important; line-height: 1.5 !important; color: var(--slate) !important; margin: 0 0 6px !important; font-style: italic; }
.v-clients { list-style: none; margin: 0; padding: 6px 14px; }
.v-clients li { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.v-clients li > div { flex: 1; min-width: 0; }
.v-clients b { display: block; font-size: 14px; } .v-clients small { color: var(--slate); font-size: 12.5px; }
.v-clients .v-btn { padding: 6px 12px; font-size: 12.5px; }
.v-who { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.v-who > div { display: grid; grid-template-columns: 36px minmax(0, 1fr); column-gap: 10px; align-items: start; padding: 14px; border-radius: 12px; background: var(--c); color: #fff; }
.v-who > div.soft { background: var(--t); color: var(--ink); border: 1.5px dashed var(--c); }
.v-who .bi { grid-row: span 2; font-size: 24px; } .v-who b { font-size: 14px; line-height: 1.3; } .v-who span { font-size: 12.5px; opacity: .92; }
.v-form3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.v-seg { display: flex; margin: 12px 14px 0; border: 1px solid var(--line-strong); border-radius: 999px; overflow: hidden; font-size: 12.5px; font-weight: 650; }
.v-seg span { flex: 1; text-align: center; padding: 7px 6px; color: var(--slate); }
.v-seg .on { background: var(--c-quote); color: #fff; }
.v-numline { list-style: none; margin: 0 0 6px; padding: 0; display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 6px; }
.v-numline li span { display: block; text-align: center; padding: 14px 4px; border-radius: 8px; font: 600 13px ui-monospace, SFMono-Regular, Menlo, monospace; border: 1.5px dashed var(--line-strong); color: var(--slate); }
.v-numline .used span { background: var(--c-invoice); border: 0; color: #fff; }
.v-numline .next span { background: var(--lime); border: 2px solid var(--c-pay); color: #1d2600; }
.v-numline .start span { border-color: var(--c-invoice); color: var(--c-invoice); }
.v-numline li:nth-child(5) { position: relative; }
.v-numline li:nth-child(5)::after { content: "…"; position: absolute; right: -6px; top: 12px; color: var(--slate); }
.vis-nextnumber .v-legend { margin-top: 14px; }
.v-rules { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.v-rules li { display: grid; grid-template-columns: 170px minmax(0, 1fr); gap: 12px; align-items: center; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; }
.v-rules p { margin: 0 !important; font-size: 13.5px !important; line-height: 1.4 !important; color: var(--ink) !important; }
.v-if { justify-self: start; font-size: 12px; font-weight: 700; color: var(--c-order); background: var(--c-order-t); border-radius: 6px; padding: 4px 8px; }
.v-if::before { content: "wenn "; font-weight: 500; }
.v-seq { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.v-seq li { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; font: 600 13px ui-monospace, SFMono-Regular, Menlo, monospace; }
.v-seq .v-method { margin: 0; }
.v-seq code { font-size: 12px; background: var(--sheet) !important; padding: 2px 6px; border-radius: 5px; }
.v-seq em { font: 650 12.5px var(--sans); font-style: normal; margin-left: auto; }


@media (max-width: 960px) {
  .tp-hero, .tp-hubhead { grid-template-columns: minmax(0, 1fr); gap: 34px; }
  .tp-body { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  .tp-toc nav { position: static; }
  .tp-toc ol { display: flex; flex-wrap: wrap; gap: 6px; border: 0; }
  .tp-toc a { border: 1px solid var(--line-strong); border-radius: 999px; padding: 5px 12px; margin: 0; font-size: 13.5px; }
  .tp-facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tp-facts > div:nth-child(3) { border-left: 0; }
  .tp-facts > div:nth-child(n+3) { border-top: 1px solid var(--line); }
}
@media (max-width: 640px) {
  .tp-wrap { padding: 0 18px; }
  .tp-steps, .tp-pager { grid-template-columns: minmax(0, 1fr); }
  .tp-pager .next { grid-column: auto; }
  .vis-art { padding: 14px; border-radius: 14px; }
  .tp-hero .vis-art { box-shadow: 8px 8px 0 var(--t); }
}
/* Feinschliff nach Sichtprüfung */
.v-apigrid { grid-template-columns: minmax(0, 1fr); }
.v-chain { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
.v-chain small, .v-chain b { overflow-wrap: anywhere; hyphens: auto; }
.vis-roles .roles-matrix th, .vis-roles .roles-matrix td { padding: 9px 7px; font-size: 13px; }
.vis-roles .roles-matrix thead th { font-size: 12px; }
.v-reader .v-code, .vis-leitweg .v-code { white-space: pre-wrap; word-break: break-all; font-size: 11.5px; }
.vis-reader .v-reader { grid-template-columns: minmax(0, .85fr) 28px minmax(0, 1.15fr); }
/* Abbildungen passen sich der eigenen Breite an (Kopf, Spalte, Übersicht, Handy) */
@container (max-width: 560px) {
  .vis-pair .vis-art, .vis-reader .v-reader { grid-template-columns: minmax(0, 1fr); }
  .v-equal { flex-direction: row; justify-content: center; }
  .v-turn { transform: rotate(90deg); }
  .v-split, .v-who, .v-form, .v-form3 { grid-template-columns: minmax(0, 1fr); }
  .v-life { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .v-numline { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .v-rules li { grid-template-columns: minmax(0, 1fr); gap: 6px; }
  .v-seq em { margin-left: 0; }
  .v-lines th:nth-child(4), .v-lines td:nth-child(4) { display: none; }
  .v-ladder, .v-aging { gap: 6px; }
  .v-ladder b { font-size: 12.5px; } .v-ladder span { display: none; }
  .v-months { grid-template-columns: repeat(6, minmax(0, 1fr)); row-gap: 8px; }
  .v-years span { font-size: 18px; }
  .v-lane span { display: none; }
  .v-report li { grid-template-columns: 18px minmax(0, 1fr); }
  .v-report li span { grid-column: 2; }
  .v-age-bar b { font-size: 11.5px; }
  .v-meter { width: 34px; margin-right: 5px; }
  .v-progress, .v-plain { font-size: 12px; }
  .v-plain th, .v-plain td { padding: 6px 5px; }
  .v-catalog th:nth-child(2), .v-catalog td:nth-child(2) { display: none; }
  .v-clients .v-btn { display: none; }
}
@container (max-width: 400px) { .v-chain { grid-template-columns: minmax(0, 1fr); } }
@media print { .tp-toc, .tp-pager, .tp-cta, .crumbs { display: none; } .tp-body { grid-template-columns: 1fr; } }
