/**
 * Theme Name: Inspiro Child
 * Template: inspiro
 * Author: WPZOOM
 * Author URI: https://www.wpzoom.com/
 * Description: Child theme for Inspiro, customized for MODEM Maroc to display custom post types (Actualités, Events, Agenda, Espace Presse) with a professional, centered layout.
 * Version: 1.0.0
 * License: GNU General Public License v2 or later
 * License URI: http://www.gnu.org/licenses/gpl-2.0.html
 * Text Domain: inspiro-child
 */

@import url("../inspiro/style.css");

.content-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 20px;
    font-family: 'Roboto', 'Arial', sans-serif;
}

.hero-section {
    position: relative;
    width: 100%;
    height: 400px;
    overflow: hidden;
    margin-bottom: 40px;
}

.hero-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    z-index: 1;
}

.post-header {
    margin-bottom: 30px;
    text-align: center;
}

.post-header h1 {
    font-size: 2.8em;
    color: #1a1a1a;
    margin: 0 0 15px;
}

.meta, .event-meta, .agenda-meta, .press-meta {
    font-size: 1.1em;
    color: #555555;
    margin-bottom: 20px;
    text-align: center;
}

.event-meta p, .agenda-meta p, .press-meta p {
    margin: 8px 0;
}

.featured-image {
    margin: 0 auto 30px;
    max-width: 100%;
    text-align: center;
}

.featured-image img {
    max-width: 100%;
    height: auto;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.featured-image figcaption {
    font-size: 0.95em;
    color: #777777;
    margin-top: 10px;
    text-align: center;
}

.post-summary, .post-content {
    line-height: 1.8;
    color: #333333;
    font-size: 1.1em;
    text-align: left;
}

.post-content p {
    margin-bottom: 20px;
}

.single-post {
    background: #ffffff;
    padding: 40px;
    margin-bottom: 40px;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.post-footer {
    text-align: center;
    margin-top: 30px;
}

.btn {
    display: inline-block;
    padding: 12px 25px;
    font-size: 1em;
    text-decoration: none;
    border-radius: 6px;
    transition: background 0.3s, transform 0.2s;
}

.btn-primary {
    background: #0057b8;
    color: #ffffff;
}

.btn-primary:hover {
    background: #003d82;
    transform: translateY(-2px);
}

.btn-secondary {
    background: #f5f5f5;
    color: #333333;
    border: 1px solid #cccccc;
}

.btn-secondary:hover {
    background: #e0e0e0;
    transform: translateY(-2px);
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .content-container {
        padding: 0 15px;
        margin: 20px auto;
    }

    .hero-section {
        height: 300px;
    }

    .single-post {
        padding: 20px;
    }

    .post-header h1 {
        font-size: 2em;
    }

    .featured-image img {
        border-radius: 8px;
    }

    .btn {
        padding: 10px 20px;
        font-size: 0.95em;
    }
}

@media (max-width: 480px) {
    .post-header h1 {
        font-size: 1.6em;
    }

    .meta, .event-meta, .agenda-meta, .press-meta {
        font-size: 1em;
    }

    .hero-section {
        height: 250px;
    }
}

/* Card Sections Styling */
.section-heading {
    text-align: center;
    font-size: 2em;
    color: #1a1a1a;
    margin-bottom: 20px;
}

.actualites-section, .events-section, .agenda-section, .presse-section {
    max-width: 1300px;
    margin: 0 auto;
    padding: 0 20px;
    background: #f9f9f9;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    overflow: hidden;
    margin-bottom: 40px;
}

.actualites-container, .events-container, .agenda-container, .presse-container {
    display: flex;
    justify-content: space-between;
    align-items: stretch;
    gap: 20px;
    width: 100%;
    flex-wrap: nowrap;
    padding: 20px 0;
}

.actualite-card, .event-card, .agenda-card, .presse-card {
    background: #ffffff;
    border: 1px solid #e0e0e0;
    text-align: center;
    padding: 15px;
    width: 32%;
    box-sizing: border-box;
    transition: transform 0.2s ease;
    border-radius: 6px;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.actualite-image, .event-image, .agenda-image, .presse-image {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 12px;
}

.actualite-image img, .event-image img, .agenda-image img, .presse-image img {
    max-width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: 4px;
}

.actualite-card h3, .event-card h3, .agenda-card h3, .presse-card h3 {
    font-size: 1.2em;
    color: #1a1a1a;
    margin: 8px 0;
    word-wrap: break-word;
    flex-grow: 0;
    line-height: 1.3;
    padding: 0 10px;
}

.actualite-card .date, .event-card .date, .agenda-card .date, .presse-card .date {
    color: #777777;
    margin: 5px 0;
    font-size: 0.9em;
    flex-grow: 0;
}

.actualite-card .excerpt, .event-card .excerpt, .agenda-card .excerpt, .presse-card .excerpt {
    color: #333333;
    margin: 8px 0;
    font-size: 1em;
    word-wrap: break-word;
    flex-grow: 1;
}

.read-more-btn {
    display: inline-block;
    padding: 8px 16px;
    color: #000000;
    text-transform: uppercase;
    text-decoration: none;
    border: 2px solid #000000;
    border-radius: 4px;
    font-size: 0.95em;
    transition: border-color 0.3s, transform 0.2s;
    margin-top: auto;
}

.read-more-btn:hover {
    border-color: #333333;
    transform: translateY(-2px);
}

.actualite-card:hover, .event-card:hover, .agenda-card:hover, .presse-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

@media (max-width: 1024px) {
    .actualite-card, .event-card, .agenda-card, .presse-card {
        width: 32%;
    }
}

@media (max-width: 768px) {
    .actualites-container, .events-container, .agenda-container, .presse-container {
        flex-direction: column;
        align-items: center;
    }

    .actualite-card, .event-card, .agenda-card, .presse-card {
        width: 100%;
        max-width: 300px;
        margin-bottom: 20px;
    }

    .actualite-image img, .event-image img, .agenda-image img, .presse-image img {
        height: 150px;
    }

    .actualite-card:last-child, .event-card:last-child, .agenda-card:last-child, .presse-card:last-child {
        margin-bottom: 0;
    }
}