/* ==========================================================================
   Ratgeber & Fachartikel - Styles
   ========================================================================== */

/* Ratgeber Hero */
.ratgeber-hero {
    background: linear-gradient(rgba(0, 0, 0, 0.8), rgba(0, 0, 0, 0.8)), url('../images/interior-bg.jpeg');
    background-size: cover;
    background-position: center;
    text-align: center;
    padding: 60px 0;
    margin-bottom: 40px;
    border-bottom: 1px solid var(--border-color);
}

.ratgeber-hero h1 {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--white);
    margin-bottom: 15px;
}

.ratgeber-hero p {
    font-size: 1.2rem;
    color: #cccccc;
    max-width: 700px;
    margin: 0 auto;
}

/* Filters & Search Section */
.filter-search-container {
    background-color: var(--card-bg);
    padding: 25px;
    border-radius: 10px;
    box-shadow: var(--shadow);
    border: 1px solid var(--border-color);
    margin-bottom: 40px;
}

.search-box {
    position: relative;
    max-width: 600px;
    margin: 0 auto 25px auto;
}

.search-box input {
    width: 100%;
    padding: 15px 20px 15px 50px;
    font-size: 1.1rem;
    border-radius: 30px;
    border: 1px solid var(--border-color);
    background-color: var(--background-color);
    color: var(--text-color);
    font-family: 'Montserrat', sans-serif;
    transition: var(--transition);
}

.search-box input:focus {
    border-color: var(--secondary-color);
    box-shadow: 0 0 10px rgba(52, 152, 219, 0.2);
}

.search-box i {
    position: absolute;
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
    color: #888888;
    font-size: 1.2rem;
}

/* Category Filters */
.categories-filter {
    display: flex;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
}

.category-btn {
    background-color: var(--background-color);
    color: var(--text-color);
    border: 1px solid var(--border-color);
    padding: 10px 20px;
    border-radius: 20px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    font-family: 'Montserrat', sans-serif;
    transition: var(--transition);
}

.category-btn:hover {
    background-color: var(--hover-color);
    border-color: var(--secondary-color);
}

.category-btn.active {
    background-color: var(--secondary-color);
    color: var(--white);
    border-color: var(--secondary-color);
    box-shadow: 0 4px 10px rgba(52, 152, 219, 0.3);
}

/* Article Grid */
.article-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 30px;
    margin-bottom: 60px;
}

@media (min-width: 768px) {
    .article-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .article-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* Article Card */
.article-card {
    background-color: var(--card-bg);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: var(--shadow);
    border: 1px solid var(--border-color);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    height: 100%;
}

.article-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.5);
    border-color: var(--secondary-color);
}

.card-image-wrapper {
    position: relative;
    width: 100%;
    aspect-ratio: 16/10;
    overflow: hidden;
}

.card-image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.article-card:hover .card-image-wrapper img {
    transform: scale(1.05);
}

.category-badge {
    position: absolute;
    top: 15px;
    left: 15px;
    background-color: var(--secondary-color);
    color: var(--white);
    padding: 6px 12px;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    box-shadow: 0 2px 10px rgba(0,0,0,0.3);
}

.card-content {
    padding: 25px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.card-meta {
    display: flex;
    gap: 15px;
    font-size: 0.85rem;
    color: #a0a0a0;
    margin-bottom: 12px;
}

.card-meta span {
    display: flex;
    align-items: center;
    gap: 5px;
}

.card-title {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--white);
    margin-bottom: 15px;
    line-height: 1.4;
    transition: var(--transition);
}

.article-card:hover .card-title {
    color: var(--secondary-color);
}

.card-summary {
    font-size: 0.95rem;
    color: #dddddd;
    line-height: 1.6;
    margin-bottom: 25px;
    flex-grow: 1;
}

.card-btn {
    align-self: flex-start;
    background-color: transparent;
    color: var(--secondary-color);
    border: 2px solid var(--secondary-color);
    padding: 10px 20px;
    border-radius: 25px;
    font-weight: 600;
    font-size: 0.9rem;
    text-decoration: none;
    transition: var(--transition);
}

.article-card:hover .card-btn {
    background-color: var(--secondary-color);
    color: var(--white);
    box-shadow: 0 4px 15px rgba(52, 152, 219, 0.3);
}

/* ==========================================================================
   Article Detail Layout
   ========================================================================== */

.article-layout {
    max-width: 900px;
    margin: 40px auto;
    padding: 0 15px;
}

/* Article Hero Header */
.article-header {
    margin-bottom: 35px;
}

.article-category {
    display: inline-block;
    color: var(--secondary-color);
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.9rem;
    letter-spacing: 1px;
    margin-bottom: 15px;
}

.article-title {
    font-size: 2.2rem;
    font-weight: 800;
    line-height: 1.3;
    color: var(--white);
    margin-bottom: 20px;
}

@media (min-width: 768px) {
    .article-title {
        font-size: 3rem;
    }
}

.article-meta-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    padding: 15px 0;
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
    font-size: 0.9rem;
    color: #a0a0a0;
}

.article-meta-bar span {
    display: flex;
    align-items: center;
    gap: 8px;
}

.article-meta-bar i {
    color: var(--secondary-color);
}

/* Hero Image */
.article-hero-image {
    width: 100%;
    aspect-ratio: 16/9;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 40px;
    box-shadow: var(--shadow);
    border: 1px solid var(--border-color);
}

.article-hero-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Table of Contents */
.toc-box {
    background-color: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 25px;
    margin-bottom: 40px;
}

.toc-title {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--white);
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.toc-title i {
    color: var(--secondary-color);
}

.toc-list {
    list-style: none;
    padding-left: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.toc-list li {
    padding-left: 0;
}

.toc-list a {
    color: #cccccc;
    text-decoration: none;
    font-size: 0.95rem;
    transition: var(--transition);
    display: inline-block;
}

.toc-list a:hover {
    color: var(--secondary-color);
    transform: translateX(5px);
}

.toc-list .sub-item {
    padding-left: 20px;
    font-size: 0.9rem;
}

/* Article Body Content */
.article-body {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #e0e0e0;
}

.article-body h2 {
    font-size: 1.7rem;
    font-weight: 700;
    color: var(--white);
    margin-top: 45px;
    margin-bottom: 20px;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.article-body h3 {
    font-size: 1.35rem;
    font-weight: 600;
    color: var(--secondary-color);
    margin-top: 30px;
    margin-bottom: 15px;
}

.article-body p {
    margin-bottom: 25px;
}

.article-body ul, .article-body ol {
    margin-bottom: 25px;
    padding-left: 25px;
}

.article-body li {
    margin-bottom: 10px;
}

.article-body blockquote {
    background-color: var(--card-bg);
    border-left: 4px solid var(--secondary-color);
    padding: 20px;
    margin: 30px 0;
    border-radius: 0 8px 8px 0;
    font-style: italic;
    color: var(--white);
}

.article-body strong {
    color: var(--white);
}

.article-body a {
    color: var(--secondary-color);
    text-decoration: none;
    font-weight: 600;
    border-bottom: 1px dashed var(--secondary-color);
    transition: var(--transition);
}

.article-body a:hover {
    color: var(--white);
    border-bottom-style: solid;
}

/* Call To Action Box (Article Footer) */
.article-cta-box {
    background: linear-gradient(135deg, var(--primary-color) 0%, #1a252f 100%);
    border: 1px solid var(--secondary-color);
    border-radius: 12px;
    padding: 40px;
    text-align: center;
    margin: 50px 0;
    box-shadow: 0 10px 30px rgba(0,0,0,0.4);
}

.article-cta-box h3 {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--white);
    margin-bottom: 15px;
}

.article-cta-box p {
    font-size: 1.1rem;
    color: #cccccc;
    margin-bottom: 30px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.article-cta-buttons {
    display: flex;
    flex-direction: column;
    gap: 15px;
    align-items: center;
    justify-content: center;
}

@media (min-width: 768px) {
    .article-cta-buttons {
        flex-direction: row;
    }
}

.article-cta-buttons .cta-button {
    background-color: var(--secondary-color);
    color: var(--white);
    padding: 12px 30px;
    border-radius: 30px;
    font-weight: 700;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
    max-width: 100%;
    justify-content: center;
}

.article-cta-buttons .whatsapp-btn {
    background-color: #25D366;
    color: var(--white);
    padding: 12px 30px;
    border-radius: 30px;
    font-weight: 700;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
}

.article-cta-buttons .whatsapp-btn:hover {
    background-color: #128C7E;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(37,211,102,0.3);
}

.article-cta-buttons .phone-btn {
    background-color: transparent;
    border: 2px solid var(--white);
    color: var(--white);
    padding: 10px 28px;
    border-radius: 30px;
    font-weight: 700;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: var(--transition);
}

.article-cta-buttons .phone-btn:hover {
    background-color: var(--white);
    color: var(--primary-color);
}

/* Related / Navigation Section at the bottom */
.related-articles-section {
    border-top: 1px solid var(--border-color);
    padding-top: 40px;
    margin-top: 40px;
}

.related-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--white);
    margin-bottom: 25px;
}

.related-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}

@media (min-width: 768px) {
    .related-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

.back-to-overview {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--secondary-color);
    text-decoration: none;
    font-weight: 600;
    margin-bottom: 30px;
    transition: var(--transition);
}

.back-to-overview:hover {
    color: var(--white);
    transform: translateX(-5px);
}
