/* ==========================================================================
   Design-Pass 11.11.2026
   Feinschliff Typografie, Abstaende, Karten, Bedienelemente.
   Ueberschreibt bewusst nur Optik, keine Funktion.
   ========================================================================== */

:root {
    --text-muted: #a9bacd;
    --border: rgba(255, 255, 255, 0.09);
    --border-strong: rgba(255, 255, 255, 0.15);
    --shadow-soft: 0 12px 32px rgba(0, 0, 0, 0.38);
    --ring: 0 0 0 3px rgba(45, 212, 191, 0.28);
}

body {
    font-size: 16px;
    line-height: 1.6;
}

/* --- Formular-Gruppen ----------------------------------------------------- */
.field-group {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 26px 0 14px;
    font-family: var(--font-body);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 1.8px;
    text-transform: uppercase;
    color: var(--accent);
}

.field-group:first-of-type {
    margin-top: 4px;
}

.field-group::after {
    content: "";
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, rgba(45, 212, 191, 0.35), transparent);
}

/* --- Info-Seiten als Karten ----------------------------------------------- */
.info-summary {
    margin: 0 0 24px;
    padding: 14px 18px;
    border-left: 3px solid var(--accent);
    border-radius: 0 12px 12px 0;
    background: rgba(45, 212, 191, 0.07);
    color: var(--text);
    font-size: 15px;
    line-height: 1.6;
}

.info-card {
    margin-bottom: 16px;
    padding: 22px 24px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 14px;
    transition: border-color var(--dur) var(--ease);
}

.info-card:hover {
    border-color: rgba(45, 212, 191, 0.35);
}

.info-card h2 {
    margin: 0 0 10px;
    font-size: 17px;
    letter-spacing: 0.3px;
}

.info-card p,
.info-card li {
    margin: 0;
    font-size: 15px;
    line-height: 1.65;
    color: var(--text-muted);
}

.info-card p + p {
    margin-top: 10px;
}

.info-card ul,
.info-card ol {
    margin: 8px 0 0;
    padding-left: 20px;
}

.info-card li + li {
    margin-top: 4px;
}

/* --- Dokument-Vorschauen in den Karten ------------------------------------ */
.doc-thumb {
    position: relative;
    height: 300px;
    margin-bottom: 16px;
    overflow: hidden;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: #fff;
}

.doc-thumb iframe {
    width: 794px;
    height: 1123px;
    border: 0;
    transform-origin: top left;
    pointer-events: none;
    display: block;
}

.doc-thumb::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 70px;
    background: linear-gradient(180deg, rgba(13, 20, 38, 0), rgba(13, 20, 38, 0.92));
    pointer-events: none;
}

/* --- Robuste Umbruch-Regeln (schmale Viewports) --------------------------- */
.hero,
.hero-inner,
.section,
.cards,
.card,
.step-card,
.editor-layout,
.preview-pane {
    min-width: 0;
}

.hero-lead,
.section-lead,
.card p,
.step-card p,
.faq details p,
.footer-brand p {
    overflow-wrap: anywhere;
}

/* --- Abschnitts-Nummern --------------------------------------------------- */
.section-index {
    display: inline-block;
    margin-bottom: 12px;
    padding: 3px 10px;
    border: 1px solid rgba(45, 212, 191, 0.35);
    border-radius: 999px;
    background: rgba(45, 212, 191, 0.07);
    color: var(--accent);
    font-family: var(--font-body);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 2px;
}

/* --- Karten: Akzentlinie beim Hover --------------------------------------- */
.card::after,
.step-card::after {
    content: "";
    position: absolute;
    left: 24px;
    right: 24px;
    top: 0;
    height: 2px;
    border-radius: 2px;
    background: linear-gradient(90deg, var(--accent), rgba(129, 140, 248, 0.4), transparent);
    opacity: 0;
    transition: opacity var(--dur) var(--ease);
}

.card:hover::after,
.step-card:hover::after {
    opacity: 1;
}

/* --- FAQ zweispaltig ------------------------------------------------------ */
@media (min-width: 900px) {
    .faq {
        grid-template-columns: 1fr 1fr;
        align-items: start;
    }
}

/* --- Editor: Bedienleiste kompakt am Formularende ------------------------- */
.editor-layout .nav-buttons {
    position: static;
    display: flex;
    flex-direction: row;
    justify-content: flex-end;
    gap: 4px;
    width: fit-content;
    margin-left: auto;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: none;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    box-shadow: none;
}

.editor-layout .nav-buttons button {
    width: auto;
    padding: 3px 9px;
    font-size: 0.68rem;
    line-height: 1.2;
    font-weight: 500;
    letter-spacing: 0.3px;
    border-radius: var(--radius-pill);
}

/* Kein zusaetzlicher Abstand noetig: die Leiste ueberlagert nichts mehr. */
.editor-layout #bewerbung-form {
    padding-bottom: 0;
}

/* --- Fuss: Lichtkante ----------------------------------------------------- */
.site-footer {
    border-top: 1px solid transparent;
    border-image: linear-gradient(90deg, transparent, rgba(45, 212, 191, 0.45), transparent) 1;
}

/* --- Konto-Seiten: Karte zentrieren --------------------------------------- */
.auth-form {
    margin-left: auto;
    margin-right: auto;
    box-shadow: var(--shadow-soft);
}

/* --- CTA-Band ------------------------------------------------------------- */
.cta-band {
    padding: 40px 48px;
    background: linear-gradient(135deg, rgba(45, 212, 191, 0.14), rgba(129, 140, 248, 0.12));
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), var(--shadow-soft);
}

.cta-band h2 {
    font-size: 26px;
}

@media (max-width: 640px) {
    .cta-band {
        padding: 28px 24px;
    }
}

/* --- Ambient-Ebene -------------------------------------------------------- */
#ambient {
    position: fixed;
    inset: 0;
    z-index: -3;
    pointer-events: none;
    opacity: 0.9;
}

.cursor-glow {
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    background: radial-gradient(
        520px circle at var(--mx, 50%) var(--my, 25%),
        rgba(45, 212, 191, 0.10),
        rgba(129, 140, 248, 0.05) 40%,
        transparent 70%
    );
    transition: background 120ms linear;
}

/* Weiche Lichtkanten oben und unten, damit die Raender nicht tot wirken */
body::after {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    background:
        linear-gradient(180deg, rgba(45, 212, 191, 0.07), transparent 16%),
        linear-gradient(0deg, rgba(129, 140, 248, 0.08), transparent 20%),
        radial-gradient(120% 80% at 50% 0%, transparent 55%, rgba(5, 7, 13, 0.55) 100%);
}

@media (prefers-reduced-motion: reduce) {
    .cursor-glow {
        display: none;
    }
}

/* --- Hero ---------------------------------------------------------------- */
.hero {
    padding-top: 76px;
    padding-bottom: 56px;
}

.hero-title {
    font-size: clamp(34px, 5vw, 60px);
    line-height: 1.02;
    letter-spacing: 0.5px;
}

.hero-lead {
    font-size: 18px;
    line-height: 1.65;
    max-width: 54ch;
}

.hero-kicker {
    font-size: 12px;
    letter-spacing: 1.2px;
    text-transform: uppercase;
}

.hero-actions {
    gap: 14px;
}

.hero-stats {
    gap: 0;
    margin-top: 8px;
}

.hero-stats li {
    padding: 0 28px;
    border-left: 1px solid var(--border);
}

.hero-stats li:first-child {
    padding-left: 0;
    border-left: 0;
}

.hero-stats strong {
    font-size: 28px;
    line-height: 1.2;
}

.hero-stats span {
    font-size: 12px;
    letter-spacing: 0.8px;
    text-transform: uppercase;
}

/* --- Abschnitte ---------------------------------------------------------- */
.section {
    margin-top: 88px;
}

.section-head {
    margin-bottom: 32px;
    max-width: 64ch;
}

.section-head h2 {
    font-size: clamp(22px, 2.6vw, 30px);
    letter-spacing: 0.4px;
    margin-bottom: 10px;
}

.section-lead {
    font-size: 15px;
    line-height: 1.65;
}

/* --- Karten -------------------------------------------------------------- */
.card,
.step-card {
    border-radius: 16px;
    padding: 26px;
    border-color: var(--border);
}

.card h3,
.step-card h3 {
    font-size: 17px;
    letter-spacing: 0.3px;
    margin-bottom: 10px;
}

.card p,
.step-card p {
    font-size: 14.5px;
    line-height: 1.6;
}

.card:hover,
.step-card:hover {
    border-color: rgba(45, 212, 191, 0.5);
    box-shadow: var(--shadow-soft);
    transform: translateY(-2px);
}

.card-list {
    margin-top: 14px;
    line-height: 1.7;
}

.step-number {
    width: 36px;
    height: 36px;
    font-size: 14px;
    margin-bottom: 14px;
}

/* --- Bedienelemente ------------------------------------------------------ */
a.button,
button.primary,
button.secondary,
.nav-cta,
.nav-login {
    min-height: 44px;
    border-radius: 12px;
}

a.button {
    padding: 12px 24px;
}

button.primary {
    padding: 13px 26px;
}

button.secondary {
    padding: 12px 20px;
}

.nav-cta {
    display: inline-flex;
    align-items: center;
}

/* --- Formular ------------------------------------------------------------ */
input[type="text"],
input[type="email"],
input[type="tel"],
input[type="number"],
input[type="url"],
input[type="password"],
input[type="search"],
select {
    min-height: 44px;
}

textarea {
    min-height: 96px;
    line-height: 1.5;
}

input:hover,
textarea:hover,
select:hover {
    border-color: rgba(255, 255, 255, 0.24);
}

label {
    font-size: 13.5px;
    letter-spacing: 0.3px;
}

/* --- Stepper ------------------------------------------------------------- */
.stepper {
    gap: 8px;
    margin-bottom: 20px;
}

.step-btn {
    padding: 10px 18px;
    font-size: 14px;
}

.step-btn.active {
    box-shadow: 0 0 0 1px rgba(45, 212, 191, 0.45), var(--glow);
}

/* --- Panels -------------------------------------------------------------- */
.panel {
    border-radius: 16px;
    border-color: var(--border);
}

.step-panel h2 {
    font-size: 21px;
    margin-bottom: 18px;
}

/* --- Live-Vorschau ------------------------------------------------------- */
.preview-pane {
    border-radius: 16px;
    border-color: var(--border);
}

.preview-head {
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border);
    margin-bottom: 14px;
}

.preview-head h2 {
    font-size: 14px;
    letter-spacing: 1.2px;
    text-transform: uppercase;
}

.preview-state {
    font-size: 11px;
    letter-spacing: 0.6px;
    text-transform: uppercase;
}

.preview-note {
    font-size: 12px;
    line-height: 1.5;
}

/* --- Ergebnis ------------------------------------------------------------ */
.generated-file {
    padding: 22px 0;
}

.generated-file h3 {
    margin-bottom: 10px;
    font-size: 13px;
    letter-spacing: 1.2px;
    text-transform: uppercase;
}

#ergebnis h2 {
    margin-bottom: 6px;
}

#ergebnis .section-lead {
    margin-bottom: 18px;
}

/* --- FAQ ----------------------------------------------------------------- */
.faq details {
    border-radius: 12px;
    border-color: var(--border);
}

.faq summary {
    padding: 14px 16px;
    font-size: 15px;
}

.faq details p {
    padding: 0 16px 14px;
    margin-top: 0;
    font-size: 14px;
    line-height: 1.65;
}

.faq details[open] summary {
    color: var(--accent);
}

/* --- Footer -------------------------------------------------------------- */
.site-footer {
    padding-top: 48px;
    padding-bottom: 32px;
}

.footer-brand p {
    line-height: 1.65;
}

.footer-col h2 {
    color: var(--text-muted);
    font-size: 12px;
    letter-spacing: 1.4px;
}

.footer-col a {
    font-size: 13.5px;
    line-height: 1.6;
}

.footer-bottom {
    margin-top: 28px;
    font-size: 12.5px;
}

/* Kleine Signatur ganz unten auf jeder Seite */
.footer-credit {
    max-width: 1180px;
    margin: 10px auto 0;
    color: var(--text-muted);
    font-size: 11px;
    letter-spacing: 0.05em;
    opacity: 0.8;
}

/* --- KI-Assistent --------------------------------------------------------- */
.ai-fab {
    position: fixed;
    right: 22px;
    bottom: 22px;
    z-index: 70;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 7px 18px 7px 8px;
    border: 1px solid rgba(45, 212, 191, 0.55);
    border-radius: 999px;
    background:
        linear-gradient(135deg, rgba(45, 212, 191, 0.16), rgba(129, 140, 248, 0.14)),
        rgba(8, 13, 22, 0.94);
    color: var(--accent);
    font-family: var(--font-display);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    box-shadow:
        0 0 0 1px rgba(129, 140, 248, 0.12) inset,
        0 12px 34px rgba(0, 0, 0, 0.55),
        0 0 26px rgba(45, 212, 191, 0.22);
    cursor: pointer;
    backdrop-filter: blur(8px);
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.ai-fab:hover {
    transform: translateY(-2px);
    border-color: var(--accent);
    box-shadow:
        0 0 0 1px rgba(129, 140, 248, 0.2) inset,
        0 16px 40px rgba(0, 0, 0, 0.6),
        0 0 34px rgba(45, 212, 191, 0.38);
}

.ai-fab-text {
    padding-right: 4px;
}

.ai-orb {
    width: 46px;
    height: 46px;
    flex: 0 0 auto;
    display: block;
    overflow: visible;
    filter: drop-shadow(0 0 7px rgba(45, 212, 191, 0.45));
}

.ai-orb-wrap .ai-orb {
    width: 34px;
    height: 34px;
    filter: drop-shadow(0 0 5px rgba(45, 212, 191, 0.4));
}

.ai-orb-sat,
.ai-orb-sat2 {
    animation: ai-pulse 3.4s ease-in-out infinite;
}

.ai-orb-orbit2 {
    transform-box: view-box;
    transform-origin: 32px 32px;
    animation: ai-rotate 34s linear infinite;
}

.ai-orb-ring {
    transform-box: fill-box;
    transform-origin: center;
    animation: ai-rotate 16s linear infinite;
}

.ai-orb-orbit {
    transform-box: fill-box;
    transform-origin: center;
    animation: ai-rotate 26s linear infinite reverse;
}

.ai-orb-halo {
    transform-box: fill-box;
    transform-origin: center;
    animation: ai-pulse 4.2s ease-in-out infinite;
}

.ai-orb-core {
    transform-box: fill-box;
    transform-origin: center;
    animation: ai-core 3.6s ease-in-out infinite;
}

@keyframes ai-rotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

@keyframes ai-pulse {
    0%, 100% { opacity: 0.25; transform: scale(1); }
    50% { opacity: 0.6; transform: scale(1.04); }
}

@keyframes ai-core {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

.ai-panel {
    position: fixed;
    right: 22px;
    bottom: 96px;
    z-index: 70;
    width: 740px;
    max-width: calc(100vw - 44px);
    max-height: min(86vh, 900px);
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 20px;
    background:
        linear-gradient(180deg, rgba(45, 212, 191, 0.06), transparent 22%),
        rgba(8, 13, 22, 0.97);
    border: 1px solid rgba(45, 212, 191, 0.28);
    border-radius: var(--radius-lg);
    box-shadow:
        0 0 0 1px rgba(129, 140, 248, 0.08) inset,
        0 30px 80px rgba(0, 0, 0, 0.65),
        0 0 40px rgba(45, 212, 191, 0.12);
}

.ai-panel[hidden] {
    display: none;
}

.ai-panel-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
}

.ai-head-left {
    display: flex;
    align-items: center;
    gap: 10px;
}

.ai-head-left strong {
    font-family: var(--font-display);
    font-size: 15px;
    letter-spacing: 0.06em;
}

.ai-target {
    display: block;
    margin-top: 2px;
    color: var(--text-muted);
    font-size: 12px;
}

.ai-close {
    border: 0;
    background: none;
    color: var(--text-muted);
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
}

.ai-close:hover {
    color: var(--text);
}

.ai-log {
    display: flex;
    flex-direction: column;
    gap: 10px;
    overflow-y: auto;
    max-height: 52vh;
    padding-right: 6px;
}

.ai-bubble {
    padding: 10px 12px;
    border-radius: 10px;
    border: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.04);
    font-size: 14px;
    line-height: 1.6;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
}

.ai-bubble.ai-user {
    align-self: flex-end;
    border-color: rgba(45, 212, 191, 0.35);
    color: var(--accent);
}

.ai-bubble.ai-error {
    border-color: rgba(248, 113, 113, 0.5);
    color: #fecaca;
}

.ai-bubble.ai-ok {
    border-color: rgba(45, 212, 191, 0.35);
    color: #ccfbf1;
}

.ai-bubble.ai-muted {
    color: var(--text-muted);
}

.ai-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.ai-chip {
    padding: 5px 10px;
    border: 1px solid rgba(45, 212, 191, 0.45);
    border-radius: 999px;
    background: transparent;
    color: var(--accent);
    font-family: var(--font-body);
    font-size: 12px;
    cursor: pointer;
}

.ai-chip:hover {
    background: rgba(45, 212, 191, 0.12);
}

.ai-chip:disabled {
    opacity: 0.5;
    cursor: default;
}

.ai-chip-hint {
    color: var(--text-muted);
    font-size: 12px;
}

.ai-form {
    display: flex;
    align-items: flex-end;
    gap: 8px;
}

.ai-form textarea {
    flex: 1;
    min-height: 44px;
    max-height: 120px;
    resize: none;
}

.ai-load {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.ai-load[hidden] {
    display: none;
}

.ai-load-bar {
    height: 4px;
    border-radius: 2px;
    background: rgba(255, 255, 255, 0.08);
    overflow: hidden;
}

.ai-load-bar span {
    display: block;
    width: 40%;
    height: 100%;
    background: linear-gradient(90deg, transparent, var(--accent), transparent);
    animation: ai-slide 1.1s linear infinite;
}

@keyframes ai-slide {
    from { transform: translateX(-120%); }
    to { transform: translateX(320%); }
}

.ai-load p {
    margin: 0;
    color: var(--text-muted);
    font-size: 12px;
}

.ai-proposal {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 10px;
    border: 1px solid rgba(45, 212, 191, 0.4);
    border-radius: 12px;
    background: rgba(45, 212, 191, 0.06);
}

.ai-proposal-head {
    color: var(--accent);
    font-size: 13px;
    font-weight: 700;
}

.ai-proposal-meta {
    margin: 0;
    color: var(--text-muted);
    font-size: 11.5px;
}

.ai-proposal-text {
    max-height: 260px;
    overflow-y: auto;
    font-size: 14px;
    line-height: 1.6;
    white-space: pre-wrap;
}

.ai-target-select {
    width: 100%;
    padding: 8px 10px;
    border: 1px solid rgba(45, 212, 191, 0.35);
    border-radius: 8px;
    background: rgba(5, 10, 22, 0.9);
    color: var(--text);
    font-family: var(--font-body);
    font-size: 13px;
}

.ai-proposal-actions {
    display: flex;
    gap: 8px;
}

.ai-cv-field {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding-top: 8px;
    border-top: 1px solid rgba(45, 212, 191, 0.16);
}

.ai-cv-field:first-of-type {
    padding-top: 0;
    border-top: 0;
}

.ai-cv-field label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12.5px;
    color: var(--text);
}

.ai-cv-count {
    color: var(--text-muted);
    font-size: 11px;
}

.ai-cv-field .ai-proposal-text {
    max-height: 150px;
}

.ai-diff-add,
.ai-diff-del {
    padding: 1px 6px;
    border-radius: 6px;
    font-size: 12.5px;
    line-height: 1.55;
}

.ai-diff-add {
    color: #86efac;
    background: rgba(34, 197, 94, 0.12);
}

.ai-diff-del {
    color: #fca5a5;
    background: rgba(239, 68, 68, 0.12);
    text-decoration: line-through;
    text-decoration-thickness: 1px;
}

.ai-undo {
    margin-left: 6px;
}

.ai-credit {
    margin: 0;
    color: var(--text-muted);
    font-size: 10.5px;
    letter-spacing: 0.03em;
    opacity: 0.75;
}

@media (max-width: 640px) {
    .ai-panel {
        left: 10px;
        right: 10px;
        bottom: 92px;
        width: auto;
        max-width: none;
        max-height: 88vh;
        padding: 16px;
    }

    .ai-fab {
        right: 12px;
        bottom: 12px;
        padding: 6px 14px 6px 6px;
    }

    .ai-orb {
        width: 32px;
        height: 32px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .ai-orb-ring,
    .ai-orb-orbit,
    .ai-orb-halo,
    .ai-orb-core,
    .ai-load-bar span {
        animation: none;
    }

    .ai-fab {
        transition: none;
    }
}

/* --- Startanimation ------------------------------------------------------- */
[hidden] {
    display: none !important;
}

.intro {
    position: fixed;
    inset: 0;
    z-index: 200;
    display: grid;
    place-items: center;
    overflow: hidden;
    background:
        radial-gradient(circle at 50% 44%, rgba(45, 212, 191, 0.18), transparent 46%),
        radial-gradient(circle at 68% 30%, rgba(129, 140, 248, 0.14), transparent 42%);
    background-color: #04070d;
}

.intro.is-done {
    animation: intro-out 0.6s ease forwards;
    pointer-events: none;
}

.intro-veil {
    position: absolute;
    inset: -25%;
    background: conic-gradient(from 0deg, transparent 0 38%, rgba(45, 212, 191, 0.07) 50%, transparent 62%);
    animation: intro-spin 9s linear infinite;
}

.intro-particles span {
    position: absolute;
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background: #5eead4;
    box-shadow: 0 0 8px #5eead4;
    opacity: 0.45;
    animation: intro-float 3.6s ease-in-out infinite;
}

.intro-particles span:nth-child(1) { top: 22%; left: 28%; animation-delay: 0.1s; }
.intro-particles span:nth-child(2) { top: 34%; left: 72%; animation-delay: 0.7s; }
.intro-particles span:nth-child(3) { top: 64%; left: 20%; animation-delay: 1.2s; }
.intro-particles span:nth-child(4) { top: 72%; left: 66%; animation-delay: 0.4s; }
.intro-particles span:nth-child(5) { top: 16%; left: 54%; animation-delay: 1.6s; }
.intro-particles span:nth-child(6) { top: 82%; left: 44%; animation-delay: 0.9s; }

.intro-stage {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    text-align: center;
    padding: 24px;
}

.intro-orb {
    position: relative;
    width: 156px;
    height: 156px;
    display: grid;
    place-items: center;
    margin-bottom: 4px;
}

.intro-ring {
    position: absolute;
    border-radius: 50%;
    border: 1px solid rgba(45, 212, 191, 0.35);
}

.ring-a { inset: 0; border-style: dashed; animation: intro-spin 10s linear infinite; }
.ring-b { inset: 17px; border-color: rgba(129, 140, 248, 0.42); animation: intro-spin 14s linear infinite reverse; }
.ring-c { inset: 33px; border-color: rgba(34, 211, 238, 0.38); animation: intro-pulse 2.6s ease-in-out infinite; }

.intro-orbit {
    position: absolute;
    inset: -7px;
    border-radius: 50%;
    animation: intro-spin 6.5s linear infinite;
}

.intro-orbit i {
    position: absolute;
    top: -3px;
    left: 50%;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #5eead4;
    box-shadow: 0 0 10px #5eead4;
}

.orbit-b { inset: 26px; animation-duration: 4.6s; animation-direction: reverse; }
.orbit-b i { background: #a5b4fc; box-shadow: 0 0 10px #a5b4fc; }

.intro-scan {
    position: absolute;
    inset: 0;
    border-radius: 50%;
    background: linear-gradient(180deg, transparent 44%, rgba(94, 234, 212, 0.55) 50%, transparent 56%);
    mix-blend-mode: screen;
    animation: intro-scan 2.2s ease-in-out infinite;
}

.intro-mark {
    position: relative;
    width: 80px;
    height: 80px;
    display: grid;
    place-items: center;
    border-radius: 24px;
    background: linear-gradient(135deg, #5eead4, #2dd4bf 55%, #818cf8);
    color: #04231f;
    font-family: var(--font-display);
    font-size: 26px;
    font-weight: 900;
    letter-spacing: 0.04em;
    box-shadow:
        0 0 30px rgba(45, 212, 191, 0.55),
        0 0 80px rgba(129, 140, 248, 0.25);
    animation: intro-mark 0.9s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

.intro-title {
    margin: 0;
    color: #e6fffb;
    font-family: var(--font-display);
    font-size: clamp(20px, 3vw, 34px);
    letter-spacing: 0.06em;
    animation: intro-up 0.8s 0.35s both;
}

.intro-title em {
    font-style: normal;
    color: var(--accent);
}

.intro-sub {
    margin: 0;
    color: #94a3b8;
    font-size: 11px;
    letter-spacing: 0.38em;
    text-transform: uppercase;
    animation: intro-up 0.8s 0.5s both;
}

.intro-bar {
    width: min(340px, 62vw);
    height: 3px;
    margin-top: 8px;
    border-radius: 2px;
    background: rgba(255, 255, 255, 0.08);
    overflow: hidden;
}

.intro-bar span {
    display: block;
    width: 0;
    height: 100%;
    background: linear-gradient(90deg, #2dd4bf, #22d3ee, #818cf8);
    box-shadow: 0 0 12px rgba(45, 212, 191, 0.6);
    animation: intro-fill 1.9s 0.3s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

.intro-note {
    margin: 0;
    color: #64748b;
    font-size: 11px;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    animation: intro-up 0.8s 0.9s both;
}

@keyframes intro-in {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes intro-out {
    to { opacity: 0; visibility: hidden; transform: scale(1.03); }
}

@keyframes intro-spin {
    to { transform: rotate(360deg); }
}

@keyframes intro-pulse {
    0%, 100% { opacity: 0.25; transform: scale(0.98); }
    50% { opacity: 0.7; transform: scale(1.04); }
}

@keyframes intro-mark {
    from { opacity: 0; transform: scale(0.6) rotate(-12deg); }
    to { opacity: 1; transform: none; }
}

@keyframes intro-up {
    from { opacity: 0; transform: translateY(14px); }
    to { opacity: 1; transform: none; }
}

@keyframes intro-fill {
    to { width: 100%; }
}

@keyframes intro-scan {
    0% { transform: translateY(-120%); }
    100% { transform: translateY(120%); }
}

@keyframes intro-float {
    0%, 100% { opacity: 0.15; transform: translateY(0); }
    50% { opacity: 0.6; transform: translateY(-14px); }
}

@media (prefers-reduced-motion: reduce) {
    .intro,
    .intro * {
        animation: none !important;
    }
}

/* --- Fokus --------------------------------------------------------------- */
:where(a, button, input, textarea, select, summary):focus-visible {
    outline: 2px solid var(--focus);
    outline-offset: 2px;
    border-radius: 8px;
}

/* --- Mobil --------------------------------------------------------------- */
@media (max-width: 640px) {
    .hero {
        padding-top: 40px;
        padding-bottom: 32px;
    }

    .hero-stats li {
        padding: 0 16px;
    }

    .section {
        margin-top: 56px;
    }

    .card,
    .step-card {
        padding: 20px;
    }
}

/* --- Konto-Ablage -------------------------------------------------------- */
.ablage-item {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px 18px;
    margin-top: 12px;
    padding: 14px 16px;
    border: 1px solid var(--border);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.02);
}

.ablage-head {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 150px;
}

.ablage-head strong {
    font-size: 14px;
    color: var(--text);
}

.ablage-head span {
    font-size: 12px;
    color: var(--text-muted);
}

.ablage-links {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px 14px;
    flex: 1;
}

.ablage-links a {
    font-size: 14px;
    color: var(--accent);
    text-decoration: none;
}

.ablage-links a:hover {
    text-decoration: underline;
}

.ablage-links .ablage-pdf {
    font-size: 12px;
    opacity: 0.8;
}

.ablage-links .ablage-zip {
    font-weight: 600;
}

.ablage-leer {
    margin: 0;
    font-size: 14px;
    color: var(--text-muted);
}

/* --- KI-Textvorschlag ---------------------------------------------------- */
.ai-box {
    margin: -6px 0 18px;
    padding: 12px 14px;
    border: 1px dashed var(--border);
    border-radius: 12px;
    background: rgba(45, 212, 191, 0.04);
}

.ai-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.ai-head-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: flex-end;
}

.load-toast {
    position: fixed;
    left: 22px;
    bottom: 22px;
    z-index: 80;
    max-width: 380px;
    padding: 12px 16px;
    border: 1px solid rgba(45, 212, 191, 0.55);
    border-radius: 12px;
    background: rgba(8, 13, 22, 0.96);
    color: var(--text);
    font-size: 13px;
    line-height: 1.45;
    box-shadow: 0 12px 34px rgba(0, 0, 0, 0.55);
}

.load-toast.is-error {
    border-color: rgba(248, 113, 113, 0.75);
    color: #fecaca;
}

@media (max-width: 640px) {
    .load-toast {
        left: 12px;
        right: 12px;
        bottom: 12px;
        max-width: none;
    }
}

.ai-title {
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 1.4px;
    text-transform: uppercase;
    color: var(--accent);
}

.ai-hint {
    margin: 8px 0 0;
    font-size: 13px;
    line-height: 1.5;
    color: var(--text-muted);
}

.ai-hint code {
    padding: 1px 5px;
    border-radius: 5px;
    background: rgba(255, 255, 255, 0.08);
    font-size: 12px;
}

.ai-result {
    margin-top: 10px;
    padding: 12px 14px;
    border: 1px solid rgba(45, 212, 191, 0.3);
    border-radius: 10px;
    background: rgba(13, 20, 38, 0.6);
}

.ai-result p {
    margin: 0;
    font-size: 14px;
    line-height: 1.6;
    color: var(--text);
    white-space: pre-wrap;
}

.ai-actions {
    display: flex;
    gap: 8px;
    margin-top: 10px;
}


/* --- Social Login -------------------------------------------------------- */
.social-login {
    margin-top: 26px;
    padding-top: 22px;
    border-top: 1px solid var(--border);
}

.social-title {
    margin: 0 0 14px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 1.6px;
    text-transform: uppercase;
    color: var(--text-muted);
}

.social-buttons {
    display: grid;
    gap: 10px;
}

.social-btn {
    display: flex;
    align-items: center;
    gap: 12px;
    min-height: 44px;
    padding: 10px 16px;
    border: 1px solid var(--border);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.03);
    color: var(--text);
    font-weight: 600;
    text-decoration: none;
    transition: border-color var(--dur) var(--ease), background var(--dur) var(--ease);
}

.social-btn:hover {
    border-color: rgba(45, 212, 191, 0.45);
    background: rgba(45, 212, 191, 0.06);
}

.social-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0;
}

.social-btn.is-off {
    opacity: 0.62;
    border-style: dashed;
}

.social-btn.is-off:hover {
    border-color: var(--border);
    background: rgba(255, 255, 255, 0.03);
}

.social-note {
    margin: 12px 0 0;
    padding: 10px 14px;
    border-left: 3px solid var(--accent);
    border-radius: 0 10px 10px 0;
    background: rgba(45, 212, 191, 0.07);
    font-size: 13px;
    line-height: 1.5;
    color: var(--text);
}

/* --- Kopfzeile: angemeldeter Nutzer + Abmelden --------------------------- */
#nav-auth {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
}

.nav-user {
    display: inline-block;
    max-width: 160px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    vertical-align: middle;
}

.nav-user::before {
    content: "\25CF  ";
    font-size: 8px;
    color: var(--success);
}

#nav-auth .nav-login {
    background: transparent;
    border: 1px solid transparent;
    font-family: var(--font-body);
    font-size: var(--text-base);
    line-height: 1.2;
    cursor: pointer;
}

#nav-auth .nav-login:hover {
    border-color: var(--border);
}

#nav-auth .nav-register {
    padding: 9px 10px;
    color: var(--accent);
    font-family: var(--font-body);
    font-size: var(--text-base);
    font-weight: 700;
    line-height: 1.2;
    text-decoration: none;
    border: 1px solid rgba(45, 212, 191, 0.45);
    border-radius: var(--radius-sm);
}

#nav-auth .nav-register:hover {
    border-color: var(--accent);
    background: rgba(45, 212, 191, 0.12);
}

@media (max-width: 1024px) {
    #nav-auth {
        justify-content: flex-start;
    }
}

/* --- Seite "Meine Unterlagen" ------------------------------------------- */
.ablage-job {
    margin-top: 14px;
    padding: 16px 18px;
    border: 1px solid var(--border);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.02);
}

.ablage-docs {
    display: grid;
    gap: 8px;
    margin: 12px 0 4px;
}

.ablage-doc {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px 14px;
    font-size: 14px;
}

.ablage-doc-name {
    min-width: 110px;
    font-weight: 600;
    color: var(--text);
}

.merge-select {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-left: 6px;
}

.merge-order {
    width: 54px;
    padding: 2px 4px;
    border: 1px solid var(--border-strong);
    border-radius: 6px;
    background: var(--surface);
    color: var(--text);
    font-size: 13px;
}

.merge-check {
    accent-color: var(--accent);
}

.ablage-doc a,
.ablage-links a {
    color: var(--accent);
    text-decoration: none;
}

.ablage-doc a:hover,
.ablage-links a:hover {
    text-decoration: underline;
}

.ablage-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid var(--border);
}

.ablage-file {
    display: flex;
    flex-direction: column;
    gap: 3px;
    min-width: 0;
    flex: 1 1 220px;
}

.ablage-file strong {
    overflow-wrap: anywhere;
    color: var(--text);
}

.ablage-file span {
    font-size: 12px;
    color: var(--text-muted);
}

.upload-form {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
    margin: 4px 0 18px;
}

.upload-label {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
    font-size: 14px;
    color: var(--text-muted);
}

.upload-label input[type="file"] {
    max-width: 100%;
    padding: 8px;
    border: 1px dashed var(--border);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.02);
    color: var(--text-muted);
    font-size: 13px;
}

.upload-label input[type="file"]::file-selector-button {
    margin-right: 10px;
    padding: 7px 12px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: rgba(45, 212, 191, 0.12);
    color: var(--text);
    font-family: var(--font-body);
    font-weight: 600;
    cursor: pointer;
}

.upload-form #upload-status {
    flex-basis: 100%;
    margin: 0;
}

/* --- Passwort vergessen / Reset ----------------------------------------- */
.auth-note {
    margin: 0;
    padding: 10px 12px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    background: rgba(45, 212, 191, 0.07);
    color: var(--text);
    font-size: 14px;
    line-height: 1.5;
    overflow-wrap: anywhere;
}

.auth-note.is-success {
    border-color: rgba(45, 212, 191, 0.5);
}

.auth-note a {
    color: var(--accent);
    font-weight: 600;
}

.auth-note p {
    margin: 8px 0;
    color: var(--text-muted);
    font-size: 13px;
}

/* --- Konto-Aktionen (Export / Loeschen) --------------------------------- */
.account-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
    margin: 4px 0 14px;
}

.account-actions .secondary {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    padding: 10px 16px;
    border: 1px solid var(--border);
    border-radius: 10px;
    color: var(--text);
    font-weight: 600;
    text-decoration: none;
    background: rgba(255, 255, 255, 0.03);
}

.account-actions .secondary:hover {
    border-color: rgba(45, 212, 191, 0.45);
}

/* --- Anzeigename -------------------------------------------------------- */
.name-form {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 12px;
    margin: 4px 0 18px;
}

.name-form label {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-size: 13px;
    color: var(--text-muted);
}

.name-form input[type="text"] {
    min-width: 260px;
    max-width: 100%;
    padding: 10px 12px;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.03);
    color: var(--text);
    font-family: var(--font-body);
    font-size: 15px;
}

.name-form input[type="text"]:focus {
    outline: 2px solid var(--focus);
    outline-offset: 1px;
}

.name-form #name-status {
    flex-basis: 100%;
    margin: 0;
}

/* --- Dokumentauswahl in "Meine Unterlagen" ------------------------------ */
.ablage-doc input[type="checkbox"] {
    width: 16px;
    height: 16px;
    margin: 0;
    accent-color: var(--accent);
    cursor: pointer;
}

.ablage-actions button:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}
