/* Home Page Styles */
.home-page {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Featured Article Section */
.featured-article-section {
    margin-bottom: 40px;
    background-color: #f9f9f9;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.featured-article-container {
    display: flex;
    flex-direction: row;
    min-height: 400px;
}

.featured-article-content {
    flex: 1;
    padding: 40px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.featured-article-image {
    flex: 1;
    overflow: hidden;
    position: relative;
}

.featured-article-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.featured-article-container:hover .featured-article-image img {
    transform: scale(1.05);
}

.category-badge {
    display: inline-block;
    background-color: #0e8040;
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    margin-bottom: 15px;
}

.article-title {
    font-size: 2rem;
    margin-bottom: 15px;
    color: #333;
    line-height: 1.3;
}

.article-meta {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
    color: #666;
    font-size: 0.9rem;
}

.article-date, .article-views {
    margin-right: 15px;
}

.article-author {
    display: flex;
    align-items: center;
    margin-right: 15px;
}

.author-avatar {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    margin-right: 8px;
}

.article-excerpt {
    margin-bottom: 25px;
    color: #555;
    line-height: 1.6;
}

.read-more-btn {
    display: inline-block;
    background-color: #0e8040;
    color: white;
    padding: 10px 20px;
    border-radius: 4px;
    text-decoration: none;
    font-weight: 600;
    transition: background-color 0.3s;
    align-self: flex-start;
}

.read-more-btn:hover {
    background-color: #0a6030;
}

/* Articles Carousel Section */
.articles-carousel-section {
    margin-bottom: 40px;
}

.section-header {
    margin-bottom: 25px;
    text-align: center;
    position: relative;
}

.view-all-link-container {
    text-align: right;
    margin: 20px 30px 10px;
}

/* Theme-based styling for links and buttons */
.theme-link {
    display: inline-block;
    color: var(--primary-color, #0e8040);
    font-weight: 500;
    text-decoration: none;
    transition: all 0.3s ease;
    font-size: 1rem;
    padding: 8px 16px;
    border-radius: 4px;
    background-color: transparent;
    border: 1px solid var(--primary-color, #0e8040);
}

.theme-link:hover {
    color: white;
    background-color: var(--primary-color, #0e8040);
    text-decoration: none;
}

.theme-link i {
    margin-left: 5px;
    font-size: 0.9rem;
}

.section-title {
    font-size: 1.8rem;
    color: #333;
    margin-bottom: 10px;
    position: relative;
    display: inline-block;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 50px;
    height: 3px;
    background-color: #0e8040;
}

.section-subtitle {
    font-size: 1.2rem;
    color: #555;
    margin: 5px 0 15px;
    font-weight: normal;
}

.section-description {
    color: #666;
    max-width: 700px;
    margin: 0 auto;
}

.editor-picks {
    display: flex;
    margin-top: 30px;
}

.editor-picks-info {
    width: 250px;
    padding: 20px;
    background-color: #f5f5f5;
    border-radius: 8px 0 0 8px;
}

.editor-picks-info h3 {
    font-size: 1.3rem;
    margin-bottom: 15px;
    color: #333;
}

.editor-picks-info p {
    color: #666;
    margin-bottom: 20px;
    font-size: 0.9rem;
    line-height: 1.5;
}

.carousel-navigation {
    display: flex;
    gap: 10px;
}

.carousel-prev, .carousel-next {
    background-color: #fff;
    border: 1px solid #ddd;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s;
}

.carousel-prev:hover, .carousel-next:hover {
    background-color: #0e8040;
    color: white;
    border-color: #0e8040;
}

.carousel-prev.disabled, .carousel-next.disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.carousel-container {
    flex: 1;
    overflow: hidden;
    border-radius: 0 8px 8px 0;
    background-color: #fff;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.carousel-track {
    display: flex;
    transition: transform 0.5s ease;
}

.carousel-item {
    flex: 0 0 calc(33.333% - 20px);
    padding: 10px;
    box-sizing: border-box;
}

.article-card {
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s, box-shadow 0.3s;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.article-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
}

.article-image {
    position: relative;
    height: 180px;
    overflow: hidden;
}

.article-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
}

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

.article-image .category-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    margin-bottom: 0;
}

.article-info {
    padding: 15px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.article-excerpt {
    color: #666;
    font-size: 0.9rem;
    margin: 8px 0;
    line-height: 1.4;
}

.article-info .article-title {
    font-size: 1.1rem;
    margin-bottom: 10px;
    line-height: 1.4;
}

.article-info .article-meta {
    margin-bottom: 15px;
    font-size: 0.8rem;
}

.read-more-link {
    color: #0e8040;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    margin-top: auto;
    display: inline-block;
    transition: color 0.3s;
}

.read-more-link:hover {
    color: #0a6030;
}

/* Other Sections */
.homepage-section {
    margin-bottom: 40px;
    padding: 30px;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

/* Deputies Grid */
.deputies-grid, .commissions-grid, .groupes-amitie-grid, .textes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.deputy-card, .commission-card, .groupe-amitie-card, .texte-card {
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s, box-shadow 0.3s;
    background-color: #fff;
}

.deputy-card:hover, .commission-card:hover, .groupe-amitie-card:hover, .texte-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
}

.deputy-image {
    height: 220px;
    overflow: hidden;
    background-color: #f9f9f9;
}

.deputy-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center 30%;
    padding: 10px;
}

.deputy-info, .commission-card, .groupe-amitie-card, .texte-card {
    padding: 15px;
}

.deputy-name, .commission-name, .groupe-amitie-name, .texte-title {
    font-size: 1.1rem;
    margin-bottom: 5px;
    color: #333;
}

.deputy-group, .commission-description, .groupe-amitie-description, .texte-description {
    color: #666;
    font-size: 0.9rem;
    margin-bottom: 15px;
}

.deputy-link, .commission-link, .groupe-amitie-link, .texte-link {
    display: inline-block;
    color: #0e8040;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.9rem;
    transition: color 0.3s;
}

.deputy-link:hover, .commission-link:hover, .groupe-amitie-link:hover, .texte-link:hover {
    color: #0a6030;
}

.commission-meta, .groupe-amitie-meta, .texte-meta {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
    color: #666;
    font-size: 0.8rem;
}

.commission-members, .groupe-amitie-members, .texte-type, .texte-date {
    margin-right: 15px;
}

/* No Content Message */
.no-content-message {
    text-align: center;
    padding: 30px;
    color: #666;
    font-style: italic;
}

/* Custom Section */
.custom-section-content {
    line-height: 1.6;
    color: #333;
}

/* Responsive Styles */
@media (max-width: 992px) {
    .featured-article-container {
        flex-direction: column;
    }

    .featured-article-image {
        height: 300px;
    }

    .editor-picks {
        flex-direction: column;
    }

    .editor-picks-info {
        width: 100%;
        border-radius: 8px 8px 0 0;
        padding: 15px;
    }

    .carousel-container {
        border-radius: 0 0 8px 8px;
    }

    .carousel-item {
        flex: 0 0 calc(50% - 20px);
    }
}

@media (max-width: 768px) {
    .home-page {
        padding: 15px;
    }

    .featured-article-content {
        padding: 20px;
    }

    .article-title {
        font-size: 1.5rem;
    }

    .carousel-item {
        flex: 0 0 calc(100% - 20px);
    }

    .deputies-grid, .commissions-grid, .groupes-amitie-grid, .textes-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    }
}

@media (max-width: 480px) {
    .featured-article-image {
        height: 200px;
    }

    .deputies-grid, .commissions-grid, .groupes-amitie-grid, .textes-grid {
        grid-template-columns: 1fr;
    }
}
