/* Unterseiten (Konfiguration, Auftrag, Anmeldung, Konto, Rechtliches, Meldungen) auf dem Niveau der Startseite.
   Gleiche Tokens wie base.css (tokens.css), keine eigenen Farben ausser Mischungen aus Tokens.
   Muster wie auf der Startseite: Ruhezustand grau und flach, beim Darueberfahren/Auswaehlen baut sich die Grafik auf.
   Ohne JavaScript bleibt alles bedienbar. Keine style-Attribute (CSP): dynamische Werte setzt flow.js per CSSOM. */

/* ---------------------------------------------------------------- Kopf und Navigation */
.nav a[aria-current="page"] { color: var(--accent); font-weight: 600; }
.nav .nav-cta { background: var(--accent); color: #fff; padding: 8px 18px; border-radius: var(--r-pill); font-weight: 600; transition: transform var(--t-fast) var(--ease), background var(--t-fast) var(--ease), box-shadow var(--t-fast) var(--ease); }
.nav .nav-cta:hover { background: var(--accent-strong); color: #fff; transform: translateY(-2px); box-shadow: 0 8px 20px rgba(27, 95, 209, .25); }

/* ---------------------------------------------------------------- Gemeinsame Bausteine */
.pg-head { margin-bottom: var(--s5); }
.pg-head h1 { margin-bottom: var(--s2); }
.pg-head .lede { margin-bottom: 0; }
.crumbs a { display: inline-flex; align-items: center; gap: 6px; text-decoration: none; color: var(--muted); transition: color var(--t-fast) var(--ease); }
.crumbs a:hover { color: var(--accent); }
.crumbs a .arrow { display: inline-block; transition: transform var(--t-fast) var(--ease); }
.crumbs a:hover .arrow { transform: translateX(-4px); }

.error, .notice { position: relative; padding-left: 48px; }
.error::before, .notice::before { position: absolute; left: 16px; top: 14px; width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; color: #fff; font: 700 .75rem/1 var(--font); }
.error::before { content: "!"; background: var(--err); }
.error { animation: nudge 420ms var(--ease) both; }
.notice::before { content: "i"; background: var(--accent); }
@keyframes nudge { 0% { transform: translateX(0); } 25% { transform: translateX(-6px); } 55% { transform: translateX(5px); } 80% { transform: translateX(-2px); } 100% { transform: none; } }

.btn[disabled], .btn.is-busy { cursor: progress; opacity: .85; transform: none; pointer-events: none; }
.btn.is-busy::before { content: ""; width: 16px; height: 16px; border-radius: 50%; border: 2.5px solid rgba(255, 255, 255, .45); border-top-color: #fff; animation: spin-busy 800ms linear infinite; }
.btn-secondary.is-busy::before { border-color: var(--line); border-top-color: var(--accent); }
@keyframes spin-busy { to { transform: rotate(360deg); } }

/* Aufklapper mit Pfeil */
.disclose > summary, .acc > summary { list-style: none; justify-content: space-between; gap: var(--s3); }
.disclose > summary::-webkit-details-marker, .acc > summary::-webkit-details-marker { display: none; }
.disclose > summary::after, .acc > summary::after { content: ""; flex: none; width: 9px; height: 9px; border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted); transform: rotate(45deg); transition: transform var(--t-base) var(--ease), border-color var(--t-base) var(--ease); margin-right: 4px; }
.disclose[open] > summary::after, .acc[open] > summary::after { transform: rotate(-135deg); }
.disclose > summary:hover::after, .acc > summary:hover::after { border-color: var(--accent); }
.disclose > summary:hover, .acc > summary:hover { color: var(--accent); }
.disclose[open] > :not(summary), .acc[open] > :not(summary) { animation: rise var(--t-base) var(--ease) both; }

/* ---------------------------------------------------------------- Konfiguration */
.page-narrow { padding-top: var(--s6); }
.cfg-title { margin-bottom: var(--s5); }
.cfg-title h1 { font-size: var(--fs-h2); }
.cfg-title .tkr { display: inline-flex; align-items: center; min-height: 28px; padding: 2px 12px; border-radius: var(--r-pill); background: var(--accent-soft); color: var(--accent-strong); font: 600 .875rem var(--font-mono); }

.cfg-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-card); padding: var(--s5); box-shadow: var(--shadow-1); margin-bottom: var(--s4); transition: box-shadow var(--t-base) var(--ease), border-color var(--t-base) var(--ease), transform var(--t-base) var(--ease), opacity var(--t-slow) var(--ease); }
.cfg-card:hover, .cfg-card:focus-within { border-color: #C3D3F0; box-shadow: var(--shadow-2); }
.cfg-head { display: flex; align-items: center; gap: var(--s3); margin-bottom: var(--s4); }
.cfg-head h2 { margin: 0; font-size: 1.125rem; }
.page-narrow form { counter-reset: cfg; }
.cfg-card:not([hidden]) { counter-increment: cfg; }
.cfg-no::before { content: counter(cfg); }
.cfg-no { flex: none; width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent); font: 650 .875rem var(--font-mono); transition: background var(--t-base) var(--ease), color var(--t-base) var(--ease), transform var(--t-base) var(--ease); }
.cfg-card:hover .cfg-no, .cfg-card:focus-within .cfg-no { background: var(--accent); color: #fff; transform: scale(1.1); }
.cfg-meta { margin-left: auto; font-size: var(--fs-small); color: var(--muted); white-space: nowrap; }
.cfg-meta b { color: var(--ink); font-family: var(--font-mono); font-weight: 650; }
.cfg-card > .small { margin: var(--s3) 0 0; }
.cfg-card .lead { margin: 0 0 var(--s4); color: var(--muted); font-size: .9375rem; }
.cfg-card .disclose:first-of-type { margin-top: var(--s4); }
.cfg-card[data-detail]:not([hidden]) { animation: rise var(--t-slow) var(--ease) both; }

.chip { transition: background var(--t-base) var(--ease), box-shadow var(--t-base) var(--ease), transform var(--t-fast) var(--ease); }
.chip:hover { transform: translateY(-2px); box-shadow: inset 0 0 0 1.5px #B9CBEC; }
.chip:has(input:checked):hover { box-shadow: inset 0 0 0 1.5px var(--accent), 0 6px 14px rgba(27, 95, 209, .14); }
.chip:active { transform: scale(.97); }

/* Formatkarten: kleine Dokument-Grafik, grau im Ruhezustand, farbig und aufgebaut bei Hover/Auswahl */
.format-card { padding: var(--s4) var(--s4) var(--s3); transition: box-shadow var(--t-base) var(--ease), background var(--t-base) var(--ease), transform var(--t-base) var(--ease); }
.format-card:hover { transform: translateY(-4px) scale(1.02); box-shadow: inset 0 0 0 1.5px #B9CBEC, var(--shadow-2); }
.format-card:has(input:checked):hover { box-shadow: inset 0 0 0 2px var(--accent), var(--shadow-2); }
.format-card strong { margin-bottom: 2px; }
.fmt { position: relative; display: block; border-radius: 8px; background: #fff; box-shadow: inset 0 0 0 1.5px var(--line); margin-bottom: var(--s3); overflow: hidden; filter: grayscale(1); opacity: .8; transition: filter var(--t-base) var(--ease), opacity var(--t-base) var(--ease), box-shadow var(--t-base) var(--ease); }
.fmt.wide { width: 68px; height: 42px; }
.fmt.tall { width: 44px; height: 56px; }
.fmt i { position: absolute; display: block; background: var(--accent); border-radius: 2px; transform-origin: bottom; }
.fmt .t { left: 7px; top: 7px; width: 22px; height: 3px; background: var(--ink); opacity: .75; }
.fmt .b1, .fmt .b2, .fmt .b3 { bottom: 7px; width: 6px; transform: scaleY(.28); transition: transform var(--t-base) var(--ease); }
.fmt .b1 { left: 8px; height: 13px; }
.fmt .b2 { left: 17px; height: 19px; background: var(--cyan); }
.fmt .b3 { left: 26px; height: 25px; background: var(--indigo); }
.fmt.wide .r { right: 8px; bottom: 7px; width: 17px; height: 17px; border-radius: 50%; background: none; border: 3.5px solid var(--accent); border-right-color: var(--accent-soft); transform: rotate(-60deg) scale(.7); transition: transform var(--t-slow) var(--ease); }
.fmt.tall .t { left: 6px; width: 20px; }
.fmt.tall .r { left: 6px; top: 14px; width: 30px; height: 3px; background: var(--line); transform: scaleX(.3); transform-origin: left; transition: transform var(--t-base) var(--ease); }
.fmt.tall .b1 { left: 7px; } .fmt.tall .b2 { left: 16px; } .fmt.tall .b3 { left: 25px; }
.format-card:hover .fmt, .format-card:has(input:checked) .fmt, .format-card:has(input:focus-visible) .fmt { filter: none; opacity: 1; box-shadow: inset 0 0 0 1.5px var(--accent); }
.format-card:hover .fmt i, .format-card:has(input:checked) .fmt i { transform: none; }
.format-card:hover .fmt .b1, .format-card:has(input:checked) .fmt .b1 { animation: pg-grow 640ms var(--ease) backwards; }
.format-card:hover .fmt .b2, .format-card:has(input:checked) .fmt .b2 { animation: pg-grow 640ms var(--ease) 90ms backwards; }
.format-card:hover .fmt .b3, .format-card:has(input:checked) .fmt .b3 { animation: pg-grow 640ms var(--ease) 180ms backwards; }
.format-card:hover .fmt.wide .r, .format-card:has(input:checked) .fmt.wide .r { transform: rotate(-60deg) scale(1); animation: pg-ring 900ms var(--ease) 240ms backwards; }
.format-card:hover .fmt.tall .r, .format-card:has(input:checked) .fmt.tall .r { transform: none; animation: pg-line 600ms var(--ease) 120ms backwards; }
@keyframes pg-grow { from { transform: scaleY(.1); } }
@keyframes pg-ring { from { transform: rotate(-260deg) scale(.4); opacity: 0; } }
@keyframes pg-line { from { transform: scaleX(0); } }
.format-card .tick-corner { position: absolute; top: 12px; right: 12px; width: 22px; height: 22px; border-radius: 50%; box-shadow: inset 0 0 0 1.5px var(--line); display: grid; place-items: center; transition: background var(--t-base) var(--ease), box-shadow var(--t-base) var(--ease); }
.format-card .tick-corner svg { width: 12px; height: 12px; stroke: #fff; fill: none; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 20; stroke-dashoffset: 20; transition: stroke-dashoffset var(--t-base) var(--ease); }
.format-card:has(input:checked) .tick-corner { background: var(--accent); box-shadow: none; }
.format-card:has(input:checked) .tick-corner svg { stroke-dashoffset: 0; }
.format-grid.two { grid-template-columns: repeat(2, 1fr); }

/* Eigene Daten: Ablageflaeche */
.dz { position: relative; display: grid; justify-items: center; gap: var(--s2); text-align: center; border: 2px dashed #C5CFDF; border-radius: var(--r-card); padding: var(--s6) var(--s4); background: var(--surface); cursor: pointer; transition: border-color var(--t-base) var(--ease), background var(--t-base) var(--ease), transform var(--t-base) var(--ease); margin-bottom: var(--s4); }
.dz:hover, .dz.over, .dz:focus-within { border-color: var(--accent); background: var(--accent-soft); }
.dz.over { transform: scale(1.015); }
.dz svg { width: 38px; height: 38px; stroke: var(--accent); fill: none; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; transition: transform var(--t-base) var(--ease); }
.dz:hover svg, .dz.over svg { transform: translateY(-5px); }
.dz strong { font-weight: 650; }
.dz .small { margin: 0; }
.dz input[type=file] { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; padding: 0; }
.dz:focus-within { box-shadow: var(--ring); }
.flist { display: grid; gap: var(--s2); margin: 0 0 var(--s4); padding: 0; list-style: none; }
.file-chip { border-radius: var(--r-field); background: var(--surface); box-shadow: inset 0 0 0 1.5px var(--line); padding: 10px var(--s4); margin: 0; animation: rise var(--t-base) var(--ease) both; }
.file-chip.new { background: var(--accent-soft); box-shadow: inset 0 0 0 1.5px #B9CBEC; }
.file-chip.bad { background: var(--err-soft); box-shadow: inset 0 0 0 1.5px #F0C4C0; color: var(--err); }
.file-chip .nm { display: flex; flex-direction: column; min-width: 0; overflow-wrap: anywhere; }
.file-chip .nm b { font-weight: 600; }
.file-chip .small { color: inherit; opacity: .8; }
.file-chip button.link { color: var(--accent-strong); flex: none; font-size: var(--fs-small); }
.file-chip.bad button.link { color: var(--err); }
textarea { transition: border-color var(--t-fast) var(--ease), box-shadow var(--t-fast) var(--ease); }
.count-note { text-align: right; margin: 6px 0 0; }

/* Hinweise zum Ablauf */
.info-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--s3); margin: 0 0 var(--s3); padding: 0; list-style: none; }
.info-grid li { display: flex; gap: var(--s3); align-items: flex-start; padding: var(--s3) var(--s4); border-radius: var(--r-field); background: var(--paper); border: 1px solid var(--line); font-size: .9375rem; line-height: 1.45; transition: background var(--t-base) var(--ease), border-color var(--t-base) var(--ease), transform var(--t-base) var(--ease), box-shadow var(--t-base) var(--ease); }
.info-grid li:hover { background: #fff; border-color: #C3D3F0; transform: translateY(-2px); box-shadow: var(--shadow-1); }
.info-grid svg { flex: none; width: 22px; height: 22px; margin-top: 1px; stroke: var(--muted); fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; transition: stroke var(--t-base) var(--ease), transform var(--t-base) var(--ease); }
.info-grid li:hover svg { stroke: var(--accent); transform: scale(1.12) rotate(-6deg); }
.info-grid b { display: block; font-weight: 650; }
.info-grid span { color: var(--muted); }

.avail { display: inline-flex; align-items: center; gap: 8px; padding: 6px 14px; border-radius: var(--r-pill); background: var(--ok-soft); color: var(--ok); font-weight: 600; font-size: .875rem; }
.avail.low { background: #FBEFE3; color: var(--warn); }
.avail::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: currentColor; }

.summary-line { bottom: 12px; margin: var(--s5) 0 0; border: 1px solid var(--line); border-radius: 20px; box-shadow: var(--shadow-2); background: rgba(255, 255, 255, .96); padding: var(--s3) var(--s4); }
.summary-line .sum { text-decoration: none; color: var(--ink); text-align: left; font-weight: 600; line-height: 1.35; flex: 1 1 260px; min-width: 0; }
.summary-line .sum small { display: block; font-weight: 400; color: var(--muted); font-size: .8125rem; }
.summary-line .sum:hover { color: var(--accent); }

/* ---------------------------------------------------------------- Auftrag */
.page-job { width: min(100% - 32px, var(--w-tool)); margin-inline: auto; padding: var(--s6) 0 0; }
.job-card { position: relative; overflow: hidden; padding: var(--s6); margin-top: 0; border-radius: 24px; box-shadow: var(--shadow-2); }
.job-card::before { content: ""; position: absolute; width: 380px; height: 380px; right: -160px; top: -200px; border-radius: 50%; background: radial-gradient(circle, rgba(27, 95, 209, .16), transparent 68%); pointer-events: none; }
.job-card > * { position: relative; }
.job-head { margin-bottom: var(--s4); align-items: flex-start; }
.job-head h1 { font-size: var(--fs-h3); }
.job-head .fmt-pill { padding: 4px 14px; border-radius: var(--r-pill); background: var(--accent-soft); color: var(--accent-strong); font-weight: 600; font-size: .875rem; white-space: nowrap; }
.job-meter { display: flex; align-items: flex-end; justify-content: space-between; gap: var(--s4); margin-bottom: var(--s3); flex-wrap: wrap; }
.pct { font: 650 clamp(3rem, 2rem + 4vw, 4.5rem)/.9 var(--font); letter-spacing: -.045em; color: var(--ink); }
.pct small { font-size: .38em; letter-spacing: 0; color: var(--muted); margin-left: 4px; font-weight: 600; }
.job-time { text-align: right; font-size: var(--fs-small); color: var(--muted); line-height: 1.5; }
.job-time b { font-family: var(--font-mono); font-weight: 650; color: var(--ink); }
.job-card progress { height: 12px; margin-bottom: var(--s3); }
.job-now { min-height: 1.6em; margin-bottom: var(--s5); color: var(--ink); font-weight: 500; }
.conn { display: flex; gap: var(--s2); align-items: center; padding: var(--s2) var(--s3); margin: 0 0 var(--s4); border-radius: var(--r-field); background: #FBEFE3; color: var(--warn); font-size: .9375rem; }
.conn[hidden] { display: none; }

.phases { gap: var(--s3); margin-bottom: var(--s5); padding-top: var(--s4); border-top: 1px solid var(--line); }
.phases li { position: relative; align-items: flex-start; min-height: 32px; padding: 3px 0; flex-wrap: wrap; row-gap: 0; transition: color var(--t-base) var(--ease); }
.phases li > span:last-child { flex: 1; min-width: 0; padding-top: 1px; }
.phases li:not(:last-child)::after { content: ""; position: absolute; left: 11px; top: 30px; height: calc(100% - 12px); width: 2px; background: var(--line); transition: background var(--t-slow) var(--ease); }
.phases li.done:not(:last-child)::after { background: var(--ok); }
.phases .dot { margin-top: 3px; position: relative; z-index: 1; background: var(--surface); }
.phases li.done .dot { background: var(--ok); }
.phases li.now .dot { background: var(--accent-soft); }
.phases .ph-hint { display: none; font-size: var(--fs-small); color: var(--muted); font-weight: 400; margin-top: 2px; }
.phases li.now .ph-hint { display: block; animation: rise var(--t-base) var(--ease) both; }
.phases li:hover { color: var(--ink); }
.phases li:hover .dot { box-shadow: inset 0 0 0 2px var(--accent); }
.phases li.done:hover .dot { box-shadow: none; }

.job-foot { display: grid; gap: var(--s2); padding: var(--s4); border-radius: var(--r-field); background: var(--paper); border: 1px solid var(--line); font-size: .9375rem; }
.job-foot p { margin: 0; }
.job-foot .small { margin: 0; }

.result-card { text-align: left; padding: var(--s6); border-radius: 24px; box-shadow: var(--shadow-2); border-color: #BFE3D3; background: linear-gradient(180deg, var(--ok-soft), var(--surface) 55%); }
.result-card h1 { font-size: var(--fs-h2); margin-bottom: var(--s2); }
.result-meta { display: flex; flex-wrap: wrap; gap: var(--s2); margin: 0 0 var(--s5); padding: 0; list-style: none; }
.result-meta li { padding: 4px 14px; border-radius: var(--r-pill); background: var(--surface); border: 1px solid var(--line); font-size: .875rem; color: var(--muted); }
.result-meta li b { color: var(--ink); font-weight: 600; }
.result-actions { display: flex; flex-wrap: wrap; gap: var(--s3); align-items: center; margin-bottom: var(--s4); }
.result-actions .btn { margin: 0; }
.result-card .link.small { color: var(--muted); }
.result-card .link.small:hover { color: var(--err); }
.result-card form { margin: var(--s3) 0 0; }
.gate { display: flex; gap: var(--s3); align-items: flex-start; padding: var(--s4); border-radius: var(--r-field); background: var(--accent-soft); margin: 0 0 var(--s4); font-size: .9375rem; }
.gate svg { flex: none; width: 22px; height: 22px; margin-top: 1px; stroke: var(--accent); fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.gate p { margin: 0; }
.fail-card { padding: var(--s6); border-radius: 24px; }
.fail-card h1 { font-size: var(--fs-h3); }
.fail-card .why { padding: var(--s3) var(--s4); border-radius: var(--r-field); background: rgba(255, 255, 255, .7); margin: 0 0 var(--s4); }
.fail-card .btn-row, .gone-card .btn-row { display: flex; flex-wrap: wrap; gap: var(--s3); }

/* Seitenansicht des Ergebnisses */
.viewer { margin-top: var(--s5); }
.viewer[hidden] { display: none; }
.v-stage { position: relative; border-radius: var(--r-card); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-2); overflow: hidden; }
.v-stage img { display: block; width: 100%; height: auto; cursor: zoom-in; animation: v-in 420ms var(--ease) both; }
@keyframes v-in { from { opacity: 0; transform: scale(.985); } }
.v-nav { position: absolute; top: 50%; width: 44px; height: 44px; margin-top: -22px; border: 0; border-radius: 50%; background: rgba(255, 255, 255, .94); box-shadow: var(--shadow-2); font-size: 1.25rem; color: var(--ink); cursor: pointer; transition: transform var(--t-fast) var(--ease), background var(--t-fast) var(--ease), color var(--t-fast) var(--ease), opacity var(--t-base) var(--ease); }
.v-nav:hover { background: var(--accent); color: #fff; transform: scale(1.1); }
.v-prev { left: 12px; } .v-next { right: 12px; }
.v-nav[disabled] { opacity: 0; pointer-events: none; }
.v-bar { display: flex; align-items: center; justify-content: space-between; gap: var(--s3); margin: var(--s3) 0; font-size: var(--fs-small); color: var(--muted); }
.v-bar b { color: var(--ink); font-family: var(--font-mono); }
.v-bar button { background: none; border: 0; padding: 6px 4px; color: var(--accent); font: 600 .875rem var(--font); cursor: pointer; }
.v-bar button:hover { color: var(--accent-strong); text-decoration: underline; text-underline-offset: 3px; }
.v-thumbs { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: var(--s2); }
.v-thumb { position: relative; padding: 0; border: 0; border-radius: 8px; overflow: hidden; background: #fff; cursor: pointer; box-shadow: inset 0 0 0 1px var(--line), var(--shadow-1); filter: grayscale(1); opacity: .65; transition: filter var(--t-base) var(--ease), opacity var(--t-base) var(--ease), transform var(--t-base) var(--ease), box-shadow var(--t-base) var(--ease); }
.v-thumb img { display: block; width: 100%; height: auto; }
.v-thumb:hover { filter: none; opacity: 1; transform: translateY(-4px) scale(1.04); box-shadow: 0 0 0 2px var(--accent), var(--shadow-2); z-index: 2; }
.v-thumb[aria-current="true"] { filter: none; opacity: 1; box-shadow: 0 0 0 2.5px var(--accent), var(--shadow-1); }
.viewer.full { position: fixed; inset: 0; z-index: 95; margin: 0; padding: var(--s4); background: rgba(15, 27, 45, .94); display: flex; flex-direction: column; }
.viewer.full .v-stage { flex: 1; min-height: 0; display: grid; place-items: center; background: transparent; border: 0; box-shadow: none; }
.viewer.full .v-stage img { width: auto; max-width: 100%; max-height: calc(100vh - 150px); border-radius: 10px; background: #fff; cursor: zoom-out; }
.viewer.full .v-bar { color: var(--on-dark-muted); } .viewer.full .v-bar b { color: #fff; } .viewer.full .v-bar button { color: #fff; }
.viewer.full .v-thumbs { display: none; }
html.js .result-pages.is-viewer { display: none; }

/* ---------------------------------------------------------------- Anmeldung, Registrierung, Meldungen */
.auth { width: min(100% - 32px, 940px); margin: var(--s7) auto 0; display: grid; grid-template-columns: 5fr 6fr; border-radius: 28px; overflow: hidden; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-2); }
.auth-side { position: relative; overflow: hidden; padding: var(--s7) var(--s6); color: var(--on-dark); background: linear-gradient(160deg, var(--ink), var(--ink-2) 55%, #0B2A5B); }
.auth-side::before { content: ""; position: absolute; width: 420px; height: 420px; right: -180px; top: -200px; border-radius: 50%; background: radial-gradient(circle, rgba(63, 167, 214, .38), transparent 66%); animation: drift 24s var(--ease) infinite alternate; }
.auth-side > * { position: relative; }
.auth-side .brand-mark { fill: #fff; width: 30px; height: 30px; margin-bottom: var(--s5); }
.auth-side h2 { color: #fff; font-size: var(--fs-h3); margin-bottom: var(--s3); }
.auth-side p { color: var(--on-dark-muted); font-size: .9375rem; }
.auth-side ul { list-style: none; margin: var(--s5) 0 0; padding: 0; display: grid; gap: var(--s3); }
.auth-side li { display: flex; gap: var(--s3); align-items: flex-start; font-size: .9375rem; line-height: 1.45; animation: rise var(--t-slow) var(--ease) both; }
.auth-side li:nth-child(1) { animation-delay: 250ms; } .auth-side li:nth-child(2) { animation-delay: 350ms; } .auth-side li:nth-child(3) { animation-delay: 450ms; } .auth-side li:nth-child(4) { animation-delay: 550ms; }
.auth-side li .tk { flex: none; width: 22px; height: 22px; border-radius: 50%; background: rgba(255, 255, 255, .14); display: grid; place-items: center; transition: background var(--t-base) var(--ease), transform var(--t-base) var(--ease); }
.auth-side li:hover .tk { background: var(--cyan); transform: scale(1.15); }
.auth-side li .tk svg { width: 12px; height: 12px; stroke: #fff; fill: none; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.auth-main { padding: var(--s7) var(--s6); }
.auth-main h1 { font-size: var(--fs-h3); margin-bottom: var(--s2); }
.auth-main > .small { margin-bottom: var(--s5); }
.auth-main .btn { width: 100%; margin-top: var(--s2); }
.auth-alt { margin: var(--s5) 0 0; padding-top: var(--s4); border-top: 1px solid var(--line); font-size: .9375rem; color: var(--muted); display: flex; justify-content: space-between; gap: var(--s3); flex-wrap: wrap; }
.auth-alt a { font-weight: 600; text-decoration: none; }
.auth-alt a:hover { text-decoration: underline; text-underline-offset: 3px; }

.auth-card { margin-top: var(--s7); }
.auth-card .card { padding: var(--s6); border-radius: 24px; box-shadow: var(--shadow-2); }
.auth-card .btn { width: 100%; }
.auth-card .btn + .btn { margin-top: var(--s2); }
.msg-ico { width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; margin-bottom: var(--s4); background: var(--accent-soft); }
.msg-ico svg { width: 28px; height: 28px; stroke: var(--accent); fill: none; stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 40; stroke-dashoffset: 40; animation: draw var(--t-slow) var(--ease) .2s forwards; }
.msg-ico.ok { background: var(--ok); } .msg-ico.ok svg { stroke: #fff; }
.msg-ico.bad { background: var(--err-soft); } .msg-ico.bad svg { stroke: var(--err); }
.message-card .btn-row { display: grid; gap: var(--s2); }
.message-card .btn-row .btn { margin: 0; }
.message-card p { color: var(--muted); }

.pw { position: relative; display: block; }
.field > .pw { margin-bottom: 0; }
.pw input { padding-right: 96px; }
.pw-toggle { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); border: 0; background: none; color: var(--accent); font: 600 .875rem var(--font); cursor: pointer; padding: 8px 12px; border-radius: var(--r-pill); min-height: 36px; transition: background var(--t-fast) var(--ease); }
.pw-toggle:hover { background: var(--accent-soft); }
.strength { margin: var(--s2) 0 var(--s1); }
.strength-text { display: flex; justify-content: space-between; gap: var(--s3); margin: 0 0 var(--s4); font-size: .8125rem; color: var(--muted); min-height: 1.3em; }
.strength-text b { font-weight: 600; color: var(--ink); }
.field.invalid input { border-color: var(--err); }
.field .hint { display: none; margin-top: 6px; font-size: .8125rem; font-weight: 400; color: var(--err); }
.field.invalid .hint { display: block; animation: rise var(--t-base) var(--ease) both; }
input:user-invalid { border-color: var(--err); }

/* ---------------------------------------------------------------- Konto */
.page-top { padding-top: var(--s6); }
.acct-head { display: flex; align-items: flex-end; justify-content: space-between; gap: var(--s4); flex-wrap: wrap; margin-bottom: var(--s5); }
.acct-head h1 { margin: 0 0 var(--s2); }
.acct-mail { display: inline-flex; align-items: center; gap: var(--s2); flex-wrap: wrap; font-size: .9375rem; color: var(--muted); }
.badge { display: inline-flex; align-items: center; gap: 6px; padding: 3px 12px; border-radius: var(--r-pill); font-size: .8125rem; font-weight: 600; background: var(--ok-soft); color: var(--ok); }
.badge.warn { background: #FBEFE3; color: var(--warn); }
.badge::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.stat-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--s3); margin-bottom: var(--s4); }
.stat { position: relative; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-card); padding: var(--s5); box-shadow: var(--shadow-1); overflow: hidden; transition: transform var(--t-base) var(--ease), box-shadow var(--t-base) var(--ease), border-color var(--t-base) var(--ease); }
.stat .big { display: block; font: 650 3rem/1 var(--font); letter-spacing: -.04em; color: var(--muted); margin-bottom: var(--s2); transition: color var(--t-base) var(--ease); }
.stat .lbl { font-weight: 600; display: block; }
.stat .small { display: block; margin-top: 2px; }
.stat .bar { display: flex; gap: 3px; align-items: flex-end; height: 28px; position: absolute; right: var(--s5); top: var(--s5); }
.stat .bar i { display: block; width: 7px; border-radius: 2px; background: var(--line); transform-origin: bottom; transform: scaleY(.35); transition: background var(--t-base) var(--ease), transform var(--t-base) var(--ease); }
.stat .bar i:nth-child(1) { height: 10px; } .stat .bar i:nth-child(2) { height: 17px; } .stat .bar i:nth-child(3) { height: 22px; } .stat .bar i:nth-child(4) { height: 28px; }
.stat:hover { transform: translateY(-4px) scale(1.03); border-color: var(--accent); box-shadow: 0 24px 56px rgba(20, 73, 168, .22), 0 0 0 1px var(--accent); }
.stat:hover .big { color: var(--accent); }
.stat:hover .bar i { background: var(--accent); transform: none; animation: pg-grow 640ms var(--ease) backwards; }
.stat:hover .bar i:nth-child(2) { animation-delay: 70ms; } .stat:hover .bar i:nth-child(3) { animation-delay: 140ms; } .stat:hover .bar i:nth-child(4) { animation-delay: 210ms; }
.stat-grid:has(.stat:hover) .stat:not(:hover) { opacity: .7; }
.acct-actions { margin: 0 0 var(--s5); }
.acc { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-card); padding: 0 var(--s5); margin-bottom: var(--s3); box-shadow: var(--shadow-1); transition: border-color var(--t-base) var(--ease), box-shadow var(--t-base) var(--ease); }
.acc:hover, .acc[open] { border-color: #C3D3F0; }
.acc > summary { cursor: pointer; font-weight: 600; min-height: 60px; display: flex; align-items: center; }
.acc > summary small { font-weight: 400; color: var(--muted); margin-left: var(--s2); }
.acc form { padding-bottom: var(--s5); max-width: 460px; }
.acc .btn { width: auto; }
.acc.danger { background: transparent; box-shadow: none; border-color: #F0C4C0; }
.acc.danger > summary { color: var(--err); }
.acc.danger p { margin: 0 0 var(--s3); color: var(--muted); font-size: .9375rem; }
.buy-card { position: sticky; top: 84px; border-radius: 24px; padding: var(--s6); box-shadow: var(--shadow-2); }
.buy-card h2 { font-size: var(--fs-h3); margin-bottom: var(--s2); }
.buy-card .lead { margin: 0 0 var(--s4); color: var(--muted); font-size: .9375rem; }
.packs { display: grid; gap: var(--s2); margin-bottom: var(--s3); }
.pack { position: relative; display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 2px var(--s4); padding: var(--s3) var(--s4) var(--s3) 52px; border-radius: var(--r-field); background: var(--surface); box-shadow: inset 0 0 0 1.5px var(--line); cursor: pointer; transition: box-shadow var(--t-base) var(--ease), background var(--t-base) var(--ease), transform var(--t-base) var(--ease); }
.pack:hover { transform: translateY(-2px) scale(1.01); box-shadow: inset 0 0 0 1.5px #B9CBEC, var(--shadow-1); }
.pack input { position: absolute; left: 16px; top: 50%; margin-top: -10px; }
.pack b { font-size: 1.0625rem; font-weight: 650; white-space: nowrap; }
.pack .px { font: 650 1rem var(--font); letter-spacing: -.02em; text-align: right; }
.pack .sub { grid-column: 1 / -1; font-size: var(--fs-small); color: var(--muted); }
.pack .coins { display: flex; gap: 3px; margin-top: 4px; }
.pack .coins i { display: block; width: 9px; height: 9px; border-radius: 50%; background: var(--line); transition: background var(--t-base) var(--ease), transform var(--t-base) var(--ease); }
.pack:hover .coins i, .pack:has(input:checked) .coins i { background: var(--accent); }
.pack:hover .coins i { animation: pg-pop 420ms var(--ease) backwards; }
.pack:hover .coins i:nth-child(2) { animation-delay: 50ms; } .pack:hover .coins i:nth-child(3) { animation-delay: 100ms; } .pack:hover .coins i:nth-child(4) { animation-delay: 150ms; } .pack:hover .coins i:nth-child(5) { animation-delay: 200ms; }
@keyframes pg-pop { from { transform: scale(0); } }
.pack:has(input:checked) { background: var(--accent-soft); box-shadow: inset 0 0 0 2px var(--accent); }
.pack:has(input:focus-visible) { box-shadow: inset 0 0 0 2px var(--accent), var(--ring); }
.buy-card .check { font-size: .875rem; line-height: 1.45; }
.buy-card .btn { width: 100%; margin-top: var(--s3); }
.buy-note { font-size: var(--fs-small); color: var(--muted); margin: var(--s3) 0 0; text-align: center; }
.page-narrow .buy-card { position: static; }

/* ---------------------------------------------------------------- Rechtliches */
.legal-shell { width: min(100% - 32px, 820px); margin: var(--s6) auto 0; }
.legal-tabs { display: flex; flex-wrap: wrap; gap: var(--s1); padding: 4px; background: var(--surface); border-radius: var(--r-pill); box-shadow: inset 0 0 0 1px var(--line); margin-bottom: var(--s5); width: fit-content; max-width: 100%; }
.legal-tabs a { padding: 9px 18px; border-radius: var(--r-pill); color: var(--muted); text-decoration: none; font-weight: 600; font-size: .9375rem; min-height: 40px; display: inline-flex; align-items: center; transition: background var(--t-base) var(--ease), color var(--t-base) var(--ease); }
.legal-tabs a:hover { background: var(--accent-soft); color: var(--accent-strong); }
.legal-tabs a[aria-current="page"] { background: var(--accent); color: #fff; }
.legal { width: 100%; margin: 0; padding: var(--s6) var(--s7); background: var(--surface); border: 1px solid var(--line); border-radius: 24px; box-shadow: var(--shadow-1); line-height: 1.7; }
.legal h1 { font-size: var(--fs-h2); hyphens: auto; -webkit-hyphens: auto; }
.legal { overflow-wrap: break-word; }
.legal h2 { font-size: 1.25rem; margin-top: var(--s6); padding-top: var(--s4); border-top: 1px solid var(--line); scroll-margin-top: 88px; }
.legal h1 + .notice + h2, .legal h1 + h2 { border-top: 0; margin-top: var(--s5); padding-top: 0; }
.legal p, .legal li { color: #243247; }
.legal ul { padding-left: 1.2em; }
.legal ul.toc { padding-left: 0; }
.legal .notice { background: #FBEFE3; color: #6B3306; line-height: 1.5; }
.legal .notice::before { background: var(--warn); }
.legal mark.ph { background: #FFF1B8; color: #4A3A00; border-radius: 4px; padding: 0 3px; }
.toc { display: flex; flex-wrap: wrap; gap: var(--s2); margin: var(--s4) 0 var(--s5); padding: 0; list-style: none; }
.toc a { display: inline-block; padding: 6px 14px; border-radius: var(--r-pill); background: var(--paper); border: 1px solid var(--line); font-size: .875rem; color: var(--ink); text-decoration: none; transition: background var(--t-fast) var(--ease), color var(--t-fast) var(--ease), border-color var(--t-fast) var(--ease), transform var(--t-fast) var(--ease); }
.toc a:hover, .toc a.on { background: var(--accent); border-color: var(--accent); color: #fff; transform: translateY(-2px); }
.to-top { position: fixed; right: 20px; bottom: 24px; z-index: 50; width: 46px; height: 46px; border: 0; border-radius: 50%; background: var(--ink); color: #fff; font-size: 1.125rem; cursor: pointer; box-shadow: var(--shadow-2); opacity: 0; transform: translateY(12px); pointer-events: none; transition: opacity var(--t-base) var(--ease), transform var(--t-base) var(--ease), background var(--t-fast) var(--ease); }
.to-top.show { opacity: 1; transform: none; pointer-events: auto; }
.to-top:hover { background: var(--accent); }

/* ---------------------------------------------------------------- Assistent (alter Ablauf) */
.steps { gap: var(--s2); margin-bottom: var(--s5); }
.steps li { padding: 6px 14px; border-radius: var(--r-pill); background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); }
.steps li.on { background: var(--accent); color: #fff; }
.steps li a { text-decoration: none; }

/* ---------------------------------------------------------------- Kleine Bildschirme */
@media (max-width: 860px) {
  .auth { grid-template-columns: 1fr; margin-top: var(--s5); }
  .auth-side { padding: var(--s5); }
  .auth-side ul { margin-top: var(--s4); }
  .auth-side .brand-mark { margin-bottom: var(--s3); width: 24px; height: 24px; }
  .auth-main { padding: var(--s5); }
  .legal { padding: var(--s5); }
  .legal h1 { font-size: 1.625rem; }
  .buy-card { position: static; }
  .info-grid, .stat-grid { grid-template-columns: 1fr; }
  .format-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 560px) {
  .acc > summary small { display: none; }
  .pack { grid-template-columns: auto 1fr; padding-right: var(--s3); }
  .pack .px { font-size: .9375rem; }
  .cfg-card { padding: var(--s4); }
  .cfg-meta { display: none; }
  .summary-line { margin-inline: 0; }
  .summary-line .cfg-actions { width: 100%; }
  .summary-line .cfg-actions .btn { flex: 1; }
  .job-card, .result-card, .fail-card { padding: var(--s5) var(--s4); }
  .job-time { text-align: left; }
  .legal-tabs { border-radius: 18px; }
  .legal-tabs a { padding: 8px 12px; }
  .v-thumbs { grid-template-columns: repeat(auto-fill, minmax(72px, 1fr)); }
  .v-nav { width: 38px; height: 38px; margin-top: -19px; }
}

@media (prefers-reduced-motion: reduce) {
  .format-card:hover, .stat:hover, .pack:hover, .info-grid li:hover, .v-thumb:hover, .chip:hover, .toc a:hover { transform: none; }
  .fmt i, .stat .bar i { transform: none; }
  .fmt .r { transform: none !important; }
  .btn.is-busy::before { animation: none !important; border-top-color: #fff; }
  .msg-ico svg { stroke-dashoffset: 0; }
}

/* Datenbericht (Dashboard und Ergebnisseite) */
.data-report { margin: 18px 0 0; padding: 18px 20px; border: 1px solid #dbe3f1; border-radius: 16px; background: #fbfcff; text-align: left; }
.data-report .rp-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.data-report h2 { margin: 0; font-size: 1.1rem; }
.data-report h3 { margin: 14px 0 6px; font-size: .95rem; }
.rp-badge { padding: 4px 12px; border-radius: 999px; font: 600 .8rem var(--font, system-ui); background: #e7f3ec; color: #1d6b3c; }
.rp-hinweise .rp-badge { background: #fff4d9; color: #7a5a00; }
.rp-luecken .rp-badge { background: #eef1f6; color: #3d4a63; }
.rp-lede { margin: 10px 0 12px; color: #3d4a63; }
.rp-counts { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 8px 16px; list-style: none; margin: 0; padding: 0; font-size: .9rem; color: #4a5671; }
.rp-counts b { font-size: 1.15rem; color: var(--ink, #14213d); margin-right: 4px; }
.rp-block ul, .rp-log ul { margin: 0; padding-left: 20px; font-size: .92rem; }
.rp-block li, .rp-log li { margin: 4px 0; }
.rp-tips { background: #eef4ff; border-radius: 12px; padding: 4px 14px 10px; margin-top: 14px; }
.rp-log { margin-top: 12px; font-size: .92rem; }
.rp-log summary { cursor: pointer; font-weight: 600; color: var(--accent-strong, #1b5fd1); }
.rp-problem { color: #7a4a00; }

/* Persoenliche Vorlage: haeufig genutzte Felder in der Konfiguration */
.chip.freq, .format-card.freq { box-shadow: inset 0 0 0 1.5px rgba(27, 95, 209, .55); background: rgba(232, 240, 253, .6); }
.format-card.freq { position: relative; }
.freq-tag { display: inline-block; margin-left: 6px; padding: 1px 8px; border-radius: 999px; background: #1b5fd1; color: #fff; font: 600 .68rem var(--font, system-ui); letter-spacing: .02em; vertical-align: middle; }
.format-card .freq-tag { position: absolute; top: 8px; right: 8px; margin: 0; }
