/* Basis-Styles der Kursseiten, Konto und Formulare.
   Farben kommen als CSS-Variablen aus den Einstellungen (layouts/app.blade.php). */

:root {
    --accent: #4CAF50;
    --accent-dark: color-mix(in srgb, var(--accent) 82%, #000);
    --navy: color-mix(in srgb, var(--accent) 66%, #1b1216);
    --text: #2a2024;
    --muted: #6a5b60;
    --border: #e6dfe1;
    --bg: #f7f4f4;
    --danger: #c0392b;
    --radius: 16px;
    --font: 'Mulish', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-display: var(--font); /* Überschriften in der Fließtextschrift (vorher Newsreader) */
}

*, *::before, *::after { box-sizing: border-box; }

body {
    margin: 0;
    font-family: var(--font);
    color: var(--text);
    background: var(--bg);
    line-height: 1.6;
}

a { color: var(--navy); }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; border-radius: 6px; }

/* Fußzeile bleibt auch bei kurzen Seiten unten */
body:not(.focus) { min-height: 100vh; display: flex; flex-direction: column; }
body:not(.focus) > .site-main { flex: 1 0 auto; width: 100%; }
body:not(.focus) > .site-main:focus { outline: none; }

.site-main {
    max-width: 1120px;
    margin: 0 auto;
    padding: 2.5rem 1rem 4rem;
}

/* Karten & Auth-Formulare */
.auth-wrap { max-width: 460px; margin: 0 auto; }
.card {
    background: #fff;
    border-radius: var(--radius);
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06);
    overflow: hidden;
}
.card__header {
    background: linear-gradient(180deg, color-mix(in srgb, var(--accent) 7%, #fff) 0%, #faf7f7 100%);
    padding: 1.75rem 2rem 1.25rem;
    border-bottom: 4px solid var(--accent);
}
.card__header h1 {
    font-family: var(--font-display);
    font-size: 1.6rem;
    margin: 0;
    line-height: 1.3;
}
.card__header p { margin: 0.35rem 0 0; color: var(--muted); font-size: 0.95rem; }
.card__body { padding: 1.75rem 2rem 2rem; }

.field { margin-bottom: 1.1rem; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 0.9rem; }
.field label { display: block; font-weight: 600; font-size: 0.875rem; margin-bottom: 0.35rem; }
.field input[type=text],
.field input[type=email],
.field input[type=password] {
    width: 100%;
    padding: 0.75rem 0.9rem;
    border: 1.5px solid var(--border);
    border-radius: 10px;
    font: inherit;
    font-size: 1rem;
    background: #fff;
    transition: border-color .15s, box-shadow .15s;
}
.field input:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 20%, transparent);
}
.field--invalid input, .field--invalid textarea { border-color: var(--danger); }
.field__error { color: var(--danger); font-size: 0.85rem; margin-top: 0.3rem; }
.field__hint { color: var(--muted); font-size: 0.8rem; margin-top: 0.3rem; }
.checkbox { display: flex; align-items: center; gap: 0.5rem; font-size: 0.9rem; }

/* Honeypot – für Menschen unsichtbar */
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    padding: 0.8rem 1.6rem;
    border: none;
    border-radius: 30px;
    background: var(--accent);
    color: #fff;
    font: inherit;
    font-weight: 700;
    font-size: 1rem;
    text-decoration: none;
    cursor: pointer;
    transition: background .15s, transform .15s;
}
.btn:hover { background: var(--accent-dark); }
.btn--full { width: 100%; }
.btn--ghost { background: transparent; color: var(--navy); border: 1.5px solid var(--border); }
.btn--ghost:hover { background: #f5f0f1; }
.btn--link { background: none; border: none; padding: 0; color: var(--navy); font-weight: 600; cursor: pointer; font: inherit; }
.btn--danger { background: var(--danger); color: #fff; border-color: var(--danger); }
.btn--danger:hover { background: #a93226; }

/* Datenschutz (Kundencockpit) */
.privacy-card--danger { border: 1.5px solid #f3c7c1; }
.privacy-exports { list-style: none; padding: 0; margin: 1rem 0 0; }
.privacy-exports li { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 0.5rem 1rem; padding: 0.6rem 0; border-top: 1px solid var(--border); }
.privacy-choice { display: grid; gap: 0.5rem; margin: 1rem 0; }
.privacy-choice label { display: flex; gap: 0.5rem; align-items: flex-start; font-size: 0.925rem; }

.alert { padding: 0.85rem 1rem; border-radius: 10px; margin-bottom: 1.25rem; font-size: 0.925rem; }
.alert--success { background: #e8f5e9; color: #1b5e20; }
.alert--error { background: #fdecea; color: #8a1c12; }

.divider { display: flex; align-items: center; gap: 0.75rem; color: var(--muted); font-size: 0.85rem; margin: 1.25rem 0; }
.divider::before, .divider::after { content: ""; flex: 1; border-top: 1px solid var(--border); }

.auth-links { margin-top: 1.25rem; text-align: center; font-size: 0.9rem; display: grid; gap: 0.4rem; }

.hero {
    background: linear-gradient(180deg, color-mix(in srgb, var(--accent) 7%, #fff) 0%, #faf7f7 100%);
    border-radius: var(--radius);
    padding: 3rem 2rem;
    text-align: center;
}
.hero h1 { font-family: var(--font-display); font-size: 2.2rem; margin: 0 0 0.5rem; }
.hero p { color: var(--muted); margin: 0 0 1.5rem; }
.section-head { display: flex; justify-content: space-between; align-items: baseline; flex-wrap: wrap; gap: 0.5rem 1rem; margin: 0 0 1rem; }
.section-head .section-title, .section-head .page-title { margin: 0; }
.section-head a { font-weight: 600; text-decoration: none; }

@media (max-width: 560px) {
    .card__header, .card__body { padding-left: 1.25rem; padding-right: 1.25rem; }
    .field-row { grid-template-columns: 1fr; gap: 0; }
    .hero h1 { font-size: 1.7rem; }
}

/* ---------- Kurse ---------- */
.page-title { font-family: var(--font-display); font-size: 2rem; margin: 0 0 1.5rem; }
.section-title { font-family: var(--font-display); font-size: 1.35rem; margin: 2rem 0 1rem; }
.muted { color: var(--muted); }
.badge { display: inline-block; font-size: 0.72rem; font-weight: 700; padding: 0.15rem 0.55rem; border-radius: 999px; background: #e8f5e9; color: #1b5e20; white-space: nowrap; }
.alert--warning { background: #fff8e1; color: #7a5a00; }
.alert--info { background: #e8f1fb; color: #1d3f72; }

.course-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 1.5rem; }
.course-card { display: flex; flex-direction: column; background: #fff; border-radius: var(--radius); overflow: hidden; box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06); text-decoration: none; color: inherit; transition: transform .15s, box-shadow .15s; }
.course-card:hover { transform: translateY(-2px); box-shadow: 0 8px 30px rgba(0, 0, 0, 0.1); }
.course-card__image { position: relative; aspect-ratio: 1200 / 628; overflow: hidden;background: linear-gradient(180deg, color-mix(in srgb, var(--accent) 7%, #fff) 0%, #faf7f7 100%); }
.course-card__image img { width: 100%; height: 100%; object-fit: cover; display: block; }
.course-card__ribbon { position: absolute; top: 30px; right: -42px; width: 160px; padding: 6px 0; transform: rotate(45deg); background: var(--accent); color: #fff; font-size: .75rem; font-weight: 700; letter-spacing: .08em; text-align: center; text-transform: uppercase; box-shadow: 0 2px 8px rgba(0, 0, 0, .2); pointer-events: none; }
.course-card__body { padding: 1.25rem 1.4rem 1.5rem; display: flex; flex-direction: column; gap: 0.4rem; flex: 1; }
.course-card__body h2 { font-family: var(--font-display); font-size: 1.25rem; margin: 0; line-height: 1.3; }
.course-card__body p { margin: 0; color: var(--muted); font-size: 0.925rem; }
/* Programm-Kurzlabel (programs.course_badge) – eckig mit Akzentkante, damit es nicht wie ein Status-Chip wirkt */
.program-badges { display: flex; flex-wrap: wrap; gap: 0.35rem; margin-bottom: 0.15rem; }
.program-badge { display: inline-flex; align-items: center; max-width: 100%; font-size: 0.72rem; font-weight: 800; letter-spacing: .02em; line-height: 1.3; padding: 0.2rem 0.5rem 0.2rem 0.45rem; border-radius: 4px; border-left: 3px solid #f99759; background: #fdeee3; color: #7d0d27; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.course-card__meta { font-size: 0.75rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--accent); }
.course-card__cta { margin-top: auto; padding-top: 0.5rem; font-weight: 700; color: var(--navy); }

.course-hero { display: grid; grid-template-columns: minmax(0, 1fr) 320px; grid-template-areas: "image box" "text box"; gap: 1.25rem 2rem; align-items: start; background: linear-gradient(180deg, color-mix(in srgb, var(--accent) 7%, #fff) 0%, #faf7f7 100%); border-radius: var(--radius); padding: 2.25rem; margin-bottom: 1.75rem; }
.course-hero h1 { font-family: var(--font-display); font-size: 2.2rem; line-height: 1.2; margin: 0.5rem 0; }
.course-hero__excerpt { color: #3d4a5c; font-size: 1.05rem; margin: 0; }
.course-hero__text { grid-area: text; }
.course-hero__media { grid-area: image; position: relative; min-width: 0; }
.course-hero__image { width: 100%; max-height: 360px; object-fit: cover; border-radius: 12px; display: block; }
.course-hero > .enroll-box { grid-area: box; align-self: start; display: flex; flex-direction: column; justify-content: center; }
.course-hero:not(:has(.course-hero__image)) { grid-template-columns: minmax(0, 1fr) 320px; grid-template-areas: "text box"; }
.breadcrumb { font-size: 0.875rem; color: var(--muted); margin-bottom: 1rem; }
.breadcrumb a { color: var(--navy); font-weight: 600; text-decoration: none; }

.tabs { background: #fff; border-radius: var(--radius); box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06); padding: 0 1.75rem 2rem; display: flex; flex-wrap: wrap; }
.tabs > input { position: absolute; opacity: 0; pointer-events: none; }
.tabs > label { padding: 1rem 0.25rem 0.8rem; margin-right: 1.5rem; font-weight: 700; color: var(--muted); border-bottom: 3px solid transparent; cursor: pointer; }
.tabs > input:checked + label { color: var(--text); border-bottom-color: var(--accent); }
.tabs__panel { display: none; width: 100%; border-top: 1px solid var(--border); padding-top: 1.5rem; }
#tab-content:checked ~ .tabs__panel--content, #tab-materials:checked ~ .tabs__panel--materials { display: block; }

.prose { font-size: 1.02rem; }
.prose img { max-width: 100%; height: auto !important; border-radius: 8px; }
/* Alleinstehende Fotos (eigener Block oder allein im Absatz) mittig */
.prose > img, .prose > a > img, .prose .img-block img { display: block; margin: 1.25rem auto; }
.prose .img-block { text-align: center; }
/* Tabellen (oft als Layout: Text neben Bild) */
.prose table { width: 100%; border-collapse: collapse; margin: 1.25rem 0; }
.prose th, .prose td { text-align: left; vertical-align: middle; padding: 0.5rem 0.75rem; font-weight: inherit; }
.prose img.img-card { border-radius: 12px; box-shadow: 0 10px 30px rgba(44, 62, 107, 0.15); }
/* Kursbeschreibung als ruhige Einleitungsfläche */
.course-intro { background: linear-gradient(180deg, #f4f9f6 0%, #fff 100%); border: 1px solid var(--border); border-radius: var(--radius); padding: 2rem clamp(1.25rem, 4vw, 3rem); margin-bottom: 2rem; line-height: 1.75; color: #2f3b4d; }
.course-intro > :first-child { margin-top: 0; }
.course-intro > :last-child { margin-bottom: 0; }
.course-intro h2, .course-intro h3 { font-family: var(--font-display); color: var(--text); }
.course-intro em { color: var(--accent-dark); }
.course-intro table { margin: 0; }
.course-intro .img-block img:not(:is(td, th) img) { border-radius: 12px; }
.prose :is(th, td) > :first-child { margin-top: 0; }
.prose :is(th, td) .img-block { margin: 0; }
.prose :is(th, td) .img-block img { margin: 0 auto; }
@media (max-width: 700px) {
    .prose table, .prose tbody, .prose tr, .prose th, .prose td { display: block; width: 100%; }
    .prose :is(th, td) { padding: 0.5rem 0; }
    .prose :is(th, td) img { min-width: 0 !important; }
}
.prose iframe { max-width: 100%; }
.prose h2, .prose h3 { font-family: var(--font-display); }

.toc { display: flex; flex-direction: column; gap: 0.5rem; }
.toc__section { margin-top: 1rem; font-size: 0.78rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.toc__item { display: flex; align-items: center; gap: 0.6rem; padding: 0.8rem 1rem; border: 1px solid var(--border); border-radius: 12px; background: #fff; }
details.toc__item { display: block; padding: 0; }
details.toc__item > summary { display: flex; align-items: center; gap: 0.6rem; padding: 0.8rem 1rem; cursor: pointer; list-style: none; }
details.toc__item > summary::-webkit-details-marker { display: none; }
details.toc__item > summary::after { content: "▾"; margin-left: auto; color: var(--muted); transition: transform .15s; }
details.toc__item:not([open]) > summary::after { transform: rotate(-90deg); }
.toc__children { display: flex; flex-direction: column; gap: 0.35rem; padding: 0 1rem 0.8rem 2rem; }
.toc__children .toc__item { padding: 0.55rem 0.8rem; font-size: 0.95rem; }
.toc__type { font-size: 0.7rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--accent); min-width: 4.5rem; }
.toc__title { font-weight: 600; color: var(--text); text-decoration: none; }
a.toc__title:hover { color: var(--accent); }
.toc__title--locked { color: var(--muted); }
.toc__lock { font-size: 0.8rem; }
.toc__count { font-size: 0.75rem; color: var(--muted); background: var(--bg); border-radius: 999px; padding: 0.1rem 0.5rem; }

.step { max-width: 860px; margin: 0 auto; }
.step h1 { font-family: var(--font-display); font-size: 2rem; margin: 0.25rem 0 1.25rem; }
.step__type { font-size: 0.78rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--accent); }
.step-nav { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); align-items: stretch; gap: 1rem; margin-top: 2.5rem; padding-top: 1.5rem; border-top: 1px solid var(--border); }
.step-nav__link {
    display: grid; align-content: center; gap: 0.2rem; min-height: 64px; padding: 0.75rem 1.1rem; border-radius: 14px;
    border: 1.5px solid var(--border); background: #fff; color: var(--text); text-decoration: none; min-width: 0;
}
a.step-nav__link:hover { border-color: var(--navy); }
.step-nav__link--next { text-align: right; }
a.step-nav__link--next { background: var(--navy); border-color: var(--navy); color: #fff; }
a.step-nav__link--next:hover { filter: brightness(1.1); }
.step-nav__hint { font-size: 0.8rem; font-weight: 800; text-transform: uppercase; letter-spacing: .05em; opacity: .85; }
.step-nav__title { font-weight: 700; font-size: 1rem; overflow-wrap: anywhere; }
.step-nav__link--locked { background: var(--bg); color: var(--muted); border-style: dashed; }
.step-nav__lock { font-size: 0.85rem; }
.step-nav__overview {
    align-self: center; display: inline-flex; align-items: center; min-height: 44px; padding: 0 1rem; border-radius: 999px;
    color: var(--navy); font-weight: 700; text-decoration: underline; text-underline-offset: 3px; white-space: nowrap;
}
@media (max-width: 700px) {
    .step-nav { grid-template-columns: minmax(0, 1fr); }
    .step-nav__overview { order: 3; justify-self: center; }
    .step-nav__spacer { display: none; }
    .step-nav__link--next { order: -1; text-align: left; }
}

@media (max-width: 1100px) {
    /* Bild rutscht unter den Text, der Kasten bleibt rechts */
    .course-hero { grid-template-columns: minmax(0, 1fr) 300px; grid-template-areas: "image box" "text box"; }
    .course-hero:not(:has(.course-hero__image)) { grid-template-columns: minmax(0, 1fr) 300px; grid-template-areas: "text box"; }
    .course-hero > .enroll-box { align-self: start; }
}

@media (max-width: 800px) {
    .course-hero, .course-hero:not(:has(.course-hero__image)) { grid-template-columns: 1fr; grid-template-areas: "image" "text" "box"; padding: 1.5rem; }
    .course-hero h1 { font-size: 1.7rem; }
    .tabs { padding: 0 1.1rem 1.5rem; }
    .toc__children { padding-left: 1rem; }
    .toc__item, details.toc__item > summary { flex-wrap: wrap; row-gap: 0.1rem; }
    .toc__type { min-width: 0; width: 100%; }
    .toc__title { flex: 1; }
}

/* ---------- Fortschritt & Einschreibung ---------- */
.badge--info { background: #e8f1fb; color: #1d3f72; }
.progress { height: 10px; border-radius: 999px; background: #ece5e6; overflow: hidden; }
.progress--small { height: 6px; width: 120px; }
.progress__bar { height: 100%; background: var(--progress, var(--accent)); border-radius: 999px; transition: width .3s; }
.progress__label { font-size: 0.85rem; color: var(--muted); margin: 0.35rem 0 1rem; }

.course-layout { display: block; }
.enroll-box { background: #fff; border-radius: var(--radius); box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06); padding: 1.5rem; }
.enroll-box__status { margin-bottom: 0.75rem; }
.enroll-box__price { margin-bottom: 1rem; }
.enroll-box__amount { display: block; font-family: var(--font-display); font-size: 1.8rem; font-weight: 700; }
.enroll-box__period { color: var(--muted); font-size: 0.9rem; }
.enroll-box__note { color: var(--muted); font-size: 0.9rem; margin: 0.75rem 0 0; }
.enroll-box__link { display: block; text-align: center; font-size: 0.875rem; margin-top: 0.75rem; }
.enroll-box__list { margin: 0.5rem 0 0; padding-left: 1.2rem; font-size: 0.9rem; }
.enroll-box__facts { list-style: none; margin: 1.25rem 0 0; padding: 1rem 0 0; border-top: 1px solid var(--border); display: grid; gap: 0.4rem; font-size: 0.875rem; color: #3d4a5c; }
.enroll-box__facts li::before { content: "•"; color: var(--accent); margin-right: 0.5rem; }
.btn:disabled { opacity: 0.55; cursor: not-allowed; }

.toc__check { width: 1.35rem; height: 1.35rem; flex: 0 0 1.35rem; border-radius: 50%; border: 2px solid var(--border); display: inline-flex; align-items: center; justify-content: center; font-size: 0.75rem; font-weight: 700; color: #fff; }
.toc__check--done { background: var(--progress, var(--accent)); border-color: var(--progress, var(--accent)); }
.toc__hint { font-size: 0.78rem; color: var(--muted); white-space: nowrap; }
/* Ganze Karte klickbar (Link über die Karte gespannt) + Hover */
.toc__item { position: relative; transition: border-color .15s, box-shadow .15s, transform .15s; }
div.toc__item:has(> a.toc__title) { cursor: pointer; }
div.toc__item > a.toc__title::after { content: ""; position: absolute; inset: 0; border-radius: inherit; }
div.toc__item > .badge { position: relative; z-index: 1; }
div.toc__item:has(> a.toc__title):hover, details.toc__item > summary:hover { border-color: color-mix(in srgb, var(--accent) 45%, var(--border)); }
div.toc__item:has(> a.toc__title):hover { box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06); transform: translateY(-1px); }
div.toc__item:has(> a.toc__title):hover > .toc__title { color: var(--accent); }
details.toc__item > summary { border-radius: 12px; transition: background .15s; }
details.toc__item > summary:hover { background: color-mix(in srgb, var(--accent) 6%, #fff); }

.complete-box { display: flex; align-items: center; justify-content: center; gap: 1rem; flex-wrap: wrap; margin: 1.5rem 0 0; padding: 1.25rem; background: #fff; border-radius: var(--radius); box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06); text-align: center; }
.complete-box form { margin: 0; }
.complete-box p { margin: 0; width: 100%; }

.video { position: relative; aspect-ratio: 16 / 9; background: #000; border-radius: 12px; overflow: hidden; margin-bottom: 1.5rem; }
.video iframe, .video video, .video #step-video-player { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

.account-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 1rem; margin-bottom: 1.5rem; }
.account-stat { background: #fff; border-radius: 12px; padding: 1rem 1.25rem; box-shadow: 0 4px 24px rgba(0, 0, 0, 0.05); }
.account-stat strong { display: block; font-family: var(--font-display); font-size: 1.6rem; }
.account-stat span { color: var(--muted); font-size: 0.85rem; }
.my-course { display: grid; grid-template-columns: 120px minmax(0, 1fr) auto; gap: 1.25rem; align-items: center; padding: 1rem 0; border-bottom: 1px solid var(--border); }
.my-course:last-child { border-bottom: 0; padding-bottom: 0; }
.my-course__image { position: relative; display: block; aspect-ratio: 1200 / 628; border-radius: 10px; overflow: hidden; background: linear-gradient(180deg, color-mix(in srgb, var(--accent) 7%, #fff) 0%, #faf7f7 100%); }
.my-course__image img { width: 100%; height: 100%; object-fit: cover; display: block; }
.my-course h3 { margin: 0; font-size: 1.05rem; }
.my-course h3 a { text-decoration: none; }
.my-course small { color: var(--muted); }
.my-course__progress { display: flex; align-items: center; gap: 0.75rem; margin-top: 0.4rem; }
.my-course__progress .progress { flex: 0 1 220px; height: 8px; }
.my-course__progress small { white-space: nowrap; }

/* Kundencockpit (Mein Konto) */
.cockpit { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: 2rem; align-items: start; }
.cockpit__side { position: sticky; top: calc(var(--sh-h, 64px) + 1.5rem); background: #fff; border-radius: var(--radius); box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06); padding: 1.1rem; }
.cockpit__user { display: flex; align-items: center; gap: 0.75rem; padding: 0.25rem 0.25rem 1rem; margin-bottom: 0.5rem; border-bottom: 1px solid var(--border); min-width: 0; }
.cockpit__user > div { min-width: 0; }
.cockpit__user strong { display: block; line-height: 1.3; }
.cockpit__user small { display: block; color: var(--muted); font-size: 0.8rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cockpit__nav { display: flex; flex-direction: column; gap: 0.15rem; }
.cockpit__nav a, .cockpit__nav button { display: flex; align-items: center; gap: 0.65rem; padding: 0.6rem 0.75rem; border-radius: 10px; text-decoration: none; color: var(--text); font: inherit; font-weight: 500; font-size: 0.95rem; background: none; border: 0; cursor: pointer; width: 100%; text-align: left; }
.cockpit__nav svg { width: 20px; height: 20px; flex-shrink: 0; color: var(--muted); }
.cockpit__nav a:hover, .cockpit__nav button:hover { background: #f5f0f1; }
.cockpit__nav a.is-active { background: color-mix(in srgb, var(--accent) 14%, #fff); color: var(--navy); font-weight: 700; }
.cockpit__nav a.is-active svg { color: var(--accent); }
.cockpit__nav form { margin: 0.5rem 0 0; padding-top: 0.5rem; border-top: 1px solid var(--border); }
.cockpit__main { min-width: 0; }
.cockpit__main > .card + .card, .cockpit__main > .card + .cockpit-grid, .cockpit__main > .account-stats + .card, .cockpit__main > .alert + .card { margin-top: 1.5rem; }
.cockpit__main .card h2 { font-size: 1.2rem; }
.cockpit-hello .page-title { margin-bottom: 0.25rem; }
.cockpit-hello p { margin: 0 0 1.5rem; }
.cockpit-head { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; margin-bottom: 0.5rem; }
.cockpit-head h2 { margin: 0; }
.cockpit-head a { font-weight: 600; font-size: 0.9rem; text-decoration: none; white-space: nowrap; }
.cockpit-subhead { font-size: 0.95rem; margin: 1.5rem 0 0.25rem; }
.cockpit-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.5rem; align-items: start; margin-top: 1.5rem; }
.cockpit-grid--wide { grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); margin-top: 0; }
.cockpit-list-item { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: 0.7rem 0; border-bottom: 1px solid var(--border); }
.cockpit-list-item:last-child { border-bottom: 0; }
.cockpit-list-item > div { min-width: 0; }
.cockpit-list-item strong { display: block; line-height: 1.35; }
.cockpit-list-item a { text-decoration: none; }
.cockpit-support h2 { margin: 0 0 0.4rem; }
.cockpit-support .card__body { display: flex; gap: 1.25rem 1.75rem; align-items: flex-start; flex-wrap: wrap; }
.cockpit-support__icon { flex: 0 0 56px; width: 56px; height: 56px; border-radius: 16px; display: inline-flex; align-items: center; justify-content: center;
    background: color-mix(in srgb, var(--accent) 14%, #fff); color: var(--accent-dark); }
.cockpit-support__icon svg { width: 30px; height: 30px; }
.cockpit-support__text { flex: 1 1 280px; min-width: 0; }
.cockpit-support__text p { margin: 0; }
.cockpit-support__contact { flex: 0 1 auto; min-width: 220px; }
.cockpit-support__contact .cockpit-contact { margin-bottom: 0.9rem; }
.cockpit-grid--wide .cockpit-support .card__body { flex-direction: column; }
.cockpit-grid--wide .cockpit-support .card__body > :not(.cockpit-support__icon) { flex: 0 0 auto; min-width: 0; width: 100%; }
.cockpit-grid--wide .cockpit-contact li { flex-direction: column; gap: 0; }
.cockpit-stack { display: flex; flex-direction: column; gap: 1.5rem; min-width: 0; }
.cockpit-card--compact .card__body { padding: 1.25rem 2rem 1.25rem; }
.cockpit-empty { margin: 0.25rem 0 0; font-size: 0.925rem; line-height: 1.5; }
    background: color-mix(in srgb, var(--accent) 7%, #fff); border: 1px solid color-mix(in srgb, var(--accent) 25%, var(--border)); color: var(--text); }
.cockpit-contact { list-style: none; padding: 0; margin: 0 0 1.25rem; }
.cockpit-contact li { display: flex; gap: 0.75rem; padding: 0.35rem 0; font-size: 0.95rem; overflow-wrap: anywhere; }
.cockpit-contact span { color: var(--muted); min-width: 80px; }
.btn--small { padding: 0.35rem 0.9rem; font-size: 0.85rem; }
.badge--muted { background: #eef1f4; color: #55606e; }
.badge--danger { background: #fdecea; color: #8a1c12; }

.resume-card { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); margin-bottom: 1.5rem; }
.resume-card__image { position: relative; display: block; min-height: 100%; background: linear-gradient(180deg, color-mix(in srgb, var(--accent) 7%, #fff) 0%, #faf7f7 100%); }
.resume-card__image img { width: 100%; height: 100%; object-fit: cover; display: block; aspect-ratio: 1200 / 628; }
.resume-card__body { padding: 1.5rem 1.75rem; display: flex; flex-direction: column; gap: 0.6rem; justify-content: center; }
.resume-card__eyebrow { font-size: 0.75rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--accent); }
.resume-card h2 { font-family: var(--font-display); font-size: 1.5rem !important; margin: 0; line-height: 1.25; }
.resume-card p { margin: 0; }
.resume-card__meta { margin-top: -0.3rem; font-size: 0.85rem; }
.resume-card .btn { margin-top: 0.4rem; }

.avatar { border-radius: 50%; object-fit: cover; flex-shrink: 0; display: inline-block; }
.avatar--initials { display: inline-flex; align-items: center; justify-content: center; background: color-mix(in srgb, var(--accent) 18%, #fff); color: var(--navy); font-weight: 700; }
.invoice-create { margin: 0.5rem 0 1.5rem; padding: 1rem 1.25rem; border: 1px solid var(--border); border-radius: 12px; background: var(--bg); }
.invoice-create h3 { margin: 0 0 0.5rem; font-size: 1rem; }
.invoice-create__row { display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap; padding: 0.5rem 0; border-bottom: 1px solid var(--border); }
.invoice-create__row:last-of-type { border-bottom: 0; }
.invoice-create__row strong { display: block; }
.invoice-create .field__hint { margin: 0.5rem 0 0; }
.profile-photo { display: flex; align-items: center; gap: 1.5rem; }
.profile-photo h2 { margin: 0 0 0.25rem; }
.profile-photo p { margin: 0 0 0.75rem; font-size: 0.9rem; }
.profile-photo__actions { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; }
.profile-photo__actions form { margin: 0; }
.profile-photo__actions label.btn { cursor: pointer; }
.field input[type=tel], .field textarea, .field select { width: 100%; padding: 0.75rem 0.9rem; color: inherit; border: 1.5px solid var(--border); border-radius: 10px; font: inherit; font-size: 1rem; background: #fff; }
.field textarea { resize: vertical; }
.field textarea:focus, .field select:focus, .field input[type=tel]:focus { outline: none; border-color: var(--accent); }

@media (max-width: 900px) {
    .cockpit { grid-template-columns: minmax(0, 1fr); gap: 1.25rem; }
    .cockpit__side { position: static; padding: 0.5rem; min-width: 0; }
    .cockpit__user { display: none; }
    .cockpit__nav { flex-direction: row; overflow-x: auto; gap: 0.25rem; scrollbar-width: none; }
    .cockpit__nav::-webkit-scrollbar { display: none; }
    .cockpit__nav a, .cockpit__nav button { width: auto; white-space: nowrap; padding: 0.5rem 0.7rem; font-size: 0.9rem; }
    .cockpit__nav form { margin: 0; padding: 0; border: 0; }
    .cockpit-grid, .cockpit-grid--wide { grid-template-columns: 1fr; }
    .resume-card { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
    .my-course { grid-template-columns: 88px minmax(0, 1fr); gap: 0.9rem; }
    .my-course > .btn { grid-column: 1 / -1; justify-self: start; }
    .my-course__progress { flex-wrap: wrap; }
    .profile-photo { flex-direction: column; align-items: flex-start; }
    .account-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.filters { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-bottom: 1.5rem; align-items: center; }
.filters input, .filters select { padding: 0.55rem 0.8rem; border: 1.5px solid var(--border); border-radius: 10px; font: inherit; background: #fff; }
.course-card__progress { margin-top: 0.5rem; }
/* Meine Kurse: kleinere Kacheln (Konto mit Seitenleiste) */
.course-grid--mine { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 1.1rem; margin-top: 1rem; }
.course-grid--mine .course-card { box-shadow: 0 2px 14px rgba(0, 0, 0, 0.06); border: 1px solid var(--border); }
.course-grid--mine .course-card__body { padding: 0.9rem 1rem 1rem; gap: 0.35rem; }
.course-grid--mine .course-card__body h2 { font-size: 1.05rem; }
.course-grid--mine .course-card__body small { font-size: 0.8rem; line-height: 1.4; }
.course-grid--mine .course-card__progress .progress { height: 6px; margin-bottom: 0.25rem; }
.course-card__state { position: absolute; top: 8px; right: 8px; z-index: 2; padding: 3px 8px; border-radius: 999px; font-size: 0.7rem; font-weight: 800; letter-spacing: .02em; color: #fff; background: #2f7a4f; }
.course-card__state--muted { background: rgb(24 16 19 / .7); }
.course-card--expired .course-card__image img { filter: grayscale(.6); opacity: .8; }

/* ---------- Focus Mode ---------- */
/* Kopfzeile: site-header.css. Darunter: Kursinhalt (Seitenleiste bzw. mobil aufklappbar) + Inhalt mit Brotkrumen. */
body.focus { background: #fff; }
.focus__body { display: grid; grid-template-columns: 340px minmax(0, 1fr); min-height: calc(100vh - var(--sh-h, 64px)); }
.focus--right .focus__body { grid-template-columns: minmax(0, 1fr) 340px; }
.focus--right .focus__sidebar { order: 2; border-right: 0; border-left: 1px solid var(--border); }
.focus__sidebar {
    background: var(--bg); border-right: 1px solid var(--border); padding: 1.25rem 1rem 2rem;
    overflow-y: auto; max-height: calc(100vh - var(--sh-h, 64px)); position: sticky; top: var(--sh-h, 64px);
}
.focus__course { margin-bottom: 1.25rem; }
.focus__back {
    display: inline-flex; align-items: center; gap: 0.4rem; min-height: 44px; padding: 0 1rem; border-radius: 999px;
    background: #fff; border: 1.5px solid var(--border); color: var(--navy); font-weight: 700; font-size: 0.95rem; text-decoration: none;
}
.focus__back:hover { border-color: var(--navy); }
.focus__course-title { font-family: var(--font-display); font-weight: 600; font-size: 1.2rem; line-height: 1.3; color: var(--text); margin: 1rem 0 0.6rem; }
.focus__progress { display: grid; gap: 0.4rem; }
.focus__progress .progress { height: 8px; background: #e9e2e3; }
.focus__progress-text { font-size: 0.875rem; color: var(--muted); }
.focus__progress-text strong { color: var(--text); }
.fnav__section { font-size: 0.75rem; font-weight: 800; text-transform: uppercase; letter-spacing: .07em; color: var(--muted); margin: 1.25rem 0 0.45rem 0.25rem; }
.fnav__group { background: #fff; border: 1px solid var(--border); border-radius: 12px; padding: 0.35rem; margin-bottom: 0.6rem; }
.fnav__group > .fnav__item--lesson { padding-top: 0.55rem; padding-bottom: 0.55rem; }
.fnav__group > .fnav__children { border-top: 1px solid var(--border); margin: 0.2rem 0 0; padding: 0.3rem 0 0 0.75rem; }
.fnav__item { display: flex; align-items: flex-start; gap: 0.6rem; padding: 0.5rem; border-radius: 8px; font-size: 0.95rem; line-height: 1.4; }
.fnav__item .toc__check, .fnav__lockicon { margin-top: 0.1rem; }
.fnav__item a { color: var(--text); text-decoration: none; flex: 1; min-width: 0; }
.fnav__item a:hover { text-decoration: underline; text-underline-offset: 3px; }
.fnav__item--lesson { font-weight: 700; }
.fnav__item--current { background: color-mix(in srgb, var(--accent) 10%, #fff); box-shadow: inset 3px 0 0 var(--accent); }
.fnav__item--current a { color: var(--navy); }
.fnav__here {
    display: inline-block; margin-left: 0.35rem; padding: 0.05rem 0.5rem; border-radius: 999px; vertical-align: 0.1em;
    background: var(--accent); color: #fff; font-size: 0.7rem; font-weight: 800; letter-spacing: .02em;
}
.fnav__lockicon { width: 1.35rem; height: 1.35rem; flex: 0 0 1.35rem; display: inline-grid; place-items: center; border-radius: 50%; background: #efe9ea; color: var(--muted); }
.fnav__locked { color: var(--muted); flex: 1; min-width: 0; }
.fnav__lockhint { display: block; font-size: 0.8rem; font-weight: 600; margin-top: 0.1rem; }
.fnav__children { margin-left: 0.75rem; }
.fnav__children .fnav__item { font-weight: 500; }

.focus__coursebar { display: none; }
.focus__main { padding: 1.75rem 1.5rem 4rem; }
.focus__main:focus { outline: none; }
.focus__content { max-width: var(--focus-width); margin: 0 auto; }
.step__title { font-family: var(--font-display); font-weight: 600; font-size: 2.1rem; line-height: 1.2; margin: 0.25rem 0 1.25rem; }

@media (max-width: 899px) {
    .focus__body, .focus--right .focus__body { grid-template-columns: minmax(0, 1fr); }
    .focus__coursebar {
        display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 0.5rem;
        padding: 0.6rem 16px; background: var(--bg); border-bottom: 1px solid var(--border);
    }
    .focus__coursebar .focus__back { padding: 0 0.85rem; justify-content: center; white-space: nowrap; }
    .crumbs { font-size: 0.875rem; }
    .focus__back--side { display: none; }
    .focus__tocbtn {
        display: inline-flex; align-items: center; gap: 0.45rem; min-height: 44px; padding: 0 1rem; border-radius: 999px; cursor: pointer;
        border: 1.5px solid var(--navy); background: #fff; color: var(--navy); font: inherit; font-weight: 800; font-size: 0.95rem;
    }
    .focus__tocbtn[aria-expanded="true"] { background: var(--navy); color: #fff; }
    .focus__toccaret { transition: transform .15s ease; }
    .focus__tocbtn[aria-expanded="true"] .focus__toccaret { transform: rotate(180deg); }
    .focus__tocbtn { padding: 0 0.85rem; white-space: nowrap; }
    .focus__tocpct { font-weight: 600; opacity: .8; }
    .focus__sidebar { display: none; position: static; max-height: none; border-right: 0; border-bottom: 1px solid var(--border); }
    .focus--right .focus__sidebar { order: 0; border-left: 0; }
    .focus__sidebar.is-open { display: block; }
    .focus__course-title { margin-top: 0; }
    .focus__main { padding: 1.25rem 16px 3rem; }
    .step__title { font-size: 1.65rem; }
}
@media (min-width: 900px) {
    .focus__tocbtn { display: none; }
}
@media (max-width: 400px) {
    .focus__tocpct { display: none; }
    .focus__coursebar .focus__back, .focus__tocbtn { font-size: 0.9rem; }
}

/* Brotkrumen (Lektion/Thema/Quiz) */
.crumbs { margin: 0 0 1.25rem; font-size: 0.9rem; }
.crumbs ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; align-items: center; row-gap: 0.25rem; }
.crumbs li { display: inline-flex; align-items: center; min-width: 0; }
.crumbs li + li::before { content: "›"; margin: 0 0.5rem; color: var(--muted); }
.crumbs a { color: var(--navy); font-weight: 700; text-decoration: underline; text-decoration-color: color-mix(in srgb, currentColor 30%, transparent); text-underline-offset: 3px; padding: 0.35rem 0; overflow-wrap: anywhere; }
.crumbs a:hover { text-decoration-color: currentColor; }
.crumbs a[aria-current="page"] { color: var(--text); font-weight: 600; text-decoration: none; }

/* Tabellen (Konto: Bestellungen) */
.table-wrap { overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
.table th { text-align: left; font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.03em; color: #6c757d; border-bottom: 2px solid #e2e6ea; padding: 0.5rem; }
.table td { border-bottom: 1px solid #edf0f2; padding: 0.6rem 0.5rem; vertical-align: top; }
.table small { color: #6c757d; }
.table .btn--link { color: #b91c1c; font-size: 0.85rem; margin-left: 0.5rem; }

/* Eingebettete Videos im Inhalt ([video URL]) */
.prose .embed { position: relative; aspect-ratio: 16 / 9; margin: 1.25rem 0; border-radius: 10px; overflow: hidden; background: #000; }
.prose .embed iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.prose .embed-video { width: 100%; margin: 1.25rem 0; border-radius: 10px; }
.prose .embed-audio { width: 100%; margin: 1rem 0; }
.prose .pdf-embed { margin: 1.25rem 0; border: 1px solid var(--border); border-radius: 10px; overflow: hidden; background: #fff; }
.prose .pdf-embed__frame { display: block; width: 100%; height: min(80vh, 820px); border: 0; background: #525659; }
.prose .pdf-embed__bar { display: flex; align-items: center; flex-wrap: wrap; gap: 0.75rem 1rem; padding: 0.75rem 1rem; border-top: 1px solid var(--border); }
.prose .pdf-embed__name { flex: 1; min-width: 12rem; font-weight: 600; overflow-wrap: anywhere; }
.prose .pdf-embed__download { padding: 0.55rem 1.25rem; font-size: 0.9rem; text-decoration: none; }
/* Handy-Browser zeigen PDFs in iframes nicht zuverlässig an → nur Öffnen/Herunterladen */
@media (max-width: 700px) {
    .prose .pdf-embed__frame { display: none; }
    .prose .pdf-embed__bar { border-top: 0; }
}

/* ---------- Quiz ---------- */
.quiz [hidden], .quiz-result [hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.quiz-intro { position: relative; margin-top: 1.5rem; padding: 1.25rem 1.5rem; border: 1px solid var(--border); border-radius: 12px; background: #fafcfb; }
.quiz-intro__art { position: absolute; right: 1.25rem; top: 50%; transform: translateY(-50%); width: 170px; height: auto; pointer-events: none; }
.quiz-intro > :not(.quiz-intro__art) { position: relative; margin-right: 190px; }
@media (max-width: 640px) { .quiz-intro__art { display: none; } .quiz-intro > :not(.quiz-intro__art) { margin-right: 0; } }
.quiz-intro__facts { display: flex; flex-wrap: wrap; gap: 0.5rem 1.5rem; list-style: none; padding: 0; margin: 0 0 1rem; }
.quiz-progress { margin-bottom: 1.25rem; }
.quiz-progress__label { display: flex; justify-content: space-between; margin-bottom: .4rem; font-size: .85rem; font-weight: 600; color: var(--muted); }
.quiz__bar { display: flex; justify-content: space-between; align-items: center; gap: 1rem; margin-bottom: 1rem; min-height: 1.5rem; }
.quiz__position { font-weight: 600; }
.quiz__timer { font-weight: 700; font-variant-numeric: tabular-nums; padding: 0.2rem 0.7rem; border-radius: 999px; background: #e8f1fb; color: #1d3f72; }
.quiz__timer.is-low { background: #fdecea; color: #8a1c12; }
.quiz-overview { display: flex; flex-wrap: wrap; gap: 0.35rem; margin-bottom: 1rem; }
.quiz-overview__item { width: 2.1rem; height: 2.1rem; border-radius: 8px; border: 1.5px solid var(--border); background: #fff; cursor: pointer; font: inherit; font-size: 0.85rem; }
.quiz-overview__item.is-answered { background: #e8f5e9; border-color: #a5d6a7; }
.quiz-overview__item.is-current { border-color: var(--accent); box-shadow: 0 0 0 2px color-mix(in srgb, var(--accent) 25%, transparent); }
.quiz-q { border: 1px solid var(--border); border-radius: 12px; padding: 1.25rem 1.5rem; margin-bottom: 1rem; background: #fff; }
.quiz-q__head { display: flex; flex-wrap: wrap; align-items: center; gap: 0.6rem; margin-bottom: 0.5rem; font-size: 0.85rem; }
.quiz-q__number { font-weight: 700; color: var(--navy); }
.quiz-q__answers { border: 0; padding: 0; margin: 0.75rem 0 0; min-width: 0; }
.quiz-q__answers:disabled { opacity: 0.85; }
.quiz-choice { display: flex; gap: 0.7rem; align-items: flex-start; padding: 0.65rem 0.85rem; border: 1.5px solid var(--border); border-radius: 10px; margin-bottom: 0.5rem; cursor: pointer; }
.quiz-choice:has(input:checked) { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 6%, #fff); }
.quiz-choice input { margin-top: 0.3rem; accent-color: var(--accent); }
.quiz-input { width: 100%; padding: 0.65rem 0.85rem; border: 1.5px solid var(--border); border-radius: 10px; font: inherit; }
.quiz-input--inline { display: inline-block; width: auto; min-width: 8rem; padding: 0.3rem 0.6rem; margin: 0 0.2rem; }
.quiz-sort { list-style: decimal; padding-left: 1.5rem; margin: 0; }
.quiz-sort__item { display: flex; justify-content: space-between; align-items: center; gap: 0.75rem; padding: 0.5rem 0.75rem; border: 1.5px solid var(--border); border-radius: 10px; margin-bottom: 0.4rem; background: #fff; }
.quiz-sort__buttons { display: flex; gap: 0.25rem; flex-shrink: 0; }
.quiz-sort__btn { width: 2rem; height: 2rem; border: 1px solid var(--border); border-radius: 6px; background: #f7f9f8; cursor: pointer; }
.quiz-matrix__row { display: flex; align-items: center; gap: 1rem; margin-bottom: 0.5rem; }
.quiz-matrix__criterion { flex-shrink: 0; }
.quiz-cloze { line-height: 2.4; }
.quiz-scale { display: flex; flex-wrap: wrap; align-items: center; gap: 0.75rem; }
.quiz-scale__option { display: flex; flex-direction: column; align-items: center; gap: 0.2rem; cursor: pointer; }
.quiz-q__hint { margin-top: 0.75rem; font-size: 0.9rem; }
.quiz-q__hint summary { cursor: pointer; color: var(--navy); }
.quiz-q__feedback { margin-top: 0.75rem; padding: 0.75rem 1rem; border-radius: 10px; background: #f3f5f4; }
.quiz-q__feedback.is-correct, .quiz-q--review.is-correct { border-color: #a5d6a7; }
.quiz-q__feedback.is-correct { background: #e8f5e9; }
.quiz-q__feedback:has(.quiz-q__smiley) { display: flex; align-items: center; gap: 1rem; }
.quiz-q__feedback-text { flex: 1; min-width: 0; }
.quiz-q__smiley { flex: none; width: 64px; height: 64px; }
@media (max-width: 640px) { .quiz-q__smiley { width: 48px; height: 48px; } }
.quiz-q__feedback.is-wrong { background: #fdecea; }
.quiz-q--review.is-wrong { border-color: #f5b7b1; }
.quiz-q__actions { margin-top: 0.75rem; text-align: center; }
.quiz-solution { margin-top: 0.75rem; font-size: 0.9rem; color: #1b5e20; }
.quiz-solution ol, .quiz-solution ul { margin: 0.25rem 0 0 1.25rem; }
.quiz__nav { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 0.5rem; margin-top: 1rem; }
.quiz__nav #quiz-prev { margin-right: auto; }
.quiz-result__score { display: flex; align-items: center; gap: 2rem; flex-wrap: wrap; margin: 1rem 0 1.5rem; }
.quiz-result__percent { font-size: 3rem; font-weight: 800; color: var(--navy); line-height: 1; }
.quiz-result__facts { list-style: none; padding: 0; margin: 0; }
.quiz-result__actions { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 1.25rem 0; }
.quiz-result__actions form { margin: 0; }
.quiz-essay { margin-top: 0.75rem; padding: 0.75rem 1rem; background: #f7f9f8; border-radius: 10px; }
@media (max-width: 600px) {
    .quiz-q { padding: 1rem; }
    .quiz-matrix__row { flex-direction: column; align-items: stretch; gap: 0.3rem; }
    .quiz-matrix__criterion { flex-basis: auto !important; }
}

.enroll-box__certificate { margin-top: 1rem; padding-top: 1rem; border-top: 1px solid var(--border); }
.enroll-box__certificate .btn { margin-top: 0.5rem; }

/* Einsendeaufgaben */
.assignment-box { margin-top: 1.5rem; padding: 1.25rem 1.5rem; border: 1px solid var(--border); border-radius: 12px; background: #fff; }
.assignment-list { list-style: none; padding: 0; margin: 0 0 1rem; }
.assignment-item { padding: 0.75rem 0; border-bottom: 1px solid var(--border); }
.assignment-item__head { display: flex; flex-wrap: wrap; align-items: center; gap: 0.6rem; }
.assignment-item__head form { margin: 0; }
.assignment-comment { margin: 0.6rem 0 0 1rem; padding: 0.5rem 0.75rem; background: #f7f9f8; border-radius: 8px; font-size: 0.9rem; }
.assignment-reply { margin: 0.5rem 0 0 1rem; font-size: 0.9rem; }
.assignment-reply summary { cursor: pointer; color: var(--navy); }
.assignment-reply .btn { margin-top: 0.4rem; }
.assignment-upload { display: flex; flex-wrap: wrap; align-items: center; gap: 0.75rem; }
.assignment-upload .muted { flex-basis: 100%; margin: 0; font-size: 0.85rem; }

/* Rechtstexte (Impressum) */
.legal { max-width: 860px; margin: 0 auto; }
.legal__head { text-align: center; margin: 0.5rem 0 2rem; }
.legal__head h1 { font-family: var(--font-display); font-size: 2.4rem; margin: 0.35rem 0 0.4rem; }
.legal__head p { margin: 0; }
.legal__eyebrow { font-size: 0.75rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--accent); }
.legal__card { background: #fff; border-radius: var(--radius); box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06); padding: 2rem clamp(1.25rem, 4vw, 2.5rem); margin-bottom: 1.5rem; }
.legal__facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.5rem 2.5rem; }
.legal__facts h2, .legal__text h2 { font-size: 0.8rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin: 0 0 0.75rem; }
.legal__facts p { margin: 0 0 0.75rem; line-height: 1.6; }
.legal__label { display: block; font-size: 0.78rem; color: var(--muted); }
.legal__text h2 { margin-top: 1.75rem; padding-top: 1.5rem; border-top: 1px solid var(--border); }
.legal__text h2:first-child { margin-top: 0; padding-top: 0; border-top: 0; }
.legal__text p { margin: 0; line-height: 1.75; color: #3d4a5c; }
.legal__updated { text-align: center; font-size: 0.85rem; }
@media (max-width: 640px) { .legal__facts { grid-template-columns: 1fr; } .legal__head h1 { font-size: 1.9rem; } }
.legal__text ul { margin: 0.5rem 0 0.75rem; padding-left: 1.2rem; line-height: 1.75; color: #3d4a5c; }
.legal__text li { margin-bottom: 0.4rem; }
.legal__text p + p { margin-top: 0.75rem; }
.legal__text h2 { scroll-margin-top: 1.5rem; }
.legal__toc { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 0.25rem 1.5rem; padding-top: 1.25rem; padding-bottom: 1.25rem; }
.legal__toc a { display: flex; align-items: center; gap: 0.6rem; padding: 0.4rem 0; text-decoration: none; font-weight: 600; font-size: 0.92rem; }
.legal__toc span { display: inline-flex; align-items: center; justify-content: center; width: 1.6rem; height: 1.6rem; border-radius: 50%; background: color-mix(in srgb, var(--accent) 14%, #fff); color: var(--accent-dark); font-size: 0.78rem; }
/* Im Admin gepflegte Rechtstexte (freies HTML aus dem Editor) */
.legal__rich { line-height: 1.75; color: #3d4a5c; overflow-wrap: anywhere; }
.legal__rich h1, .legal__rich h2, .legal__rich h3, .legal__rich h4 { font-family: var(--font-display); color: var(--navy, #1b2433); line-height: 1.3; margin: 1.75rem 0 0.6rem; }
.legal__rich h1 { font-size: 1.6rem; }
.legal__rich h2 { font-size: 1.3rem; }
.legal__rich h3 { font-size: 1.1rem; }
.legal__rich h4 { font-size: 1rem; }
.legal__rich > :first-child { margin-top: 0; }
.legal__rich p { margin: 0 0 0.85rem; }
.legal__rich ul, .legal__rich ol { margin: 0.5rem 0 0.85rem; padding-left: 1.3rem; }
.legal__rich li { margin-bottom: 0.35rem; }
.legal__rich table { width: 100%; border-collapse: collapse; margin: 0.75rem 0 1rem; font-size: 0.92rem; display: block; overflow-x: auto; }
.legal__rich th, .legal__rich td { border: 1px solid var(--border); padding: 0.4rem 0.6rem; text-align: left; vertical-align: top; }
.site-footer { background: #2a2024; color: rgba(255, 255, 255, 0.72); text-align: center; padding: 2.5rem 1rem 3rem; font-size: 0.92rem; }
.site-footer nav { display: flex; justify-content: center; flex-wrap: wrap; gap: 0.6rem 1.9rem; margin-bottom: 1.1rem; }
.site-footer nav a { color: rgba(255, 255, 255, 0.85); text-decoration: none; }
.site-footer a:hover { color: #fff; }
.site-footer p { margin: 0; }
.site-footer p a { color: inherit; text-decoration: none; }
.site-footer .product-credit { margin-top: 0.9rem; font-size: 0.75rem; color: rgba(255, 255, 255, 0.5); }
.product-credit { display: flex; align-items: center; justify-content: center; gap: 0.4em; }
.product-credit__link { display: inline-flex; align-items: center; line-height: 0; border-radius: 3px; opacity: 0.85; transition: opacity 0.15s ease; }
.product-credit__link:hover, .product-credit__link:focus-visible { opacity: 1; }
.product-credit__logo { display: block; height: 2.1em; width: auto; }
.site-footer .product-credit__link { color: #fff; }
.focus__main .site-footer { margin: 4rem -1.5rem -4rem; border-radius: 0; }
@media (max-width: 899px) { .focus__main .site-footer { margin: 3rem -16px -3rem; } }

/* Kontakt-Modal */
.contact-modal { width: min(560px, calc(100vw - 2rem)); max-height: calc(100vh - 2rem); padding: 0; border: 0; border-radius: 20px; box-shadow: 0 30px 80px rgba(27, 36, 51, 0.35); overflow: auto; }
.contact-modal::backdrop { background: rgba(27, 36, 51, 0.55); backdrop-filter: blur(3px); }
.contact-modal[open] { animation: contact-in .22s ease-out; }
@keyframes contact-in { from { opacity: 0; transform: translateY(12px) scale(.98); } to { opacity: 1; transform: none; } }
.contact-modal__form { position: relative; margin: 0; }
.contact-modal__head { display: flex; gap: 1rem; align-items: flex-start; padding: 1.75rem 1.75rem 1.25rem; background: linear-gradient(180deg, color-mix(in srgb, var(--accent) 7%, #fff) 0%, #faf7f7 100%); }
.contact-modal__head h2 { font-family: var(--font-display); font-size: 1.6rem; margin: 0 0 0.25rem; }
.contact-modal__head p { margin: 0; color: #3d4a5c; font-size: 0.92rem; }
.contact-modal__icon { flex: 0 0 48px; width: 48px; height: 48px; border-radius: 14px; background: #fff; color: var(--accent-dark); display: inline-flex; align-items: center; justify-content: center; box-shadow: 0 4px 14px rgba(0, 0, 0, 0.06); }
.contact-modal__icon svg { width: 26px; height: 26px; }
.contact-modal__close { position: absolute; top: 0.75rem; right: 0.9rem; width: 2.2rem; height: 2.2rem; border-radius: 50%; border: 0; background: rgba(255, 255, 255, 0.8); font-size: 1.5rem; line-height: 1; cursor: pointer; color: var(--muted); }
.contact-modal__close:hover { color: var(--text); background: #fff; }
.contact-modal__body { padding: 1.5rem 1.75rem 1.75rem; }
.contact-modal__body .field { margin-bottom: 0.9rem; }
.contact-modal__privacy { display: flex; gap: 0.6rem; align-items: flex-start; font-size: 0.85rem; color: var(--muted); margin: 0.25rem 0 1.1rem; cursor: pointer; }
.contact-modal__privacy input { margin-top: 0.2rem; accent-color: var(--accent); }
.contact-modal__hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.contact-modal__error { margin-bottom: 1rem; }
.contact-modal__done { padding: 2.5rem 1.75rem; text-align: center; }
.contact-modal__done h3 { font-family: var(--font-display); font-size: 1.5rem; margin: 0.75rem 0 0.4rem; }
.contact-modal__done p { color: var(--muted); margin: 0 0 1.5rem; }
.contact-modal__check { display: inline-flex; width: 3.5rem; height: 3.5rem; border-radius: 50%; align-items: center; justify-content: center; background: color-mix(in srgb, var(--accent) 16%, #fff); color: var(--accent-dark); font-size: 1.6rem; font-weight: 700; }
@media (max-width: 560px) { .contact-modal__head { padding: 1.4rem 1.25rem 1rem; } .contact-modal__body { padding: 1.25rem; } }
/* Kündigungsbutton (Vertrag kündigen) */
.cancel-summary { display: grid; grid-template-columns: max-content 1fr; gap: 0.35rem 1.25rem; margin: 1rem 0 1.25rem; font-size: 0.95rem; }
.cancel-summary dt { color: var(--muted); }
.cancel-summary dd { margin: 0; font-weight: 600; overflow-wrap: anywhere; }
.cancel-form fieldset.field { border: 0; padding: 0; margin: 0 0 1rem; display: grid; gap: 0.4rem; }
.cancel-form legend { font-weight: 600; margin-bottom: 0.4rem; }
@media (max-width: 560px) { .cancel-summary { grid-template-columns: 1fr; } .cancel-summary dd { margin-bottom: 0.4rem; } }

/* Konto → Sicherheit (Passkeys, Code-Generator) */
.security-list { list-style: none; margin: 0 0 1.25rem; padding: 0; border: 1px solid var(--border); border-radius: 10px; }
.security-list li { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 0.75rem 1rem; }
.security-list li + li { border-top: 1px solid var(--border); }
.security-list small { display: block; }
.security-add { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 0.75rem; }
.security-add .field { flex: 1 1 16rem; margin-bottom: 0; }
.security-add .alert { flex: 1 1 100%; margin: 0; }
.security-steps { padding-left: 1.25rem; margin: 0 0 1rem; }
.security-setup { display: flex; flex-wrap: wrap; gap: 1.5rem; align-items: flex-start; }
.security-qr { background: #fff; padding: 0.5rem; border: 1px solid var(--border); border-radius: 10px; line-height: 0; }
.security-qr svg { width: 208px; height: 208px; }
.security-secret { display: inline-block; padding: 0.4rem 0.6rem; background: var(--bg, #f6f6f6); border: 1px solid var(--border); border-radius: 8px; font-size: 0.95rem; letter-spacing: 0.04em; word-break: break-all; }
.security-codes { margin: 0.75rem 0 0; font-size: 1rem; line-height: 1.7; columns: 2; background: transparent; }

/* ---------- Handy: Umschalter Website / Lernplattform (components/app-switch) ---------- */
.app-switch { display: none; }
@media (max-width: 820px) {
    body:has(> .app-switch) { padding-bottom: calc(4.75rem + env(safe-area-inset-bottom, 0px)); }
    .app-switch {
        display: grid; grid-template-columns: 1fr 1fr; gap: 0.375rem;
        position: fixed; left: 0; right: 0; bottom: 0; z-index: 50;
        padding: 0.5rem 0.75rem calc(0.5rem + env(safe-area-inset-bottom, 0px));
        background: color-mix(in srgb, #fffdfa 94%, transparent);
        border-top: 1px solid var(--border);
        box-shadow: 0 -6px 20px -12px rgba(27, 18, 22, 0.35);
        -webkit-backdrop-filter: saturate(1.4) blur(10px); backdrop-filter: saturate(1.4) blur(10px);
    }
    .app-switch__item {
        display: flex; align-items: center; justify-content: center; gap: 0.5rem; min-height: 3rem; padding: 0 0.75rem;
        border-radius: 999px; font-size: 1rem; font-weight: 700; color: var(--muted); text-decoration: none;
        transition: background-color .15s, color .15s;
    }
    .app-switch__item.is-active { color: #fff; background: var(--accent); }
    .app-switch__item:not(.is-active):active { background: color-mix(in srgb, var(--accent) 10%, transparent); }
    /* „Seite bearbeiten“ (Admins) rutscht über die Leiste */
    body:has(> .app-switch) .sp-edit { bottom: calc(5.5rem + env(safe-area-inset-bottom, 0px)); }
}
@media print { .app-switch { display: none !important; } }

/* Social-Media-Symbole in der Fußzeile */
/* Newsletter-Anmeldung in der Fußzeile */
.site-footer__newsletter { max-width: 56rem; margin: 0 auto 2.2rem; padding-bottom: 2rem; border-bottom: 1px solid rgba(255, 255, 255, 0.12); display: grid; gap: 1.1rem 2.5rem; text-align: left; }
@media (min-width: 900px) { .site-footer__newsletter { grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); align-items: center; } }
.site-footer__newsletter h2 { margin: 0 0 0.35rem; font-family: var(--font-display); font-size: 1.25rem; font-weight: 700; color: #fff; }
.site-footer__newsletter-text p { margin: 0; color: rgba(255, 255, 255, 0.72); line-height: 1.5; }
.site-footer__newsletter-form { display: grid; grid-template-columns: minmax(0, 1fr); gap: 0.6rem; }
@media (min-width: 600px) { .site-footer__newsletter-form { grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr) auto; } }
.site-footer__newsletter-form input[type=text], .site-footer__newsletter-form input[type=email] { width: 100%; min-height: 2.9rem; padding: 0.55rem 0.85rem; font: inherit; color: #fff; background: rgba(255, 255, 255, 0.08); border: 1px solid rgba(255, 255, 255, 0.25); border-radius: 8px; }
.site-footer__newsletter-form input::placeholder { color: rgba(255, 255, 255, 0.55); }
.site-footer__newsletter-form input:focus { outline: 2px solid #f99759; outline-offset: 1px; border-color: transparent; }
.site-footer__newsletter-form button { min-height: 2.9rem; padding: 0.55rem 1.3rem; font: inherit; font-weight: 700; color: #fff; background: var(--accent, #9b1131); border: 0; border-radius: 8px; cursor: pointer; }
.site-footer__newsletter-form button:hover { filter: brightness(1.12); }
.site-footer__newsletter-form button:focus-visible { outline: 2px solid #f99759; outline-offset: 2px; }
.site-footer .site-footer__newsletter-hint { grid-column: 1 / -1; font-size: 0.78rem; color: rgba(255, 255, 255, 0.55); }
.site-footer .site-footer__newsletter-hint a { text-decoration: underline; }
.site-footer__social { list-style: none; margin: 0 0 1.4rem; padding: 0; display: flex; justify-content: center; flex-wrap: wrap; gap: 0.5rem; }
.site-footer__social a { display: inline-grid; place-items: center; width: 2.75rem; height: 2.75rem; border-radius: 999px; color: rgba(255, 255, 255, 0.8); background: rgba(255, 255, 255, 0.07); border: 1px solid rgba(255, 255, 255, 0.14); transition: background-color .15s, color .15s; }
.site-footer__social a:hover, .site-footer__social a:focus-visible { color: #fff; background: var(--accent); border-color: var(--accent); }
