/* =========================================================
   Themenwelten: Artikel-Detailansicht (Premium Leseerlebnis)
   ========================================================= */

.themenwelt-article-detail {
    display: flex;
    flex-direction: column;
    padding-bottom: 4rem;
}

/* --- KOPFBEREICH & TITEL --- */
.themenwelt-article-detail__header {
    text-align: center;
    max-width: 54rem;
    margin: 0 auto 2rem auto;
    padding: 0 1rem;
}

.themenwelt-article-detail__title {
    font-size: clamp(2rem, 5vw, 3.5rem);
    font-weight: 800;
    line-height: 1.15;
    color: var(--rw-color-ocean);
    margin-top: 1rem;
    margin-bottom: 1.5rem;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

/* --- METADATEN (Autor, Datum, etc.) --- */
.themenwelt-article-detail__meta {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1.5rem;
    color: #64748b; /* Dezentes Grau */
    font-size: 0.95rem;
    font-weight: 500;
    margin-bottom: 1rem;
}

.themenwelt-article-detail__meta-item {
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.themenwelt-article-detail__meta-item a {
    color: inherit;
    text-decoration: none;
    transition: color 0.2s ease;
}

.themenwelt-article-detail__meta-item a:hover {
    color: var(--rw-color-ocean);
    text-decoration: underline;
}

.themenwelt-article-detail__meta-item [class^="icon-"], 
.themenwelt-article-detail__meta-item [class*=" icon-"] {
    font-size: 1.1em;
    opacity: 0.8;
}

/* --- HERO BILD --- */
.themenwelt-article-detail__hero-image {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto 3rem auto;
}

.themenwelt-article-detail__hero-image img {
    display: block;
    width: 100%;
    height: auto;
    max-height: 75vh;
    object-fit: cover;
    border-radius: 0.75rem;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.05);
}

.themenwelt-article-detail__hero-image figcaption {
    text-align: center;
    font-size: 0.85rem;
    color: #94a3b8;
    margin-top: 0.75rem;
    font-style: italic;
}

/* --- ARTIKEL TEXT (Der Lesebereich) --- */
.themenwelt-article-detail__content {
    width: 100%;
}

.themenwelt-article-detail__text {
    max-width: 45rem; /* ~720px - Perfekte Lesebreite (65-75 Zeichen pro Zeile) */
    margin: 0 auto;
    font-size: 1.125rem; /* 18px */
    line-height: 1.8;
    color: #334155;
    padding: 0 1.25rem;
}

/* Typografie im Fließtext (Magazin-Stil) */
.themenwelt-article-detail__text {
    font-family: 'Merriweather', Georgia, 'Times New Roman', serif; /* Elegante Serifenschrift für perfekten Lesefluss */
}

/* Drop-Cap (Initiale) für den ersten Absatz, wie bei großen Magazinen */
.themenwelt-article-detail__text > p:first-of-type::first-letter {
    float: left;
    font-size: 4.5rem;
    line-height: 0.8;
    padding-top: 0.2rem;
    padding-right: 0.5rem;
    font-weight: 700;
    color: var(--rw-color-ocean);
}

.themenwelt-article-detail__text p {
    margin-bottom: 1.75rem;
}

.themenwelt-article-detail__text h2,
.themenwelt-article-detail__text h3,
.themenwelt-article-detail__text h4 {
    font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif; /* Überschriften bleiben modern */
    color: var(--rw-color-ocean);
    margin-top: 3rem;
    margin-bottom: 1.2rem;
    font-weight: 800;
    line-height: 1.3;
}

.themenwelt-article-detail__text h2 {
    font-size: 2rem;
    border-bottom: 2px solid #f1f5f9;
    padding-bottom: 0.5rem;
}

.themenwelt-article-detail__text h3 {
    font-size: 1.6rem;
}

.themenwelt-article-detail__text ul,
.themenwelt-article-detail__text ol {
    margin-bottom: 1.75rem;
    padding-left: 1.5rem;
}

.themenwelt-article-detail__text li {
    margin-bottom: 0.75rem;
}

.themenwelt-article-detail__text blockquote {
    font-size: 1.35rem;
    font-style: italic;
    font-weight: 400;
    color: #334155;
    border-left: 4px solid var(--rw-color-ocean);
    margin: 2.5rem 0;
    background: #f8fafc;
    padding: 1.5rem 1.5rem 1.5rem 2rem;
    border-radius: 0 0.5rem 0.5rem 0;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.themenwelt-article-detail__text img {
    max-width: 100%;
    height: auto;
    border-radius: 0.5rem;
    margin: 1.5rem 0;
}

/* --- TAGS & PAGINATION --- */
.themenwelt-article-detail__tags,
.themenwelt-article-detail__pagination {
    max-width: 45rem;
    margin: 0 auto;
    padding: 0 1.25rem;
}

.themenwelt-article-detail__pagination {
    margin-top: 4rem;
    padding-top: 2rem;
    border-top: 1px solid #e2e8f0;
}

/* Joomla Pagination Override für schöneres Aussehen */
.themenwelt-article-detail__pagination .pagination {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 1rem;
    list-style: none;
    padding: 0;
}

.themenwelt-article-detail__pagination .pagination li a {
    display: inline-flex;
    align-items: center;
    padding: 0.75rem 1.5rem;
    background: #f8fafc;
    color: var(--rw-color-ocean);
    text-decoration: none;
    border-radius: 0.5rem;
    font-weight: 600;
    transition: all 0.2s ease;
}

.themenwelt-article-detail__pagination .pagination li a:hover {
    background: var(--rw-color-ocean);
    color: #ffffff;
    box-shadow: 0 4px 12px rgba(0, 90, 140, 0.2);
}

/* Responsive Anpassungen */
@media (max-width: 48rem) {
    .themenwelt-article-detail__title {
        font-size: 2.25rem;
    }
    
    .themenwelt-article-detail__hero-image {
        border-radius: 0;
    }
    
    .themenwelt-article-detail__hero-image img {
        border-radius: 0;
    }
    
    .themenwelt-article-detail__text {
        font-size: 1.05rem;
        padding: 0 1rem;
    }
}
