﻿/* =====================================================================
   seminar.css – Ergänzungen des Seminarportals zum gemeinsamen Stylesheet der Lehreinheit
   (theme.css, layout.css, account.css werden unverändert übernommen).
   Farben ausschließlich über die Variablen aus theme.css (--up-*, --bs-*), damit Hell/Dunkel stimmt.
   ===================================================================== */

/* ---------- Seitenkopf und Inhaltsbreite ---------- */
.page-head { padding: 1.25rem 0 .75rem; border-bottom: 1px solid var(--bs-border-color); margin-bottom: 1.25rem; }
.page-head h1 { font-size: clamp(1.4rem, 1.1rem + 1.4vw, 2rem); margin: 0; }
.page-head .page-sub { color: var(--bs-secondary-color); margin: .25rem 0 0; }
.page-head .page-actions { display: flex; flex-wrap: wrap; gap: .5rem; }
.breadcrumb { --bs-breadcrumb-divider: '›'; font-size: .9rem; margin-bottom: .35rem; }
.content-narrow { max-width: 52rem; }

/* ---------- Kacheln (Startseite, Übersichten) – wie Kurskacheln der Lehreinheit ---------- */
.tile-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(17rem, 1fr)); gap: 1rem; }
.tile { position: relative; display: flex; gap: 1rem; align-items: flex-start; padding: 1rem 1.1rem; border: 1px solid var(--bs-border-color); border-radius: .875rem; background: var(--bs-body-bg); color: var(--bs-body-color); text-decoration: none; box-shadow: var(--up-shadow); transition: transform .15s ease, border-color .15s; }
a.tile:hover, a.tile:focus-visible { transform: translateY(-2px); border-color: var(--up-orange); color: var(--bs-body-color); }
.tile .tile-icon { flex: 0 0 3rem; width: 3rem; height: 3rem; border-radius: .75rem; display: grid; place-items: center; background: var(--up-soft); color: var(--up-orange-icon); font-size: 1.35rem; }
.tile .tile-title { font-weight: 700; line-height: 1.3; }
.tile .tile-meta { font-size: .875rem; color: var(--bs-secondary-color); }
.tile .tile-cta { font-size: .875rem; font-weight: 700; color: var(--up-accent); }
.tile.is-muted { box-shadow: none; background: var(--bs-tertiary-bg); }
.tile .stretched-link::after { border-radius: .875rem; }

/* Kennzahlen */
.stat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(10rem, 1fr)); gap: .75rem; }
.stat { padding: .85rem 1rem; border: 1px solid var(--bs-border-color); border-radius: .75rem; background: var(--bs-body-bg); }
.stat .stat-value { font-size: 1.6rem; font-weight: 700; line-height: 1.1; }
.stat .stat-label { font-size: .85rem; color: var(--bs-secondary-color); }
.stat.is-warning { border-color: var(--bs-warning-border-subtle); background: var(--bs-warning-bg-subtle); }

/* ---------- Ablauf einer Seminarteilnahme (Schritte) ---------- */
.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: .5rem; counter-reset: schritt; }
.steps > li { counter-increment: schritt; position: relative; padding: .7rem 1rem .7rem 3.25rem; border: 1px solid var(--bs-border-color); border-radius: .75rem; background: var(--bs-body-bg); }
.steps > li::before { content: counter(schritt); position: absolute; left: .85rem; top: .7rem; width: 1.75rem; height: 1.75rem; border-radius: 50%; display: grid; place-items: center; font-weight: 700; font-size: .9rem; background: var(--up-track); color: var(--bs-body-color); }
.steps > li.is-done::before { content: '✓'; background: #2f7d32; color: #fff; }
.steps > li.is-current { border-color: var(--up-orange); box-shadow: inset 4px 0 0 var(--up-orange); }
.steps > li.is-current::before { background: var(--up-orange); color: var(--up-on-orange); }
.steps .step-title { font-weight: 700; }
.steps .step-meta { font-size: .875rem; color: var(--bs-secondary-color); }

/* Frist mit Restzeit */
.deadline { display: inline-flex; align-items: center; gap: .4rem; padding: .25rem .6rem; border-radius: 999px; background: var(--up-soft); font-weight: 600; font-size: .9rem; }
.deadline.is-urgent { background: var(--bs-danger-bg-subtle); color: var(--bs-danger-text-emphasis); }
.deadline.is-over { background: var(--bs-secondary-bg); color: var(--bs-secondary-color); }

/* ---------- Hinweise ---------- */
.hint-box { display: flex; align-items: flex-start; gap: .75rem; padding: .85rem 1rem; border-radius: .75rem; background: var(--up-soft); border: 1px solid var(--bs-primary-border-subtle); }
.hint-box > .fa-fw { font-size: 1.3rem; flex: 0 0 auto; color: var(--up-orange-icon); margin-top: .1rem; }
.hint-box > div { flex: 1 1 auto; min-width: 0; }
.hint-box.is-danger { background: var(--bs-danger-bg-subtle); border-color: var(--bs-danger-border-subtle); }
.hint-box.is-danger > .fa-fw { color: var(--bs-danger-text-emphasis); }
.impersonation-bar { background: #7a2e00; color: #fff; padding: .5rem 1rem; display: flex; flex-wrap: wrap; align-items: center; gap: .75rem; justify-content: center; font-weight: 600; }
.impersonation-bar .btn { --bs-btn-color: #fff; --bs-btn-border-color: #fff; --bs-btn-hover-bg: #fff; --bs-btn-hover-color: #7a2e00; }

/* ---------- Formulare ---------- */
.form-section { border: 1px solid var(--bs-border-color); border-radius: .875rem; padding: 1rem 1.25rem 1.25rem; margin-bottom: 1.25rem; background: var(--bs-body-bg); }
.form-section > h2, .form-section > legend { font-size: 1.15rem; font-weight: 700; margin-bottom: .75rem; float: none; width: auto; padding: 0; }
.form-text { color: var(--bs-secondary-color); }
.required-mark { color: var(--bs-danger-text-emphasis); margin-left: .15rem; }
.action-bar { position: sticky; bottom: 0; z-index: 10; display: flex; flex-wrap: wrap; gap: .5rem; justify-content: flex-end; padding: .75rem 0; margin-top: 1rem; background: color-mix(in srgb, var(--bs-body-bg) 92%, transparent); border-top: 1px solid var(--bs-border-color); }
.is-dirty-hint { display: none; }
form.is-dirty .is-dirty-hint { display: inline-flex; }

/* ---------- Hochladen mit Fortschritt ---------- */
.dropzone { position: relative; border: 2px dashed var(--up-grey); border-radius: .875rem; padding: 1.25rem; text-align: center; background: var(--bs-tertiary-bg); transition: border-color .15s, background .15s; }
.dropzone.is-over { border-color: var(--up-orange); background: var(--up-soft); }
.dropzone input[type=file] { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.dropzone .dz-icon { font-size: 2rem; color: var(--up-orange-icon); }
.upload-progress { height: .75rem; margin-top: .75rem; }
.file-list { list-style: none; padding: 0; margin: 0; display: grid; gap: .5rem; }
.file-list > li { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem .75rem; padding: .55rem .75rem; border: 1px solid var(--bs-border-color); border-radius: .6rem; }
.file-list .file-name { font-weight: 600; word-break: break-word; }
.file-list .file-meta { font-size: .85rem; color: var(--bs-secondary-color); }
.file-list .file-actions { margin-left: auto; display: flex; gap: .35rem; }

/* ---------- Tabellen (DataTables) ---------- */
.table-wrap { border: 1px solid var(--bs-border-color); border-radius: .75rem; padding: .5rem .75rem; background: var(--bs-body-bg); }
.table > :not(caption) > * > * { padding: .55rem .6rem; }
.table thead th { font-size: .85rem; text-transform: uppercase; letter-spacing: .03em; color: var(--bs-secondary-color); white-space: nowrap; }
div.dt-container .dt-search input { min-width: 14rem; }
div.dt-container .dt-paging .page-link { border-radius: 999px; margin: 0 .1rem; }
.table .col-actions { width: 1%; white-space: nowrap; text-align: right; }

/* ---------- Runde Symbol-Schaltflächen und Badges (wie Lehreinheit) ---------- */
.btn.rounded-circle { display: inline-flex; align-items: center; justify-content: center; flex: 0 0 auto; width: 2.5rem; height: 2.5rem; padding: 0; border-radius: 50%; line-height: 1; }
.btn.rounded-circle.btn-sm { width: 2rem; height: 2rem; font-size: .875rem; }
.btn.rounded-circle .fa-fw { width: auto; margin: 0; }
.badge { display: inline-flex; align-items: center; justify-content: center; align-self: center; }
.badge-soft { background: var(--up-soft); color: var(--bs-emphasis-color); border: 1px solid var(--bs-primary-border-subtle); }

/* ---------- Dialoge und Fortschritt ---------- */
.modal-content { border-radius: 1rem; }
.modal-header { border-bottom-color: var(--bs-border-color); }
.confirm-details { margin: .5rem 0 0; padding-left: 1.2rem; }
.busy-overlay { position: fixed; inset: 0; z-index: 2050; display: none; align-items: center; justify-content: center; background: rgba(17, 19, 24, .35); }
.busy-overlay.is-visible { display: flex; }
.busy-overlay .busy-card { background: var(--bs-body-bg); color: var(--bs-body-color); border-radius: 1rem; padding: 1.25rem 1.5rem; min-width: min(24rem, 90vw); box-shadow: 0 10px 40px rgba(0, 0, 0, .3); }

/* ---------- Fragen und Mitteilungen ---------- */
.thread { border: 1px solid var(--bs-border-color); border-radius: .75rem; padding: .75rem 1rem; background: var(--bs-body-bg); }
.thread + .thread { margin-top: .75rem; }
.thread .reply { margin: .6rem 0 0 1rem; padding-left: .75rem; border-left: 3px solid var(--up-track); }
.thread .meta { font-size: .85rem; color: var(--bs-secondary-color); }
.rich-text img { max-width: 100%; height: auto; }

/* Datenschutzfreundliche Videoeinbettung (Zwei-Klick-Lösung) */
.video-consent { aspect-ratio: 16 / 9; display: grid; place-items: center; text-align: center; padding: 1rem; border-radius: .875rem; background: var(--bs-tertiary-bg); border: 1px solid var(--bs-border-color); }
.video-frame { aspect-ratio: 16 / 9; width: 100%; border: 0; border-radius: .875rem; }

@media print {
    .action-bar, .page-actions, .impersonation-bar, .dt-search, .dt-paging, .dt-length { display: none !important; }
}

/* ---------- Rechtstexte (Impressum, Datenschutz, Barrierefreiheit) – wie KI-Portal ---------- */
.text-brand { color: var(--up-accent) !important; }
.prose { max-width: 75ch; }
.font-tabular { font-variant-numeric: tabular-nums; }
.legal section[id], .legal [id].accordion-collapse { scroll-margin-top: calc(var(--hdr-h) + 1.5rem); }
.legal details > summary { cursor: pointer; }
.toc { position: sticky; top: calc(var(--hdr-h) + 1.5rem); }
.toc .nav-link { padding: .3rem .75rem; color: var(--bs-secondary-color); border-left: 2px solid var(--bs-border-color); font-size: .875rem; }
.toc .nav-link:hover { color: var(--bs-body-color); }
.toc .nav-link.active { color: var(--up-accent); border-left-color: var(--up-orange); font-weight: 600; }
.proc { display: grid; grid-template-columns: max-content 1fr; gap: .35rem 1rem; }
.proc dt { font-weight: 600; color: var(--bs-secondary-color); }
.proc dd { margin: 0; }
@media (max-width: 575.98px) { .proc { grid-template-columns: 1fr; gap: .1rem; } .proc dd { margin-bottom: .5rem; } }
.callout { padding: 1.25rem 1.5rem; border: 1px solid var(--bs-border-color); border-left: 4px solid var(--up-orange); border-radius: var(--bs-border-radius-lg); background: color-mix(in srgb, var(--up-orange) 6%, var(--bs-body-bg)); }
.legal .accordion { --bs-accordion-bg: var(--bs-body-bg); }
