/* Dokumente: Visuals der Funktionen und KI-Assistent */
.dk-fi { width: 36px; height: 36px; flex: none; border-radius: 10px; display: grid; place-items: center; background: #eceee9; color: var(--ink-2); }
.dk-fi svg, .dk-hit i svg, .dk-src svg, .dk-lock svg, .dk-tb svg, .dk-ai svg, .dk-in i svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.dk-name { width: min(480px, 100%); display: grid; gap: 10px; }
.dk-file { display: flex; gap: 12px; align-items: center; background: #fff; border-radius: 16px; padding: 14px 16px; box-shadow: 0 0 0 1px var(--line), 0 20px 40px -30px rgba(20,35,28,.4); }
.dk-file b { display: block; font-size: .95rem; } .dk-file small { display: block; color: var(--ink-3); font-size: .8rem; }
.dk-file--raw { opacity: .7; } .dk-file--raw b { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .85rem; font-weight: 600; }
.dk-file--ok .dk-fi { background: var(--lime); color: var(--ink); }
.dk-arrow { display: flex; justify-content: center; position: relative; height: 34px; }
.dk-arrow::before { content: ""; position: absolute; top: 0; bottom: 0; left: 50%; border-left: 2px dashed var(--petrol); opacity: .5; }
.dk-arrow span { position: relative; align-self: center; background: var(--ink); color: var(--lime); font-size: .75rem; font-weight: 800; border-radius: var(--r-pill); padding: 4px 12px; }
.dk-links { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; }
.dk-links em { font-style: normal; font-size: .76rem; font-weight: 700; background: rgba(255,255,255,.75); border-radius: var(--r-pill); padding: 4px 10px; color: var(--petrol); box-shadow: 0 0 0 1px var(--line); }
.dk-ocr { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: 14px; width: min(520px, 100%); align-items: center; }
.dk-page { position: relative; background: #fff; border-radius: 12px; padding: 18px 16px; box-shadow: 0 0 0 1px var(--line), 0 24px 40px -28px rgba(20,35,28,.45); overflow: hidden; display: grid; gap: 7px; }
.dk-l { height: 6px; border-radius: 3px; background: #e8ebe4; }
.w40 { width: 40%; } .w50 { width: 50%; } .w60 { width: 60%; } .w70 { width: 70%; } .w80 { width: 80%; } .w90 { width: 90%; }
.dk-hl { font-size: .72rem; font-weight: 700; color: var(--ink); background: rgba(212,239,107,.55); border-radius: 4px; padding: 2px 5px; justify-self: start; animation: dkHl 4s ease-in-out infinite; animation-delay: var(--d); }
@keyframes dkHl { 0%, 20% { background: transparent; } 35%, 100% { background: rgba(212,239,107,.55); } }
.dk-scan { position: absolute; left: 0; right: 0; height: 26px; background: linear-gradient(rgba(31,77,74,0), rgba(31,77,74,.18), rgba(31,77,74,0)); animation: dkScan 4s linear infinite; }
@keyframes dkScan { from { top: -26px; } to { top: 100%; } }
.dk-fields { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.dk-fields li { background: #fff; border-radius: 10px; padding: 8px 10px; box-shadow: 0 0 0 1px var(--line); }
.dk-fields small { display: block; font-size: .68rem; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; color: var(--ink-3); } .dk-fields b { font-size: .88rem; }
.dk-ver ol { list-style: none; margin: 10px 0 0; padding: 0; }
.dk-ver li { display: flex; align-items: center; gap: 12px; padding: 11px 0; border-top: 1px solid var(--line); }
.dk-ver li > span:nth-child(2) { flex: 1; } .dk-ver b { display: block; font-size: .92rem; } .dk-ver small { display: block; color: var(--ink-3); font-size: .8rem; }
.dk-v { width: 34px; height: 34px; border-radius: 10px; background: #eceee9; display: grid; place-items: center; font-weight: 800; font-size: .8rem; }
.dk-ver li.is-cur .dk-v { background: var(--ink); color: var(--lime); }
.dk-lock { display: flex; align-items: center; gap: 8px; margin-top: 8px; font-size: .82rem; font-weight: 700; color: var(--petrol); }
.dk-pdf { width: min(520px, 100%); background: #fff; border-radius: 16px; overflow: hidden; box-shadow: 0 0 0 1px var(--line), 0 24px 44px -30px rgba(20,35,28,.45); }
.dk-tb { display: flex; flex-wrap: wrap; gap: 4px; padding: 8px; border-bottom: 1px solid var(--line); background: #f7f8f5; }
.dk-tb span { display: inline-flex; align-items: center; gap: 6px; font-size: .78rem; font-weight: 700; padding: 6px 10px; border-radius: 8px; color: var(--ink-2); }
.dk-tb span.on { background: var(--ink); color: var(--lime); }
.dk-pg { position: relative; margin: 16px auto; width: 72%; aspect-ratio: .78; background: #fff; box-shadow: 0 0 0 1px var(--line), 0 10px 24px -14px rgba(20,35,28,.35); padding: 22px 18px; display: grid; gap: 9px; align-content: start; }
.dk-mark { background: rgba(212,239,107,.8); }
.dk-black { background: var(--ink); }
.dk-note { position: absolute; right: -14%; top: 30%; font-size: .72rem; font-weight: 700; background: #fff6d8; border-radius: 8px; padding: 6px 9px; box-shadow: 0 8px 16px -10px rgba(20,35,28,.4); transform: rotate(2deg); }
.dk-sign { position: absolute; left: 18px; bottom: 16px; font-family: "Brush Script MT", cursive; font-size: 1.15rem; color: var(--petrol); border-bottom: 1.5px solid var(--line); padding: 0 16px 2px 2px; }
.dk-ask-in { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: clamp(28px, 5vw, 72px); align-items: center; background: var(--aqua-pale); border-radius: 36px; padding: clamp(24px, 4vw, 56px); }
.dk-ask .intro { margin-top: 14px; }
.dk-chat { width: 100%; max-width: 560px; justify-self: center; background: #fff; border-radius: 22px; box-shadow: 0 40px 70px -40px rgba(20,35,28,.5), 0 0 0 1px var(--line); display: grid; grid-template-rows: auto 1fr auto; min-height: 430px; overflow: hidden; color: var(--ink); text-align: left; }
.dk-chat-h { display: flex; align-items: center; gap: 10px; padding: 14px 16px; border-bottom: 1px solid var(--line); }
.dk-chat-h b { display: block; font-size: .95rem; } .dk-chat-h small { display: block; color: var(--ink-3); font-size: .78rem; }
.dk-ai { width: 32px; height: 32px; border-radius: 10px; background: var(--lime); display: grid; place-items: center; }
.dk-msgs { padding: 16px; display: grid; gap: 10px; align-content: start; }
.dk-msgs > [data-s] { opacity: 0; transform: translateY(8px); transition: opacity .35s, transform .35s; }
.dk-msgs > [data-s].on { opacity: 1; transform: none; }
.dk-q { justify-self: end; max-width: 86%; background: var(--ink); color: #fff; border-radius: 16px 16px 4px 16px; padding: 10px 14px; font-size: .92rem; min-height: 2.6em; }
.dk-search { display: flex; align-items: center; gap: 10px; font-size: .82rem; color: var(--ink-3); }
.dk-spin { width: 16px; height: 16px; border-radius: 50%; border: 2px solid #dde2d6; border-top-color: var(--petrol); animation: dkSpin .8s linear infinite; }
@keyframes dkSpin { to { transform: rotate(360deg); } }
.dk-chat:not(.is-searching) .dk-spin { animation: none; border-color: var(--petrol); }
.dk-hit { display: inline-flex; align-items: center; gap: 10px; background: #f7f8f5; border-radius: 12px; padding: 8px 12px; font-size: .85rem; font-weight: 700; box-shadow: 0 0 0 1px var(--line); }
.dk-hit i { width: 30px; height: 30px; border-radius: 8px; background: var(--aqua-pale); color: var(--petrol); display: grid; place-items: center; }
.dk-hit small { display: block; font-weight: 500; color: var(--ink-3); font-size: .76rem; }
.dk-a { background: #f3f6f1; border-radius: 16px 16px 16px 4px; padding: 12px 14px; font-size: .9rem; line-height: 1.5; max-width: 94%; }
.dk-src { display: inline-flex; align-items: center; gap: 6px; margin-top: 8px; font-size: .76rem; font-weight: 700; color: var(--petrol); }
.dk-in { display: flex; justify-content: space-between; align-items: center; margin: 0 12px 12px; padding: 10px 10px 10px 14px; border-radius: 14px; box-shadow: 0 0 0 1px var(--line); color: var(--ink-3); font-size: .88rem; }
.dk-in i { width: 32px; height: 32px; border-radius: 10px; background: var(--ink); color: var(--lime); display: grid; place-items: center; }
.dk-chat-c .tb-vis { margin-top: 18px; }
.dk-chat-c .tb-txt h3 { color: #fff; } .dk-chat-c .tb-txt > p:not(.tb-k) { color: var(--on-dark-2); } .dk-chat-c .tb-k { color: var(--lime); }
.tb-c--ink.dk-chat-c { justify-content: flex-start; display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: 32px; align-items: center; }
.qc-media .dk-chat { min-height: 400px; }
@media (max-width: 900px) { .dk-ask-in, .tb-c--ink.dk-chat-c { grid-template-columns: 1fr; } }
@media (max-width: 520px) { .dk-ocr { grid-template-columns: 1fr; } .dk-note { right: -4%; } }
@media (prefers-reduced-motion: reduce) { .dk-scan, .dk-hl, .dk-spin { animation: none; } }
.dk-full { margin: clamp(56px, 8vw, 96px) 0; }
.dk-full-h { display: flex; align-items: center; gap: 14px; font-size: clamp(1.6rem, 2.6vw, 2.2rem); letter-spacing: -0.025em; }
.dk-full-lead { margin-top: 10px; font-size: 1.15rem; color: var(--ink-2); }
.dk-full-p { margin-top: 12px; color: var(--ink-2); max-width: 46ch; }
/* Kopf: Dokumente wandern von links in die Ordner rechts */
.dkn-ln { fill: none; stroke: var(--ink); stroke-width: 1; stroke-dasharray: 2 8; opacity: .6; }
.dkn-mv { fill: #fff; stroke: var(--petrol); stroke-width: 1.4; stroke-linejoin: round; }
.dkn-scan { fill: var(--petrol); animation: dknScan 2.4s ease-in-out infinite; }
@keyframes dknScan { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(42px); } }
@media (prefers-reduced-motion: reduce) { .dkn-mv { display: none; } .dkn-scan { animation: none; } }
.dkn-scan { animation-name: dknScan2; }
@keyframes dknScan2 { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(22px); } }
.pz-hero h1.dk-h1 { max-width: 13ch; }
/* Kacheln: Versionen und PDF-Editor gleichmäßig füllen */
.tb .tb-c--half .tb-vis--panel { margin-top: 24px; flex: 1; align-items: flex-end; }
.tb .tb-c--half .dk-ver { margin-top: auto; }
.tb-c--ink.dk-chat-c { grid-column: 1 / -1; }
.tb .dk-pg { aspect-ratio: auto; height: 230px; width: 78%; }
.tb .tb-c--half .tb-vis--panel { align-items: center; }
.dk-chat:not(.is-searching) .dk-spin { background: var(--petrol); box-shadow: inset 0 0 0 3px #fff; }

/* PDF-Editor zum Ausprobieren */
.dk-tb { align-items: center; }
.dk-tb button { all: unset; box-sizing: border-box; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; font-size: .78rem; font-weight: 700; padding: 0 10px; min-height: 36px; border-radius: 8px; color: var(--ink-2); transition: background .25s, color .25s; }
.dk-tb button:hover { background: #eceee9; }
.dk-tb button svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.dk-tb button.on { background: var(--ink); color: var(--lime); }
.dk-tb button:focus-visible { outline: 2px solid var(--petrol); outline-offset: 2px; }
.dk-tb .dk-reset { margin-left: auto; color: var(--ink-3); font-weight: 600; }
.dk-hint { font-size: .8rem; color: var(--ink-3); padding: 8px 12px 0; min-height: 1.6em; }
.tb .dk-pdf .dk-pg, .dk-pdf .dk-pg { position: relative; height: auto; aspect-ratio: auto; width: 84%; margin: 10px auto 16px; padding: 18px 18px 12px; display: grid; gap: 5px; align-content: start; text-align: left; }
.dk-ttl { font-weight: 800; font-size: .9rem; margin-bottom: 4px; }
.dk-ln { font-size: .78rem; line-height: 1.5; color: var(--ink-2); border-radius: 3px; padding: 0 3px; margin: 0 -3px; transition: background .3s, color .3s; background-image: linear-gradient(rgba(212,239,107,.9), rgba(212,239,107,.9)); background-repeat: no-repeat; background-size: 0% 100%; }
.dk-ln--h { font-weight: 800; color: var(--ink); margin-top: 4px; }
.dk-ln.is-mark { background-size: 100% 100%; color: var(--ink); transition: background-size .7s cubic-bezier(.4,.1,.2,1); }
.dk-ln.is-black { background: var(--ink); color: transparent; user-select: none; }
.dk-pdf[data-tool="mark"] .dk-ln, .dk-pdf[data-tool="black"] .dk-ln { cursor: pointer; }
.dk-pdf[data-tool="mark"] .dk-ln:hover { outline: 1.5px dashed var(--lime); }
.dk-pdf[data-tool="black"] .dk-ln:hover { outline: 1.5px dashed var(--ink); }
.dk-pdf[data-tool="note"] .dk-pg { cursor: copy; }
.dk-note2 { position: absolute; z-index: 2; max-width: 150px; font-size: .72rem; font-weight: 700; background: #fff6d8; border-radius: 8px; padding: 6px 9px; box-shadow: 0 8px 16px -10px rgba(20,35,28,.4); transform: rotate(2deg); animation: dkPop .35s cubic-bezier(.3,1.6,.5,1); outline: none; }
.dk-note2:focus { box-shadow: 0 0 0 2px var(--petrol); }
@keyframes dkPop { from { transform: rotate(2deg) scale(.5); opacity: 0; } }
.dk-sigbox { position: relative; margin-top: 10px; border-bottom: 1.5px solid var(--line); }
.dk-sigc { display: block; width: 100%; height: 70px; touch-action: none; }
.dk-pdf[data-tool="sign"] .dk-sigc { cursor: crosshair; background: rgba(212,239,107,.12); border-radius: 6px; }
.dk-sigbox span { position: absolute; left: 0; bottom: -18px; font-size: .68rem; color: var(--ink-3); }
.dk-pg { padding-bottom: 26px !important; }
@media (prefers-reduced-motion: reduce) { .dk-ln, .dk-note2 { transition: none; animation: none; } }

/* Kopf: wechselndes Wort unter dem Titel (wie Rundschreiben) */
.dk-words { margin-top: clamp(12px, 1.8vw, 20px); display: grid; justify-items: center; position: relative; overflow: hidden; padding-bottom: 10px; font-size: clamp(1.5rem, 2.8vw, 2.3rem); font-weight: 800; letter-spacing: -0.025em; color: var(--petrol); will-change: transform; }
.dk-words span { grid-area: 1 / 1; opacity: 0; transform: translateY(70%); transition: opacity .45s, transform .55s cubic-bezier(.2,.8,.2,1); }
.dk-words span.is-on { opacity: 1; transform: none; }
.dk-words span.is-out { opacity: 0; transform: translateY(-70%); }
.dk-words::after { content: ""; position: absolute; left: 50%; bottom: 0; width: 56px; height: 4px; border-radius: 2px; background: var(--lime); transform: translateX(-50%); }
@media (prefers-reduced-motion: reduce) { .dk-words span { transition: none; } }
