/* Zalcara Demo – statische Präsentationsseite, keine externen Abhängigkeiten */
:root {
  --ink: #1b2a4a; --ink-2: #243a66; --ink-3: #14213a;
  --accent: #b4914f; --accent-soft: #fbf7ee; --accent-text: #6b5423;
  --bg: #f5f6fa; --paper: #fff; --line: #e3e5ec; --muted: #6c757d; --text: #1f2430;
  --green: #198754; --green-soft: #e7f5ec; --red: #b02a37; --red-soft: #f8d7da; --amber: #997404; --amber-soft: #fff3cd;
  --serif: Georgia, "Times New Roman", serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  --shadow: 0 1px 3px rgba(11,16,32,.08), 0 8px 24px rgba(11,16,32,.06);
  --ease: cubic-bezier(.4, 0, .2, 1);
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { font-family: var(--sans); color: var(--text); background: var(--bg); display: flex; flex-direction: column; min-height: 100vh; font-size: 17px; line-height: 1.45; }
a { color: var(--ink-2); }
h1 { font-family: var(--serif); font-weight: 400; font-size: 2.2rem; margin: 0 0 .5rem; color: var(--ink); letter-spacing: .01em; }
.lead { font-size: 1.15rem; color: var(--muted); margin: 0 0 1.5rem; }
.muted { color: var(--muted); }
.green { color: var(--green); } .red { color: var(--red); }
.r { text-align: right; white-space: nowrap; }
[hidden] { display: none !important; }

/* ---------- Header ---------- */
.z-header { display: flex; align-items: center; gap: 2rem; padding: .6rem 2rem; background: linear-gradient(90deg, #14213a 0%, #1b2a4a 70%, #243a66 100%); border-bottom: 2px solid var(--accent); color: #fff; position: sticky; top: 0; z-index: 50; }
.z-brand { display: flex; align-items: center; gap: .8rem; text-decoration: none; color: #e8dcc0; }
.z-brand img { height: 46px; width: 46px; border-radius: 50%; background: #fff; box-shadow: 0 0 0 2px rgba(232,220,192,.35); }
.z-wordmark { font-family: var(--serif); letter-spacing: .28em; text-transform: uppercase; font-size: 1.25rem; font-weight: 400; }
.z-demo-tag { font-size: .65rem; letter-spacing: .15em; text-transform: uppercase; border: 1px solid var(--accent); color: var(--accent); padding: .1rem .45rem; border-radius: 3px; }
.z-steps { display: flex; align-items: center; gap: .9rem; margin-left: auto; }
.z-step { display: flex; align-items: center; gap: .5rem; color: rgba(255,255,255,.55); text-decoration: none; font-size: .95rem; white-space: nowrap; transition: color .3s; }
.z-step .n { display: inline-flex; width: 1.6rem; height: 1.6rem; border-radius: 50%; border: 1px solid rgba(255,255,255,.35); align-items: center; justify-content: center; font-size: .8rem; transition: all .3s; }
.z-step.active { color: #fff; }
.z-step.active .n { background: var(--accent); border-color: var(--accent); color: var(--ink-3); font-weight: 700; }
.z-step.done { color: rgba(255,255,255,.85); }
.z-step.done .n { background: var(--green); border-color: var(--green); color: #fff; }
.z-step-sep { width: 2.2rem; height: 1px; background: rgba(255,255,255,.25); }
.z-header-right { margin-left: auto; }
.z-client { font-size: .9rem; color: rgba(255,255,255,.85); display: flex; align-items: center; gap: .5rem; }
.z-client .dot { width: .6rem; height: .6rem; border-radius: 50%; background: #4ade80; box-shadow: 0 0 0 3px rgba(74,222,128,.25); }

main { flex: 1; display: flex; flex-direction: column; }
.screen { flex: 1; padding: 2rem 2.5rem; animation: screen-in .45s var(--ease); }
@keyframes screen-in { from { opacity: 0; transform: translateY(8px);} to { opacity: 1; transform: none;} }

.z-foot { display: flex; justify-content: space-between; padding: .6rem 2rem; font-size: .8rem; color: var(--muted); border-top: 1px solid var(--line); background: #fff; }
.z-keys kbd { font-family: var(--mono); background: #eef0f5; border: 1px solid #d5d9e3; border-bottom-width: 2px; border-radius: 4px; padding: 0 .4em; font-size: .75rem; }

/* ---------- Buttons ---------- */
.btn { display: inline-flex; align-items: center; gap: .6rem; border: 1px solid transparent; border-radius: 8px; padding: .6rem 1.2rem; font: inherit; font-weight: 600; cursor: pointer; text-decoration: none; transition: transform .15s var(--ease), box-shadow .15s, background .2s; }
.btn:active { transform: translateY(1px); }
.btn-xl { font-size: 1.2rem; padding: .9rem 1.8rem; border-radius: 10px; }
.btn-primary { background: var(--ink); color: #fff; box-shadow: 0 6px 18px rgba(27,42,74,.25); }
.btn-primary:hover { background: var(--ink-2); box-shadow: 0 8px 22px rgba(27,42,74,.32); }
.btn-success { background: var(--green); color: #fff; box-shadow: 0 6px 18px rgba(25,135,84,.25); }
.btn-success:hover { background: #157347; }
.btn-outline { background: transparent; color: var(--ink); border-color: var(--ink); }
.btn-outline:hover { background: var(--ink); color: #fff; }
.btn-appear { animation: pop-in .5s var(--ease) both; }
@keyframes pop-in { 0% { opacity: 0; transform: scale(.85) translateY(10px);} 60% { transform: scale(1.03) translateY(-2px);} 100% { opacity: 1; transform: none;} }

.z-key { font-family: var(--mono); font-size: .65rem; color: #8a8f99; background: #f1f2f6; padding: .05em .35em; border-radius: 3px; font-weight: 400; vertical-align: middle; }
.panel-title { display: flex; justify-content: space-between; align-items: baseline; font-size: .78rem; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); margin-bottom: .6rem; }
.panel-title > span:first-child { color: var(--ink); font-weight: 700; }
.panel-title .muted { text-transform: none; letter-spacing: 0; font-size: .8rem; }
.spinner { display: inline-block; width: .9em; height: .9em; border: 2px solid var(--line); border-top-color: var(--accent); border-radius: 50%; animation: spin .8s linear infinite; vertical-align: -.1em; }
@keyframes spin { to { transform: rotate(360deg);} }

/* ---------- Schritt 1: Upload ---------- */
.screen-upload { display: flex; align-items: center; justify-content: center; }
.upload-card { width: min(820px, 100%); background: var(--paper); border-radius: 18px; box-shadow: var(--shadow); padding: 3rem 3.5rem; text-align: center; transition: box-shadow .4s; }
.upload-card.success { box-shadow: 0 0 0 3px var(--green-soft), 0 12px 40px rgba(25,135,84,.18); }
.dropzone { border: 2px dashed #b9b7d8; border-radius: 14px; padding: 3rem 2rem 2rem; background: #fafbff; transition: all .3s; }
.dropzone:hover, .dropzone.dragover { border-color: var(--accent); background: var(--accent-soft); }
.icon-upload { width: 84px; height: 84px; fill: none; stroke: var(--ink); stroke-width: 2.5; opacity: .85; margin-bottom: .6rem; }
.dz-text { font-size: 1.15rem; margin: 0 0 1.2rem; color: var(--muted); }
.dz-hint { margin: 1.4rem 0 0; font-size: .9rem; color: var(--muted); }

.file-list { list-style: none; padding: 0; margin: 1.5rem auto 1.5rem; max-width: 520px; text-align: left; }
.file-list li { display: flex; align-items: center; gap: .8rem; padding: .55rem .8rem; border-radius: 8px; opacity: .45; transition: all .3s; }
.file-list li.active { opacity: 1; background: var(--accent-soft); }
.file-list li.done { opacity: 1; }
.file-list .fi { width: 1.6rem; height: 1.6rem; border-radius: 6px; background: #eef0f5; display: inline-flex; align-items: center; justify-content: center; font-size: .6rem; font-weight: 700; color: var(--ink); font-family: var(--mono); }
.file-list .fn { flex: 1; font-family: var(--mono); font-size: .9rem; }
.file-list .st { font-size: .8rem; color: var(--muted); min-width: 5rem; text-align: right; }
.file-list li.done .st { color: var(--green); font-weight: 600; }
.progress { height: 12px; background: #eef0f5; border-radius: 6px; overflow: hidden; max-width: 520px; margin: 0 auto; }
.progress-bar { height: 100%; width: 0; background: linear-gradient(90deg, var(--accent), #d4b86f); border-radius: 6px; transition: width .35s var(--ease); }
.progress-label { margin: .7rem 0 0; color: var(--muted); font-variant-numeric: tabular-nums; }

.check-wrap { margin: 0 auto 1rem; width: 140px; height: 140px; }
.check { width: 100%; height: 100%; }
.check-circle { fill: var(--green-soft); stroke: var(--green); stroke-width: 4; stroke-dasharray: 340; stroke-dashoffset: 340; animation: draw .7s var(--ease) forwards; }
.check-mark { fill: none; stroke: var(--green); stroke-width: 8; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 80; stroke-dashoffset: 80; animation: draw .45s var(--ease) .5s forwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }

/* ---------- Schritt 2: Auslesung ---------- */
.analyse-grid { display: grid; grid-template-columns: minmax(520px, 1fr) minmax(460px, 1fr); gap: 2.5rem; align-items: start; max-width: 1500px; margin: 0 auto; width: 100%; }
.paper { position: relative; background: var(--paper); box-shadow: var(--shadow); padding: 2.2rem 2.4rem; font-size: .84rem; line-height: 1.4; color: #222; overflow: hidden; border-radius: 4px; }
.scanline { position: absolute; left: 0; right: 0; height: 3px; top: 0; background: linear-gradient(90deg, transparent, var(--accent), transparent); box-shadow: 0 0 18px 4px rgba(180,145,79,.45); opacity: 0; pointer-events: none; }
.scanline.run { opacity: 1; animation: scan 2.2s var(--ease) forwards; }
@keyframes scan { from { top: 0; } to { top: 100%; } }
.inv-head { display: flex; justify-content: space-between; gap: 1.5rem; margin-bottom: 1.6rem; }
.inv-supplier { display: flex; gap: .9rem; align-items: flex-start; }
.inv-logo { width: 46px; height: 46px; border-radius: 8px; background: #2f4858; color: #fff; display: flex; align-items: center; justify-content: center; font-family: var(--serif); font-size: 1.6rem; flex-shrink: 0; }
.inv-name { font-weight: 700; font-size: 1rem; }
.inv-addr { color: #555; font-size: .78rem; margin-top: .2rem; }
.inv-meta { text-align: right; }
.inv-title { font-family: var(--serif); font-size: 1.6rem; letter-spacing: .08em; text-transform: uppercase; color: #2f4858; margin-bottom: .3rem; }
.inv-meta-table { margin-left: auto; border-collapse: collapse; font-size: .8rem; }
.inv-meta-table td { padding: .05rem .3rem; }
.inv-meta-table td:first-child { color: #666; text-align: left; }
.inv-recipient { margin-bottom: 1.4rem; }
.inv-label { font-size: .68rem; text-transform: uppercase; letter-spacing: .1em; color: #888; margin-bottom: .15rem; }
.inv-lines { width: 100%; border-collapse: collapse; margin-bottom: 1rem; }
.inv-lines th { text-align: left; font-size: .72rem; text-transform: uppercase; letter-spacing: .05em; color: #666; border-bottom: 1.5px solid #333; padding: .3rem .4rem; }
.inv-lines td { padding: .4rem .4rem; border-bottom: 1px solid #e8e8e8; vertical-align: top; }
.inv-lines small { color: #777; }
.inv-totals { display: flex; justify-content: flex-end; margin-bottom: 1.6rem; }
.inv-totals table { border-collapse: collapse; min-width: 300px; }
.inv-totals td { padding: .2rem .4rem; }
.inv-totals tr.total td { border-top: 2px solid #333; font-weight: 700; font-size: 1rem; padding-top: .4rem; }
.inv-foot { border-top: 1px solid #ddd; padding-top: .8rem; font-size: .74rem; color: #444; display: grid; gap: .25rem; }
.inv-foot .muted { color: #888; }

[data-src] { border-radius: 3px; padding: 0 .15em; margin: 0 -.15em; transition: background .3s, box-shadow .3s; }
[data-src].hl { background: var(--amber-soft); box-shadow: 0 0 0 2px var(--accent); }
[data-src].found { background: var(--amber-soft); border-bottom: 1px dotted var(--accent); }
.inv-lines tr.hl td { background: var(--amber-soft); }
.inv-lines tr.found td { background: #fdfaf0; }

.flyer { position: fixed; z-index: 100; pointer-events: none; background: var(--amber-soft); color: var(--text); border: 1px solid var(--accent); border-radius: 5px; padding: .15em .45em; font-size: .9rem; font-weight: 600; box-shadow: 0 6px 18px rgba(180,145,79,.35); white-space: nowrap; transform-origin: left center; }

.col-data { display: flex; flex-direction: column; gap: 1rem; }
.status-line { display: flex; align-items: center; gap: .6rem; color: var(--muted); font-size: .95rem; min-height: 1.6rem; }
.doctype-badge { display: flex; align-items: center; gap: .8rem; background: var(--green-soft); color: var(--green); border: 1px solid #b7dfc5; border-radius: 12px; padding: .8rem 1.1rem; animation: badge-in .6s var(--ease) both; }
.doctype-badge strong { display: block; font-size: 1.25rem; }
.doctype-badge small { color: #2d6a4f; }
@keyframes badge-in { 0% { opacity: 0; transform: scale(.6) translateY(-10px);} 60% { transform: scale(1.06);} 100% { opacity: 1; transform: none;} }

.data-card { background: var(--paper); border-radius: 12px; box-shadow: var(--shadow); overflow: hidden; }
.data-card-head { padding: .7rem 1.1rem; font-weight: 700; color: var(--ink); border-bottom: 1px solid var(--line); display: flex; align-items: center; gap: .6rem; }
.data-card-head .count { margin-left: auto; background: var(--ink); color: #fff; border-radius: 999px; font-size: .75rem; padding: .05rem .55rem; }
.data-table { width: 100%; border-collapse: collapse; }
.data-table th, .data-table td { padding: .5rem 1.1rem; border-bottom: 1px solid #f0f1f5; text-align: left; font-size: .95rem; }
.data-table th { color: var(--muted); font-weight: 500; width: 38%; }
.data-table tbody tr:last-child th, .data-table tbody tr:last-child td { border-bottom: 0; }
.data-table .val { font-family: var(--mono); font-size: .92rem; color: var(--text); display: inline-block; }
.data-table tr:not(.filled) .val::before { content: "·  ·  ·"; color: #c9ccd6; letter-spacing: .1em; }
.data-table tr.filled .val { animation: val-in .35s var(--ease); }
.data-table tr.filled td { background: linear-gradient(90deg, var(--accent-soft), transparent 60%); }
@keyframes val-in { from { transform: scale(1.15); color: var(--accent-text);} to { transform: none;} }
.lines-table thead th { font-size: .72rem; text-transform: uppercase; letter-spacing: .05em; width: auto; }
.lines-table td { font-size: .9rem; }
.lines-table tbody tr { animation: row-in .4s var(--ease) both; }
@keyframes row-in { from { opacity: 0; transform: translateX(-12px);} to { opacity: 1; transform: none;} }
.lines-card { animation: badge-in .5s var(--ease) both; }
.actions { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding-top: .5rem; }

/* ---------- Schritt 3: Beurteilung ---------- */
.doc-strip { display: flex; align-items: center; gap: 1.5rem; background: var(--paper); border-radius: 12px; box-shadow: var(--shadow); padding: .8rem 1.3rem; margin-bottom: 1.3rem; max-width: 1600px; margin-left: auto; margin-right: auto; }
.doc-strip .muted { font-size: .9rem; }
.strip-amount { margin-left: auto; font-family: var(--mono); font-size: 1.3rem; font-weight: 700; color: var(--ink); }
.tax-grid { display: grid; grid-template-columns: 320px minmax(520px, 1fr) 340px; gap: 1.6rem; align-items: start; max-width: 1600px; margin: 0 auto; width: 100%; }

.col-lines, .col-accounts { position: sticky; top: 5.2rem; }
.line-cards { display: flex; flex-direction: column; gap: .6rem; }
.line-card { background: var(--paper); border-radius: 10px; box-shadow: var(--shadow); padding: .7rem .9rem; display: grid; grid-template-columns: 1.6rem 1fr auto; gap: .5rem; align-items: center; border-left: 4px solid var(--line); transition: all .35s var(--ease); }
.line-card .no { width: 1.5rem; height: 1.5rem; border-radius: 50%; background: #f1f2f6; color: var(--ink); font-size: .75rem; font-weight: 700; display: inline-flex; align-items: center; justify-content: center; }
.line-card .desc { font-size: .92rem; line-height: 1.3; }
.line-card .desc small { display: block; color: var(--muted); font-size: .78rem; }
.line-card .amt { font-family: var(--mono); font-weight: 600; white-space: nowrap; }
.line-card.active { border-left-color: var(--accent); box-shadow: 0 0 0 3px var(--amber-soft), var(--shadow); transform: translateX(6px); }
.line-card.done { border-left-color: var(--green); opacity: .78; }
.line-card.done[data-share="50"] { border-left-color: var(--accent); }
.line-card.done[data-share="0"] { border-left-color: var(--red); }
.line-card .share { font-size: .7rem; font-weight: 700; padding: .05rem .4rem; border-radius: 3px; margin-left: .3rem; display: none; }
.line-card.done .share { display: inline-block; }
.share-100 { background: var(--green-soft); color: var(--green); }
.share-50 { background: var(--amber-soft); color: var(--amber); }
.share-0 { background: var(--red-soft); color: var(--red); }

.status-inline { text-transform: none; letter-spacing: 0; font-size: .85rem; display: flex; gap: .5rem; align-items: center; }
.assess-stream { display: flex; flex-direction: column; gap: .9rem; }
.assess-card { background: var(--paper); border-radius: 12px; box-shadow: var(--shadow); padding: 1rem 1.2rem 1rem 1.2rem; border-left: 5px solid var(--ink); animation: card-in .55s var(--ease) both; position: relative; }
.assess-card[data-share="50"] { border-left-color: var(--accent); }
.assess-card[data-share="0"] { border-left-color: var(--red); }
.assess-card[data-kind="doc"] { border-left-color: var(--ink-2); background: linear-gradient(180deg, #fff, #f8f9fd); }
@keyframes card-in { 0% { opacity: 0; transform: translateY(18px) scale(.98);} 100% { opacity: 1; transform: none;} }
.assess-head { display: flex; align-items: center; gap: .7rem; margin-bottom: .35rem; }
.assess-head .kind { font-size: .68rem; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); }
.assess-head h3 { margin: 0; font-size: 1.05rem; color: var(--ink); font-weight: 700; }
.assess-head .pill { margin-left: auto; font-size: .8rem; font-weight: 700; padding: .15rem .6rem; border-radius: 999px; white-space: nowrap; }
.assess-text { margin: 0 0 .6rem; line-height: 1.5; }
.assess-text .z-cite { background: var(--amber-soft); border-bottom: 1px dotted var(--accent); }
.assess-norms { display: flex; flex-wrap: wrap; gap: .35rem; }
.norm { display: inline-flex; align-items: center; gap: .35rem; font-size: .78rem; line-height: 1.3; padding: .15rem .55rem; border-radius: 4px; background: var(--accent-soft); border: 1px solid var(--accent); color: var(--accent-text); animation: norm-in .4s var(--ease) both; cursor: help; }
.norm::before { content: "§"; font-family: var(--serif); font-weight: 700; }
@keyframes norm-in { from { opacity: 0; transform: translateY(6px);} to { opacity: 1; transform: none;} }
.assess-fact { margin-top: .6rem; padding: .45rem .7rem; background: #f6f7fb; border-radius: 6px; font-size: .85rem; color: #3b4252; display: grid; gap: .2rem; }
.assess-fact .q { color: var(--muted); }
.assess-fact .q::before { content: "Rückfrage an Mandantin: "; font-weight: 600; color: var(--ink-2); }
.assess-fact .a::before { content: "Antwort: "; font-weight: 600; color: var(--green); }
.assess-fact .src::before { content: "Quelle: "; font-weight: 600; color: var(--ink-2); }
.assess-booking { display: flex; align-items: center; gap: .5rem; margin-top: .6rem; font-size: .85rem; color: var(--muted); }
.assess-booking .acct { font-family: var(--mono); background: var(--ink); color: #fff; padding: .05rem .45rem; border-radius: 4px; font-size: .8rem; }

.accounts { display: flex; flex-direction: column; gap: .4rem; }
.account { background: var(--paper); border-radius: 8px; box-shadow: var(--shadow); padding: .55rem .8rem; display: grid; grid-template-columns: auto 1fr auto; gap: .6rem; align-items: center; opacity: .55; transition: all .4s var(--ease); border: 2px solid transparent; }
.account .num { font-family: var(--mono); font-weight: 700; color: var(--ink); font-size: .9rem; }
.account .name { font-size: .88rem; line-height: 1.2; }
.account .sum { font-family: var(--mono); font-size: .9rem; color: var(--muted); min-width: 5.5rem; text-align: right; }
.account.used { opacity: 1; }
.account.used .sum { color: var(--ink); font-weight: 700; }
.account.receive { border-color: var(--accent); background: var(--accent-soft); transform: scale(1.04); box-shadow: 0 0 0 4px var(--amber-soft), var(--shadow); }
.account .sum.bump { animation: bump .45s var(--ease); }
@keyframes bump { 0% { transform: scale(1);} 40% { transform: scale(1.25); color: var(--accent-text);} 100% { transform: scale(1);} }

.summary-card { background: var(--paper); border-radius: 12px; box-shadow: var(--shadow); padding: 1.1rem 1.3rem; border-top: 4px solid var(--accent); animation: card-in .55s var(--ease) both; margin-top: .9rem; }
.summary-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; margin-bottom: 1rem; }
.summary-grid small { display: block; color: var(--muted); font-size: .78rem; text-transform: uppercase; letter-spacing: .08em; }
.summary-grid strong { font-family: var(--mono); font-size: 1.5rem; color: var(--ink); }
.summary-actions { display: flex; gap: .8rem; align-items: center; }

.z-toast { position: fixed; left: 50%; bottom: 3.5rem; transform: translateX(-50%); background: var(--ink); color: #fff; padding: .8rem 1.4rem; border-radius: 10px; box-shadow: 0 10px 30px rgba(0,0,0,.25); font-size: 1rem; display: flex; align-items: center; gap: .6rem; animation: toast-in .4s var(--ease); z-index: 200; }
@keyframes toast-in { from { opacity: 0; transform: translate(-50%, 12px);} to { opacity: 1; transform: translate(-50%, 0);} }

@media (max-width: 1100px) {
  .analyse-grid, .tax-grid { grid-template-columns: 1fr; }
  .z-steps { display: none; }
  .screen { padding: 1.2rem 1rem; }
}

/* ---------- Beleg-Status im Kopfstreifen (gelb bei offener Rückfrage, grün nach Antwort) ---------- */
.doc-strip { border-left: 5px solid var(--line); transition: border-color .5s, background .5s; }
.doc-strip[data-state="open"] { border-left-color: var(--amber); background: #fffdf5; }
.doc-strip[data-state="ok"], .doc-strip[data-state="done"] { border-left-color: var(--green); background: #f6fcf8; }
.doc-status { margin-left: auto; display: inline-flex; align-items: center; gap: .45rem; font-size: .85rem; font-weight: 600; padding: .25rem .75rem; border-radius: 999px; background: #f1f2f6; color: var(--muted); transition: all .4s; white-space: nowrap; }
.doc-status[data-state="open"] { background: var(--amber-soft); color: var(--amber); animation: pulse 1.4s ease-in-out infinite; }
.doc-status[data-state="ok"], .doc-status[data-state="done"] { background: var(--green-soft); color: var(--green); }
.doc-status .spinner { border-top-color: currentColor; }
.strip-amount { margin-left: 0; }
@keyframes pulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(153,116,4,.35);} 50% { box-shadow: 0 0 0 7px rgba(153,116,4,0);} }

/* Karte im Zustand „unklar / Rückfrage offen“ und Aufblitzen nach der Antwort */
.assess-card[data-state="open"] { border-left-color: var(--amber); background: linear-gradient(180deg, #fff, #fffcf2); }
.pill.share-open { background: var(--amber-soft); color: var(--amber); }
.assess-fact-open .waiting { display: flex; align-items: center; gap: .5rem; color: var(--amber); font-weight: 600; margin-top: .2rem; }
.assess-card.flash { animation: card-flash 1.1s var(--ease); }
@keyframes card-flash { 0% { box-shadow: 0 0 0 0 rgba(25,135,84,.0); } 25% { box-shadow: 0 0 0 6px rgba(25,135,84,.35), var(--shadow); background: var(--green-soft);} 100% { box-shadow: var(--shadow); } }
.line-card[data-state="open"] { border-left-color: var(--amber); box-shadow: 0 0 0 3px var(--amber-soft), var(--shadow); }

/* ---------- Handy-Overlay: Rückfrage an die Mandantin ---------- */
.phone-backdrop { position: fixed; inset: 0; z-index: 150; background: rgba(20,33,58,.55); backdrop-filter: blur(2px); display: flex; align-items: center; justify-content: center; gap: 3rem; animation: fade-in .4s var(--ease); }
.phone-backdrop.out { animation: fade-out .45s var(--ease) forwards; }
@keyframes fade-in { from { opacity: 0;} to { opacity: 1;} }
@keyframes fade-out { to { opacity: 0;} }
.phone-caption { color: #fff; max-width: 320px; display: grid; gap: .6rem; animation: card-in .6s var(--ease) .2s both; }
.phone-caption strong { font-family: var(--serif); font-size: 1.7rem; font-weight: 400; }
.phone-caption span { color: rgba(255,255,255,.8); line-height: 1.5; }
.phone { width: 340px; height: 700px; background: #0d0f14; border-radius: 48px; padding: 12px; box-shadow: 0 40px 90px rgba(0,0,0,.55), inset 0 0 0 2px #2a2d36; animation: phone-in .7s var(--ease) both; flex-shrink: 0; }
@keyframes phone-in { from { opacity: 0; transform: translateY(60px) scale(.92);} to { opacity: 1; transform: none;} }
.phone-screen { position: relative; height: 100%; border-radius: 38px; overflow: hidden; background: linear-gradient(160deg, #1b2a4a, #0f1a30 60%, #243a66); display: flex; flex-direction: column; }
.phone-notch { position: absolute; top: 10px; left: 50%; transform: translateX(-50%); width: 112px; height: 32px; background: #0d0f14; border-radius: 20px; z-index: 6; }
.phone-status { display: flex; justify-content: space-between; padding: 16px 26px 0; font-size: .75rem; font-weight: 600; color: #fff; z-index: 5; }
.phone-home { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; padding-top: 90px; color: #fff; transition: opacity .4s; }
.phone-home.hide { opacity: 0; }
.phone-clock { font-size: 4rem; font-weight: 200; letter-spacing: -.02em; line-height: 1; }
.phone-date { opacity: .8; margin-top: .4rem; }
.phone-notif { position: absolute; top: 58px; left: 12px; right: 12px; z-index: 7; background: rgba(255,255,255,.96); border-radius: 18px; padding: .65rem .8rem; display: flex; gap: .7rem; align-items: flex-start; box-shadow: 0 10px 30px rgba(0,0,0,.3); transform: translateY(-140px); opacity: 0; transition: transform .55s var(--ease), opacity .4s; }
.phone-notif.show { transform: none; opacity: 1; }
.phone-notif img { width: 38px; height: 38px; border-radius: 10px; }
.phone-notif .n-head { display: flex; justify-content: space-between; font-size: .8rem; }
.phone-notif .n-head span { color: var(--muted); }
.phone-notif .n-text { font-size: .82rem; line-height: 1.3; color: #222; }
.phone-app { position: absolute; inset: 0; background: var(--bg); display: flex; flex-direction: column; opacity: 0; transform: scale(.96); transition: all .45s var(--ease); }
.phone-app.show { opacity: 1; transform: none; }
.phone-app-head { background: linear-gradient(90deg, #14213a, #1b2a4a 70%, #243a66); color: #fff; padding: 2.9rem 1.1rem .9rem; display: flex; align-items: center; gap: .7rem; border-bottom: 2px solid var(--accent); }
.phone-app-head img { width: 34px; height: 34px; border-radius: 50%; background: #fff; }
.phone-app-head strong { display: block; font-size: 1rem; }
.phone-app-head small { color: #e8dcc0; font-size: .75rem; }
.q-stack { position: relative; flex: 1; margin: 1.1rem .9rem 1.2rem; }
.q-card { position: absolute; inset: 0; background: #fff; border-radius: 22px; box-shadow: 0 10px 30px rgba(27,42,74,.14); padding: 1.1rem 1rem 1rem; display: flex; flex-direction: column; gap: .55rem; transition: transform .6s var(--ease), opacity .5s; transform-origin: bottom center; }
.q-card[data-i="1"] { transform: scale(.94) translateY(14px); box-shadow: 0 4px 14px rgba(27,42,74,.1); }
.q-card.tilt-right { transform: translateX(40px) rotate(6deg); }
.q-card.tilt-left { transform: translateX(-40px) rotate(-6deg); }
.q-card.swipe-right { transform: translateX(140%) rotate(22deg); opacity: 0; }
.q-card.swipe-left { transform: translateX(-140%) rotate(-22deg); opacity: 0; }
.q-doc { font-size: .72rem; color: var(--muted); }
.q-line { font-size: .78rem; color: var(--ink); font-weight: 600; }
.q-text { font-size: 1.08rem; line-height: 1.4; color: var(--text); margin-top: .3rem; font-weight: 500; }
.q-why { font-size: .78rem; color: var(--muted); border-left: 3px solid var(--accent); padding-left: .5rem; }
.q-actions { margin-top: auto; display: flex; align-items: center; justify-content: space-between; }
.q-hint { font-size: .72rem; color: #adb5bd; }
.q-btn { width: 62px; height: 62px; border-radius: 50%; border: 2px solid; background: #fff; font-size: 1.6rem; font-weight: 700; cursor: pointer; transition: transform .25s var(--ease), background .25s, color .25s; box-shadow: 0 6px 16px rgba(0,0,0,.1); }
.q-btn.ja { color: var(--green); border-color: var(--green); }
.q-btn.nein { color: var(--red); border-color: var(--red); }
.q-btn.pressed { transform: scale(1.18); color: #fff; }
.q-btn.ja.pressed { background: var(--green); }
.q-btn.nein.pressed { background: var(--red); }
.q-stamp { position: absolute; top: 1rem; padding: .15rem .6rem; border: 4px solid; border-radius: 8px; font-size: 1.7rem; font-weight: 900; letter-spacing: .12em; opacity: 0; transition: opacity .25s, transform .3s var(--ease); z-index: 2; }
.q-stamp.ja { right: 1rem; color: var(--green); border-color: var(--green); transform: rotate(-16deg) scale(1.4); }
.q-stamp.nein { left: 1rem; color: var(--red); border-color: var(--red); transform: rotate(16deg) scale(1.4); }
.q-stamp.active { opacity: 1; transform: rotate(-16deg) scale(1); }
.q-stamp.nein.active { transform: rotate(16deg) scale(1); }
.phone-done { position: absolute; inset: 0; background: var(--bg); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .5rem; text-align: center; padding: 2rem; opacity: 0; transition: opacity .4s; pointer-events: none; }
.phone-done.show { opacity: 1; }
.phone-done .check { width: 120px; height: 120px; }
.phone-done strong { font-family: var(--serif); font-size: 1.8rem; color: var(--ink); font-weight: 400; margin-top: .5rem; }
.phone-done span { color: var(--muted); font-size: .9rem; line-height: 1.45; }
@media (max-height: 820px) { .phone { zoom: .85; } }
@media (max-width: 900px) { .phone-caption { display: none; } }
/* Beleg-Streifen bleibt beim Scrollen sichtbar, damit der Statuswechsel (gelb → grün) zu sehen ist */
.doc-strip { position: sticky; top: 4.6rem; z-index: 40; }
.strip-amount { white-space: nowrap; }
.doc-strip .muted { flex: 1; min-width: 0; }
