/* ==========================================================================
   Seiten – Frontend
   ========================================================================== */

.seiten-module .content-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 16px;
}

/* ── Gruppen-Übersicht ────────────────────────────────────────────────── */
.seiten-group-title {
    font-size: 1.05rem;
    font-weight: 700;
    margin: 0 0 10px;
    color: var(--text-primary, #111);
}

.seiten-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.seiten-list-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 8px 10px;
    border-radius: var(--radius, 5px);
    transition: background var(--transition, 0.15s);
}

.seiten-list-item:hover {
    background: var(--bg-light, #f5f5f5);
}

.seiten-link {
    font-weight: 600;
    color: var(--primary, #0066cc);
    text-decoration: none;
    flex: 1;
}

.seiten-link:hover { text-decoration: underline; }

.seiten-meta {
    font-size: 0.8rem;
    color: var(--text-secondary, #888);
    white-space: nowrap;
}

/* ── Einzel-Seite ─────────────────────────────────────────────────────── */
.seiten-page-title {
    margin: 0 0 16px;
    font-size: 1.4rem;
    color: var(--text-primary, #111);
}

.seiten-body {
    line-height: 1.65;
    color: var(--text-primary, #111);
}

/* TinyMCE-Inhalt normalisieren */
.seiten-body h1 { font-size: 1.4rem; margin: 1.2em 0 0.5em; }
.seiten-body h2 { font-size: 1.2rem; margin: 1em 0 0.4em; }
.seiten-body h3 { font-size: 1rem;   margin: 0.9em 0 0.3em; }
.seiten-body p  { margin: 0.6em 0; }
.seiten-body ul,
.seiten-body ol { margin: 0.6em 0 0.6em 1.4em; }
.seiten-body li { margin: 4px 0; }
.seiten-body table {
    border-collapse: collapse;
    width: 100%;
    margin: 0.8em 0;
}
.seiten-body table th,
.seiten-body table td {
    border: 1px solid var(--border, #ddd);
    padding: 6px 10px;
    text-align: left;
}
.seiten-body table th {
    background: var(--bg-light, #f5f5f5);
    font-weight: 700;
}
.seiten-body img {
    max-width: 100%;
    height: auto;
    border-radius: var(--radius, 4px);
}
.seiten-body a {
    color: var(--primary, #0066cc);
}

/* ── Breadcrumb ──────────────────────────────────────────────────────── */
.breadcrumb {
    font-size: 0.88rem;
    color: var(--text-secondary, #888);
}
.breadcrumb a {
    color: var(--primary, #0066cc);
    text-decoration: none;
}
.breadcrumb a:hover { text-decoration: underline; }

/* ── Leer-Zustand ────────────────────────────────────────────────────── */
.seiten-empty p {
    text-align: center;
    color: var(--text-secondary, #999);
    padding: 24px 0;
}

/* ── Dark Mode ───────────────────────────────────────────────────────── */
html[data-theme="dark"] .seiten-list-item:hover {
    background: var(--bg-light, #2a2a2a);
}
html[data-theme="dark"] .seiten-body table th {
    background: var(--bg-light, #2a2a2a);
}
