/*
 * pages-static.css
 * apropos, careers-mansa, entrepreneuriat-styles,
 * recherche-prospective-styles, contenu-media-single,
 * programme-encadre.css
 */

/* ============================================================
   VARIABLES COMMUNES
   Centralisées ici — supprimées des fichiers d'origine
   ============================================================ */
:root {
    --mansa-black: #1A1A1A;
    --mansa-gray: #8C8C8C;
    --mansa-gray-light: #F8F8F8;
    --mansa-gray-medium: #E0E0E0;
    --mansa-light-gray: #F5F5F5;
    --mansa-yellow: #E4FF7A;
    --mansa-white: #FFFFFF;
    --mansa-light: rgba(0, 0, 0, 0.06);
    --border-subtle: 1px solid rgba(26, 26, 26, 0.08);
    --border-visible: 1px solid rgba(26, 26, 26, 0.15);
    --transition-elegant: cubic-bezier(0.16, 1, 0.3, 1);
    --transition-mansa: cubic-bezier(0.16, 1, 0.3, 1);
}

/* ============================================================
   ANIMATIONS COMMUNES
   ============================================================ */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to   { opacity: 1; transform: translateY(0); }
}

@keyframes fadeInUp {
    to { opacity: 1; transform: translateY(0); }
}

@keyframes cardAppear {
    to { opacity: 1; transform: translateY(0); }
}


/* ============================================================
   1. À PROPOS (apropos.css)
   Pages : .page-qui-nous-sommes, .page-a-propos
   ============================================================ */

.page-qui-nous-sommes .site-content,
.page-a-propos .site-content {
    padding-top: 0 !important;
}

.page-qui-nous-sommes .entry-header,
.page-a-propos .entry-header {
    display: none;
}

.qui-intro {
    max-width: 720px;
    margin: 50px auto 80px;
    padding: 0 40px;
    text-align: center;
}

.qui-intro .title-image {
    display: block;
    max-width: 70%;
    height: auto;
    margin: 0 auto 20px;
    border: none;
}

.qui-intro p {
    font-size: 16px;
    margin: 0 0 30px;
}

.qui-layout {
    max-width: 1400px;
    margin: 0 auto 100px;
    padding: 0 40px;
    display: flex;
    gap: 80px;
    position: relative;
}

.qui-layout::before {
    display: none;
}

.qui-nav {
    width: 320px;
    position: sticky;
    top: 140px;
    height: fit-content;
}

.qui-nav ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

.qui-nav li {
    width: auto;
}

.qui-nav button {
    background: none;
    border: none;
    font-size: 16px;
    padding: 14px 0;
    cursor: pointer;
    position: relative;
    transition: color 0.25s ease, transform 0.25s ease;
    border-bottom: 1px solid rgba(0, 0, 0, 0.04);
    text-align: right;
    width: auto;
    display: block;
}

.qui-nav button span {
    display: inline-block;
    position: relative;
    padding-bottom: 2px;
}

.qui-nav button::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 1px;
    background-color: rgba(0, 0, 0, 0.04);
    transition: transform 0.25s ease;
    transform-origin: right center;
}

.qui-nav button:hover::after {
    transform: scaleX(0.95);
}

.qui-nav button:hover {
    color: var(--mansa-black);
    transform: translateX(4px);
}

.qui-nav button.active {
    color: var(--mansa-black);
}

.qui-nav button.active::before {
    content: '';
    position: absolute;
    right: -14px;
    top: 50%;
    transform: translateY(-50%);
    width: 2px;
    height: 70%;
    background-color: var(--mansa-black);
}

.qui-content {
    flex: 1;
    padding-left: 40px;
    position: relative;
}

.qui-content::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 1px;
    background: rgba(26, 26, 26, 0.06);
}

.qui-content article {
    margin-bottom: 70px;
    scroll-margin-top: 140px;
}

.qui-content h2 {
    font-size: 20px;
    color: #FFFFFF;
    display: inline-block;
    position: relative;
    white-space: nowrap;
    background-color: var(--mansa-black);
    padding: 2px 4px;
}

.qui-content h2::before {
    display: none;
}

.qui-content h2 span {
    display: inline;
    visibility: visible;
    position: static;
    z-index: auto;
}

.qui-content p {
    font-size: 16px;
    margin: 0 0 22px;
    max-width: 720px;
}

.qui-content .end-image {
    display: block;
    max-width: 100%;
    height: auto;
    margin: 10px 0 0;
    border: none;
}

@media (max-width: 992px) {
    .qui-layout {
        display: block;
        padding: 20px;
        margin-bottom: 60px;
    }

    .qui-layout::before,
    .qui-nav {
        display: none;
    }

    .qui-content {
        padding-left: 0;
    }

    .qui-content::before {
        display: none;
    }

    .qui-intro {
        margin: 100px auto 30px;
        padding: 0 20px;
    }

    .qui-intro .title-image {
        margin-bottom: 16px;
        max-width: 90%;
    }

    .qui-content h2 {
        font-size: 18px;
        white-space: normal;
        display: inline-block;
    }

    .qui-content h2::before {
        display: none;
    }

    .qui-content h2 span {
        display: inline;
        visibility: visible;
    }

    .qui-content article {
        margin-bottom: 60px;
    }

    .qui-content .end-image {
        margin: 0;
    }
}

@media (max-width: 480px) {
    .qui-intro {
        margin: 30px auto 40px;
    }

    .qui-intro .title-image {
        margin-bottom: 12px;
        max-width: 90%;
    }

    .qui-content h2 {
        font-size: 18px;
        margin-bottom: 35px;
    }

    .qui-content article {
        margin-bottom: 50px;
    }

    .qui-content .end-image {
        margin: 30px 0 0;
    }
}


/* ============================================================
   2. CARRIÈRES (careers-mansa.css)
   Page : rejoindre-mansa
   ============================================================ */

.recruitment-custom-sections {
    width: 100%;
    margin: 0;
    padding: 0;
}

.offers-section {
    display: flex !important;
    flex-direction: row !important;
    gap: 30px !important;
    margin: 0 auto 100px auto !important;
    max-width: 1400px !important;
    padding: 0 !important;
    width: 100% !important;
    box-sizing: border-box !important;
}

.offer-item {
    flex: 1 !important;
    padding: 40px 35px !important;
    border: var(--border-subtle) !important;
    background: var(--mansa-white) !important;
    transition: all 0.4s var(--transition-elegant) !important;
    position: relative !important;
    display: flex !important;
    flex-direction: column !important;
    box-sizing: border-box !important;
}

.offer-item:hover {
    border-color: rgba(26, 26, 26, 0.2) !important;
    transform: translateY(-4px) !important;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.04) !important;
}

.offer-item::before {
    content: '' !important;
    position: absolute !important;
    top: -1px !important;
    left: -1px !important;
    right: -1px !important;
    height: 1px !important;
    background: var(--mansa-black) !important;
    transform: scaleX(0) !important;
    transform-origin: left !important;
    transition: transform 0.4s var(--transition-elegant) !important;
}

.offer-item:hover::before {
    transform: scaleX(1) !important;
}

.offer-meta {
    margin-bottom: 20px !important;
    font-size: 13px !important;
}

.offer-type,
.offer-location {
    display: inline-block !important;
}

.offer-title {
    font-size: 24px !important;
    margin: 0 0 15px 0 !important;
    color: var(--mansa-black) !important;
}

.offer-description {
    font-size: 15px !important;
    margin: 0 0 20px 0 !important;
    flex: 1 !important;
}

.offer-link {
    display: inline-block !important;
    font-size: 15px !important;
    color: var(--mansa-gray) !important;
    text-decoration: none !important;
    transition: all 0.3s var(--transition-elegant) !important;
    margin: 20px 0 0 0 !important;
    padding-top: 20px !important;
    border-top: 0.5px solid rgba(0, 0, 0, 0.05) !important;
    width: 100% !important;
}

.offer-link:hover {
    color: var(--mansa-black) !important;
}

.offer-special {
    background-color: var(--mansa-gray-light) !important;
    border-color: rgba(26, 26, 26, 0.05) !important;
}

.offer-special:hover {
    border-color: rgba(26, 26, 26, 0.1) !important;
}

.offer-special::before {
    content: none !important;
}

.offer-special .offer-link {
    border-top-color: rgba(0, 0, 0, 0.1) !important;
}

.value-item,
.offer-item {
    animation: fadeIn 0.6s var(--transition-elegant) forwards;
    opacity: 0;
}

.value-item:nth-child(1),
.offer-item:nth-child(1) { animation-delay: 0.1s; }
.value-item:nth-child(2),
.offer-item:nth-child(2) { animation-delay: 0.15s; }
.value-item:nth-child(3),
.offer-item:nth-child(3) { animation-delay: 0.2s; }

@media (max-width: 1200px) {
    .offers-section {
        gap: 20px !important;
    }
}

@media (max-width: 992px) {
    .offers-section {
        flex-direction: column !important;
    }
}

@media (max-width: 768px) {
    .offer-item {
        padding: 30px 25px !important;
    }

    .offer-title {
        font-size: 20px !important;
    }
}

@media (max-width: 480px) {
    .offer-item {
        padding: 25px 20px !important;
    }
}


/* ============================================================
   3. ENTREPRENEURIAT (entrepreneuriat-styles.css)
   Page : entrepreneuriat
   ============================================================ */

.wp-block-group.entrepreneuriat,
.wp-block-group.programmes {
    margin-top: 80px;
    margin-bottom: 40px;
}

.page-entrepreneuriat .site-content,
.page-entrepreneuriat .entry-header {
    padding-top: 0 !important;
}

.page-entrepreneuriat .entry-header {
    display: none;
}

.entrepreneuriat-mansa {
    margin: 0;
    padding: 0;
    background: #fff;
}

.mlab-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px 40px 80px;
}

.mlab-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 60px;
    margin: 0 auto;
    width: 100%;
}

.mlab-card {
    position: relative;
    padding: 40px 30px;
    border: 1px solid rgba(26, 26, 26, 0.08);
    background: #fff;
    transition: all 0.4s var(--transition-elegant);
    height: 100%;
    display: flex;
    flex-direction: column;
    opacity: 0;
    transform: translateY(20px);
    animation: cardAppear 0.6s var(--transition-elegant) forwards;
}

.mlab-card:nth-child(1) { animation-delay: 0.1s; }
.mlab-card:nth-child(2) { animation-delay: 0.15s; }
.mlab-card:nth-child(3) { animation-delay: 0.2s; }

.mlab-card:hover {
    border-color: rgba(26, 26, 26, 0.2);
    transform: translateY(-4px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.04);
}

.mlab-card.mansa-lab {
    background-color: var(--mansa-yellow);
    border: none;
    box-shadow: none;
}

.mlab-card.mansa-lab:hover {
    border: none;
    transform: translateY(-4px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.08);
}

.mlab-card::before {
    content: '';
    position: absolute;
    top: -1px;
    left: -1px;
    right: -1px;
    height: 1px;
    background: var(--mansa-black);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s var(--transition-elegant);
}

.mlab-card:hover::before {
    transform: scaleX(1);
}

.mlab-card.mansa-lab::before {
    content: none;
}

.mlab-card-icon {
    margin: 0 0 30px 0;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 120px;
}

.mlab-card-icon img {
    max-width: 180px;
    width: auto;
    height: auto;
    display: block;
}

.mlab-card-title {
    display: none !important;
}

.mlab-card-description {
    font-size: 16px;
    margin: 0 0 30px;
    flex-grow: 1;
}

.mlab-card.mansa-lab .mlab-card-description {
    color: #555555;
}

.mlab-card-links {
    margin-top: auto;
    border-top: 0.5px solid rgba(0, 0, 0, 0.05);
}

.mlab-card.mansa-lab .mlab-card-links {
    border-top-color: rgba(0, 0, 0, 0.1);
}

.mlab-link {
    display: flex;
    align-items: center;
    color: #666666 !important;
    text-decoration: none;
    font-size: 16px;
    padding: 12px 0;
    transition: all 0.3s var(--transition-elegant);
    width: 100%;
    border-bottom: 0.5px solid rgba(0, 0, 0, 0.05);
}

.mlab-card.mansa-lab .mlab-link {
    border-bottom-color: rgba(0, 0, 0, 0.1);
}

.mlab-link:hover {
    color: #000000 !important;
    padding-left: 8px;
}

.mlab-card-links .mlab-link:last-child {
    border-bottom: none;
}

.mlab-link::after {
    content: '→';
    margin-left: auto;
    opacity: 0.4;
    font-size: 14px;
    transition: all 0.3s var(--transition-elegant);
}

.mlab-link:hover::after {
    opacity: 0.8;
    transform: translateX(2px);
}

@media (max-width: 1200px) {
    .mlab-grid { gap: 40px; }
}

@media (max-width: 992px) {
    .mlab-grid { gap: 30px; }
    .mlab-card { padding: 30px 20px; }
}

@media (max-width: 781px) {
    .mlab-container { padding: 20px 20px 60px; }
    .mlab-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    .mlab-card { padding: 30px 25px; }
    .mlab-card-icon img { max-width: 150px; }
}

@media (max-width: 480px) {
    .mlab-container { padding: 20px 15px 50px; }
    .mlab-card { padding: 25px 20px; }
    .mlab-card-icon { min-height: 100px; }
    .mlab-card-icon img { max-width: 130px; }
    .mlab-link { font-size: 15px; padding: 10px 0; }
}


/* ============================================================
   4. RECHERCHE & PROSPECTIVE (recherche-prospective-styles.css)
   Page : recherche-prospective
   ============================================================ */

.wp-block-group.recherche {
    margin-top: 40px;
    margin-bottom: 30px;
}

.recherche-chapitres {
    background: #fff;
}

.recherche-wrapper {
    max-width: 960px;
    margin: 0 auto 120px;
    padding: 0 40px;
    position: relative;
}

.recherche-wrapper::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: linear-gradient(
        to bottom,
        transparent 0%,
        rgba(0, 0, 0, 0.03) 10%,
        rgba(0, 0, 0, 0.03) 90%,
        transparent 100%
    );
}

.recherche-chapitre {
    max-width: 760px;
    padding-left: 20px;
    margin-bottom: 80px;
    position: relative;
    opacity: 0;
    transform: translateY(10px);
    animation: fadeInUp 0.6s var(--transition-mansa) forwards;
}

.recherche-chapitre:nth-of-type(1) { animation-delay: 0.1s; }
.recherche-chapitre:nth-of-type(2) { animation-delay: 0.5s; }

@media (hover: hover) {
    .recherche-chapitre:hover {
        transform: translateX(4px);
    }
}

.chapitre-header h3 {
    margin: 0 0 4px;
    position: relative;
    display: inline-block;
}

.chapitre-header h3::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 1px;
    background: var(--mansa-black);
    opacity: 0.3;
    transition: width 0.3s var(--transition-mansa);
}

.recherche-chapitre:hover .chapitre-header h3::after {
    width: 30px;
}

.chapitre-subtitle {
    margin: 0 0 20px;
    text-transform: uppercase;
    opacity: 0.85;
}

.chapitre-content {
    margin-bottom: 30px;
}

.chapitre-links {
    display: inline-flex;
    gap: 24px;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid rgba(0, 0, 0, 0.05);
}

.chapitre-link {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
    position: relative;
    padding: 4px 0;
    transition: color 0.25s ease;
}

.chapitre-link::after {
    margin-left: 6px;
    opacity: 0.25;
    transition: opacity 0.25s ease, transform 0.25s ease;
}

.chapitre-link:hover {
    color: var(--mansa-black);
}

.chapitre-link:hover::after {
    opacity: 0.6;
    transform: translateX(2px);
}

.recherche-divider {
    border: none;
    height: 1px;
    background: rgba(0, 0, 0, 0.05);
    margin: 60px 0;
    position: relative;
    opacity: 0;
    animation: fadeIn 0.6s var(--transition-mansa) forwards;
    animation-delay: 0.3s;
}

.recherche-divider::before {
    content: '•';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: var(--mansa-gray);
    background: #fff;
    padding: 0 10px;
    opacity: 0.3;
}

.recherche-chapitre:first-child .chapitre-links {
    gap: 0;
}

@media (max-width: 781px) {
    .recherche-wrapper {
        padding: 0 20px;
    }

    .recherche-wrapper::before {
        display: none;
    }

    .recherche-chapitre {
        padding-left: 0;
        margin-bottom: 60px;
    }

    .chapitre-links {
        flex-direction: column;
        gap: 12px;
    }
}


/* ============================================================
   5. CONTENU MÉDIA SINGLE (contenu-media-single.css)
   Template : single-contenu_media.php
   ============================================================ */

.media-info-column {
    padding-right: 2rem;
}

.media-info-column h1 {
    font-size: clamp(2rem, 4vw, 2.75rem);
    line-height: 1.2;
    margin-bottom: 1.5rem;
}

.video-caption {
    text-align: center;
    margin-top: 1rem;
    font-size: 0.9rem;
    color: #666;
    padding: 0.5rem 1rem;
    border-top: 1px solid #eee;
}

.media-excerpt {
    font-size: 1.25rem;
    line-height: 1.6;
    color: #666;
    font-style: italic;
    padding-left: 1.5rem;
    border-left: 4px solid var(--color-primary, #000);
    margin-bottom: 2rem;
}

.media-description {
    font-size: 1.125rem;
    line-height: 1.8;
    color: #333;
}

.media-description p:last-child {
    margin-bottom: 0;
}

.media-credits {
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 8px;
    margin-bottom: 2rem;
    border-left: 4px solid var(--color-primary, #000);
}

.credit-item {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
}

.credit-item:last-child {
    margin-bottom: 0;
}

.credit-item strong {
    min-width: 120px;
    color: #000;
}

.credit-item span {
    color: #555;
}

.media-video-column {
    position: sticky;
    top: 100px;
}

.video-container {
    background: #000;
}

.post-blog-item {
    height: 100%;
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.post-blog-item:hover {
    transform: translateY(-5px);
}

.post-thumbnail-link {
    display: block;
    text-decoration: none;
    margin-bottom: 1rem;
}

.post-thumbnail-wrapper {
    position: relative;
    padding-bottom: 56.25%;
    overflow: hidden;
    border-radius: 8px;
    background: #f0f0f0;
    transition: box-shadow 0.3s ease;
}

.post-thumbnail-link:hover .post-thumbnail-wrapper {
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
}

.post-thumbnail-wrapper img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.post-thumbnail-link:hover .post-thumbnail-wrapper img {
    transform: scale(1.05);
}

.youtube-play-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 68px;
    height: 48px;
    background: rgba(255, 0, 0, 0.8);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s ease, transform 0.3s ease;
    pointer-events: none;
}

.post-thumbnail-link:hover .youtube-play-icon {
    background: rgba(255, 0, 0, 1);
    transform: translate(-50%, -50%) scale(1.1);
}

.video-placeholder-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    color: #999;
}

.post-content {
    padding-top: 1rem;
    flex-grow: 1;
}

.post-title {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
    line-height: 1.3;
}

.post-title a {
    color: #000;
    text-decoration: none;
    transition: color 0.3s ease;
}

.post-title a:hover {
    color: var(--color-primary, #000);
}

.post-excerpt {
    font-size: 0.95rem;
    color: #666;
    line-height: 1.6;
}

.mb-6 {
    margin-bottom: 4rem !important;
}

@media (max-width: 991px) {
    .media-info-column {
        padding-right: 0;
        padding-left: 0;
        margin-top: 2rem;
    }

    .media-video-column {
        position: static;
        margin-bottom: 0;
    }
}

@media (max-width: 767px) {
    .media-info-column h1 { font-size: 1.75rem; }
    .media-excerpt { font-size: 1.125rem; padding-left: 1rem; }
    .media-description { font-size: 1rem; }
    .credit-item { flex-direction: column; gap: 0.25rem; }
    .credit-item strong { min-width: auto; }
    .post-title { font-size: 1.125rem; }
    .post-excerpt { font-size: 0.9rem; }
    .video-caption { font-size: 0.85rem; padding: 0.5rem 0; }
    .mb-6 { margin-bottom: 2rem !important; }
}

@media (max-width: 575px) {
    .media-info-column { padding-right: 0; margin-top: 1.5rem; }
    .media-excerpt { font-size: 1rem; padding-left: 0.75rem; border-left-width: 3px; }
    .media-credits { padding: 1rem; }
    .video-caption { font-size: 0.8rem; }
}


/* ============================================================
   6. ENCADRÉ PROGRAMME (programme-encadre.css)
   Post type : programme (single)
   ============================================================ */

.programme-encadre {
    background-color: #f5f5f5;
    padding: 32px;
    margin-top: 64px;
}

@media (max-width: 781px) {
    .programme-encadre {
        padding: 24px;
        margin-top: 48px;
    }
}