/* woc-app.css
   Mobile-Version des World-of-Coaching-Stylesheets fuer /de/app/woc/.
   Portiert aus /de/woc/includes/woc-style.css, angepasst an die
   402px-Mobile-Spalte von mobile.css (var(--accent), var(--text) usw.),
   plus Ersatz fuer Bootstrap-Klassen (ratio, btn, Abstands-Utilities),
   die im Desktop-Theme global verfuegbar sind, in der App aber fehlen. */

.woc-content { line-height: 1.65; max-width: 343px; margin: 0 auto; font-size: 14px; }

/* Mobile-Ersatz fuer die Desktop-Sidebar: da es keinen Platz fuer eine
   permanente Seitenleiste gibt, gibt es stattdessen eine schmale
   Navigationsleiste ganz oben auf jeder WoC-Seite (Home / Alle Kurse /
   aufklappbares Menue mit den restlichen Bereichen). */
.woc-mobile-nav {
    display: flex; align-items: center; flex-wrap: wrap; gap: 10px;
    margin: 0 0 16px; padding-bottom: 12px; border-bottom: 1px solid var(--line, #eee);
    font-size: 12px; font-weight: 700;
}
.woc-mobile-nav a { color: var(--accent, #ff6d24); text-decoration: none; }
.woc-mobile-nav__home { color: var(--muted, #888) !important; }
.woc-mobile-nav__more { position: relative; margin-left: auto; }
.woc-mobile-nav__more summary { list-style: none; cursor: pointer; color: var(--accent, #ff6d24); }
.woc-mobile-nav__more summary::-webkit-details-marker { display: none; }
.woc-mobile-nav__more ul {
    position: absolute; right: 0; top: 22px; z-index: 20; margin: 0; padding: 8px 0;
    list-style: none; background: #fff; border: 1px solid #ececec; border-radius: 10px;
    box-shadow: 0 6px 18px rgba(0,0,0,0.12); width: 230px; max-width: 78vw;
    max-height: 70vh; overflow-y: auto;
}
.woc-mobile-nav__more li a { display: block; padding: 9px 16px; color: var(--text, #16182b) !important; font-weight: 600; }
.woc-mobile-nav__more li a:hover { background: #fff8f2; color: var(--accent, #ff6d24) !important; }
.woc-mobile-nav__more ul.woc-mobile-nav__sub {
    position: static; box-shadow: none; border: none; width: auto; max-width: none;
    background: #fafafa; margin: 0 0 4px; padding: 2px 0;
}
.woc-mobile-nav__more ul.woc-mobile-nav__sub li a { padding: 7px 16px 7px 28px; font-weight: 500; font-size: 12px; color: var(--muted, #666) !important; }
.woc-mobile-nav__more ul.woc-mobile-nav__sub li a:hover { color: var(--accent, #ff6d24) !important; }

/* Willkommen/Ausbildungen/Bibliothek sind jetzt eigene Aufklapp-Punkte
   innerhalb von "Mehr" - standardmaessig eingeklappt, nicht permanent
   sichtbar. Der Name selbst bleibt ein Link zur Uebersichtsseite,
   der kleine Pfeil daneben klappt die Unterpunkte auf/zu. */
.woc-mobile-nav__group > details > summary { list-style: none; display: flex; align-items: center; justify-content: space-between; padding: 0; }
.woc-mobile-nav__group > details > summary::-webkit-details-marker { display: none; }
.woc-mobile-nav__group > details > summary > a { flex: 1; padding: 9px 16px; }
.woc-mobile-nav__caret { padding: 9px 16px 9px 6px; color: var(--muted, #999); font-size: 10px; transition: transform 0.15s ease; }
.woc-mobile-nav__group > details[open] .woc-mobile-nav__caret { transform: rotate(180deg); }
.woc-mobile-nav__group > details > ul.woc-mobile-nav__sub { margin: 0 0 4px; }

.woc-content img { max-width: 100% !important; width: auto !important; height: auto !important; border-radius: 8px; }

/* Normale Links im Lektions-/Kurstext (z.B. ">> Zu den Aufzeichnungen...")
   sahen wie schwarzer Fliesstext aus, weil die App global Links ohne
   Farbe/Unterstreichung darstellt. Eigene Komponenten (Navigation,
   Material-Kacheln, Kursliste, Tabs, Buttons) haben ihre eigene Farbe
   und werden dadurch nicht veraendert. */
:where(.woc-content p, .woc-content li, .woc-content td) a {
    color: var(--accent, #ff6d24);
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 2px;
}
:where(.woc-content p, .woc-content li, .woc-content td) a:hover { opacity: 0.85; }
.woc-content h1.title { font-weight: 800; font-size: 22px; line-height: 1.25; margin: 0 0 14px; }
.woc-content h2 { margin-top: 30px; margin-bottom: 12px; font-weight: 700; font-size: 19px; line-height: 1.3; }
.woc-content h3 { margin-top: 22px; margin-bottom: 8px; font-weight: 600; font-size: 16px; line-height: 1.3; }
.woc-content p { margin: 0 0 14px; }
.woc-content ul, .woc-content ol { padding-left: 20px; margin: 0 0 14px; }
.woc-content .wp-block-list { list-style: disc; }

/* Bootstrap-Ersatz: Video-Einbettung mit fixem Seitenverhaeltnis */
.ratio { position: relative; width: 100%; }
.ratio-16x9::before { display: block; padding-top: 56.25%; content: ""; }
.ratio iframe, .ratio video, .ratio embed, .ratio object {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%; border: 0; border-radius: 10px; background: #000;
}
.my-3 { margin-top: 16px; margin-bottom: 16px; }

/* Bootstrap-Ersatz: Abstands-Utilities (Literalwerte wie im Original) */
.mb-15 { margin-bottom: 15px; } .mb-20 { margin-bottom: 20px; } .mb-25 { margin-bottom: 25px; } .mb-30 { margin-bottom: 30px; }
.mt-15 { margin-top: 15px; } .mt-25 { margin-top: 25px; } .mt-30 { margin-top: 30px; }
.pt-40 { padding-top: 40px; } .pt-60 { padding-top: 60px; }
.pb-60 { padding-bottom: 60px; }
.p-20 { padding: 20px; }

/* Bootstrap-Ersatz: Buttons */
.btn {
    display: inline-flex; align-items: center; justify-content: center;
    padding: 11px 22px; border-radius: 999px; font-weight: 700; font-size: 13px;
    line-height: 1.2; text-decoration: none; cursor: pointer; border: none;
}
.btn-primary { background: var(--accent, #f28e00); color: #fff !important; }
.btn-primary:hover { opacity: 0.9; }
a.btn-outline-secondary {
    border: 1.5px solid var(--line, #d8d8d8) !important;
    background: transparent !important;
    color: var(--muted, #6b6b6f) !important;
}
a.btn-outline-secondary:hover { border-color: var(--accent, #ff6d24) !important; color: var(--accent, #ff6d24) !important; }

/* Kurs-Uebersichtsseite (Kacheln) */
.woc-course-grid { display: grid; grid-template-columns: 1fr; gap: 14px; }
.woc-course-card { border: 1px solid #eee; border-radius: 10px; overflow: hidden; background: #fff; }
.woc-course-card__thumb { height: 110px; background-size: cover; background-position: center; background-color: #16223f; }
.woc-course-card__body { padding: 12px 14px; }
.woc-course-card__title { font-size: 15px; font-weight: 700; margin: 0 0 6px; }
.woc-course-card__meta { font-size: 12px; color: #777; }

/* Lektionsliste innerhalb eines Kurses */
ul.imported-page-outline { list-style: none; margin: 0; padding: 0; }
ul.imported-page-outline > li,
ul.imported-page-outline--nested > li {
    background: #f7f7f8; border: 1px solid #ececec; border-radius: 8px;
    margin-bottom: 8px; padding: 12px 14px !important; list-style: none;
    display: flex; align-items: center; gap: 8px; font-size: 13px;
}
ul.imported-page-outline li a { text-decoration: none; color: var(--text, #16182b); font-weight: 600; }
ul.imported-page-outline li.lp-lesson-done a { color: #2e9e4f; }

.woc-topic-list { list-style: none; margin: 6px 0 0 0; padding: 0; }
.woc-topic-list li a { font-weight: 400; font-size: 13px; }
.woc-topics-in-lesson { margin: 10px 0 20px; }

.imported-page-nav { margin-bottom: 16px; font-size: 13px; }
.imported-page-nav a { color: var(--accent, #ff6d24); text-decoration: none; font-weight: 700; }

/* Akkordeon (Module mit Unterthemen) */
.woc-accordion { border: 1px solid #eee; border-radius: 10px; margin-bottom: 12px; overflow: hidden; }
.woc-accordion summary {
    list-style: none; cursor: pointer; padding: 12px 16px; font-weight: 800;
    color: #e8631c; font-size: 13px; background: #fff8f2;
    display: flex; align-items: center; justify-content: space-between;
}
.woc-accordion summary::-webkit-details-marker { display: none; }
.woc-accordion summary::after { content: '\25BE'; font-size: 0.9rem; color: #e8631c; margin-left: 10px; }
.woc-accordion[open] > summary::after { transform: rotate(180deg); }
.woc-accordion > ul.imported-page-outline { padding: 4px 14px 8px; }

li.woc-item-with-children { padding: 0 !important; border: 1px solid #ececec; background: #f7f7f8; border-radius: 8px; }
li.woc-item-with-children details { border: none; margin: 0; width: 100%; }
li.woc-item-with-children summary {
    list-style: none; cursor: pointer; padding: 12px 14px;
    display: flex; align-items: center; justify-content: space-between; font-size: 13px;
}
li.woc-item-with-children summary::-webkit-details-marker { display: none; }
li.woc-item-with-children summary::after { content: '\25BE'; font-size: 0.8rem; color: #999; margin-left: 10px; flex-shrink: 0; }
li.woc-item-with-children details[open] summary::after { transform: rotate(180deg); }
li.woc-item-with-children summary a { font-weight: 600; color: var(--text, #16182b); text-decoration: none; }
li.woc-item-with-children ul.imported-page-outline--nested { margin: 8px 0 10px 4px; }

/* Titelbild + Info-Karte auf Kursseiten (im Hochformat untereinander) */
.woc-hero-wrapper { display: flex; flex-direction: column; gap: 14px; margin-bottom: 22px; }
.woc-hero {
    position: relative; min-height: 190px; background-size: cover; background-position: center;
    border-radius: 12px; display: flex; align-items: flex-end; overflow: hidden;
}
.woc-hero__overlay { width: 100%; padding: 18px 20px; background: linear-gradient(0deg, rgba(0,0,0,0.72) 0%, rgba(0,0,0,0.15) 70%, rgba(0,0,0,0) 100%); }
.woc-hero__eyebrow { color: #ffb37a; font-weight: 700; letter-spacing: 1px; font-size: 11px; margin-bottom: 6px; text-transform: uppercase; }
.woc-hero__title { color: #fff; font-size: 22px; font-weight: 800; margin: 0; line-height: 1.2; }
.woc-hero--plain { background: linear-gradient(135deg, #16223f, #2a3a63); align-items: center; padding: 20px; min-height: 110px; }
.woc-hero--plain .woc-hero__title { padding: 0; }

.woc-info-card {
    display: flex; flex-direction: column; background: #fff; border-radius: 12px; overflow: hidden;
    box-shadow: 0 6px 16px rgba(0,0,0,0.12); border: 1px solid #f0f0f0;
}
.woc-info-card img { display: block; width: 100%; max-height: 160px; object-fit: cover; margin: 0; }
.woc-info-card__title { padding: 12px 14px 4px; font-size: 14px; font-weight: 700; color: var(--text, #16182b); line-height: 1.35; }
.woc-info-card__cta {
    display: block; margin: 12px 14px; padding: 11px 14px; text-align: center;
    background: var(--accent, #ff6d24); color: #fff !important; font-weight: 700;
    border-radius: 8px; text-decoration: none; font-size: 13px;
}
.woc-info-card__includes { margin: 0 14px 14px; padding-top: 10px; border-top: 1px solid #f0f0f0; font-size: 12px; color: #444; list-style: none; }
.woc-info-card__includes li { padding: 3px 0; }

/* Tab-Leiste "Lektion" / "Materials" */
.woc-tabs { display: inline-flex; gap: 0; background: #f0f0f1; padding: 4px; border-radius: 999px; border: none !important; margin: 4px 0 20px; }
button.woc-tab-btn {
    background: transparent !important; border: none !important; outline: none !important; box-shadow: none !important;
    border-radius: 999px !important; padding: 8px 16px !important; font-weight: 700 !important; font-size: 13px !important;
    color: var(--muted, #6b6b6f) !important; cursor: pointer;
}
button.woc-tab-btn.is-active { background: #fff !important; color: var(--accent, #ff6d24) !important; box-shadow: 0 1px 4px rgba(0,0,0,0.12) !important; }
.woc-tab-panel[hidden] { display: none; }

.woc-materials { padding: 4px 0; }
.woc-materials strong { display: block; margin-bottom: 10px; color: #555; font-weight: 700; font-size: 13px; }
.woc-materials a {
    display: block; padding: 12px 14px; margin-bottom: 8px; background: #f7f7f8; border: 1px solid #ececec;
    border-radius: 8px; color: var(--text, #16182b); font-weight: 600; text-decoration: none; font-size: 13px;
}
.woc-materials a:hover { background: #fff8f2; border-color: #ffb37a; }
.woc-materials a::before { content: '\1F4C4  '; }

/* "Als vollstaendig markieren"-Button */
button.woc-complete-btn {
    background: var(--accent, #ff6d24) !important; color: #fff !important; border: none !important; outline: none !important;
    box-shadow: none !important; padding: 12px 20px !important; border-radius: 999px !important; font-weight: 700 !important;
    font-size: 13px !important; line-height: 1.2 !important; display: inline-flex !important; align-items: center !important; cursor: pointer;
}
button.woc-complete-btn::before { content: '\2713  '; }
button.woc-complete-btn.is-done { background: #2e9e4f !important; }

.woc-lesson-actions { margin-top: 20px; display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
/* "Test zu dieser Lektion"-Links sahen wie normaler Fließtext aus (der
   globale Mobile-Reset macht Links standardmaessig schwarz/ohne
   Unterstreichung) - jetzt deutlich als antippbarer Button erkennbar. */
.woc-quiz-links { font-size: 13px; }
.woc-quiz-links ul { list-style: none; padding: 0; margin: 8px 0 0; display: flex; flex-direction: column; gap: 8px; }
.woc-quiz-links li { display: block; }
.woc-quiz-links a {
    display: inline-flex; align-items: center; gap: 6px;
    background: var(--accent, #ff6d24); color: #fff !important;
    padding: 10px 16px; border-radius: 999px; font-weight: 700; font-size: 13px;
    text-decoration: none !important;
}
.woc-quiz-links a::before { content: '\1F4DD  '; }
.woc-quiz-links a:hover { opacity: 0.9; }

/* Quiz-Fortschrittsbalken */
.woc-progressbar { background: #eee; border-radius: 6px; height: 10px; overflow: hidden; margin: 6px 0; }
.woc-progressbar__fill { background: var(--accent, #ff6d24); height: 100%; }

/* WordPress-Bloecke aus dem Original-Export.
   Erst versuchen die Zellen normal umzubrechen (bei den meist kurzen
   Tabellen wie Terminuebersichten reicht die Spaltenbreite dann aus) -
   nur wenn eine Tabelle trotzdem zu breit ist, wird sie horizontal
   scrollbar statt abgeschnitten. */
.woc-content table {
    display: block; width: 100%; max-width: 100%; overflow-x: auto;
    -webkit-overflow-scrolling: touch; border-collapse: collapse; margin: 14px 0 20px; font-size: 13px;
}
.woc-content table td, .woc-content table th {
    padding: 10px; border-bottom: 1px solid #eee; text-align: left;
    white-space: normal; word-break: break-word; vertical-align: top; min-width: 90px;
}
.woc-content table tr:nth-child(odd) td { background: #f9f9f9; }
.woc-content table tr:first-child td { font-weight: 700; background: #f7f7f7; }
.wp-block-table { max-width: 100%; overflow-x: auto; }
.wp-block-table figcaption { font-size: 12px; color: var(--muted, #777); margin-top: 6px; }

.wp-block-media-text { display: flex; flex-direction: column; gap: 12px; margin: 16px 0; }
.wp-block-media-text__media img { border-radius: 8px; }

.wp-block-columns { display: flex; flex-direction: column; gap: 16px; margin: 14px 0; }

.wp-block-video { margin: 16px 0; }
.wp-block-video video { width: 100%; height: auto; max-width: 100%; border-radius: 10px; background: #000; display: block; }

/* Browser-Standard fuer <figure> ist margin:1em 40px - dadurch wirkten
   die WordPress-Video-Einbettungen viel schmaler als die Vimeo-Videos,
   die in einem einfachen <div class="ratio ratio-16x9"> stecken (kein
   Default-Margin). Hier auf denselben vollen Spaltenbreite gebracht. */
.wp-block-embed { margin: 16px 0; width: 100%; max-width: 100%; }
.wp-block-embed__wrapper { position: relative; width: 100%; padding-bottom: 56.25%; height: 0; margin: 0; border-radius: 10px; overflow: hidden; background: #000; }
.wp-block-embed__wrapper iframe { position: absolute; top: 0; left: 0; width: 100% !important; height: 100% !important; border: 0; }

.wp-block-image { display: flex !important; flex-direction: column; align-items: center !important; text-align: center; margin: 16px auto !important; float: none !important; }
.wp-block-image.alignright, .wp-block-image.alignleft, .wp-block-image.aligncenter { float: none !important; }
.wp-block-image img { width: auto !important; max-width: 100% !important; height: auto !important; display: block !important; margin: 0 auto !important; border-radius: 8px; }
.wp-element-caption { font-size: 12px; color: var(--muted, #777); margin-top: 6px; }

.wp-block-file { margin: 14px 0; display: flex; flex-wrap: wrap; align-items: center; gap: 10px; font-size: 13px; }
.wp-block-file__button, a.wp-element-button {
    display: inline-block; padding: 7px 14px; background: var(--accent, #f28e00); color: #fff !important;
    border-radius: 6px; font-size: 12px; font-weight: 700; text-decoration: none;
}

.wp-block-quote { margin: 16px 0; padding: 4px 0 4px 14px; border-left: 3px solid var(--accent, #f28e00); font-style: italic; color: #444; }
.wp-block-separator { border: none; border-top: 1px solid var(--line, #ddd); margin: 22px 0; }
.text-muted { color: #6c757d; }
