/* =============================================
   Manager Logistique — Styles principaux
   ============================================= */

/* === Reset & Base === */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
    --navy: #1a2332;
    --navy-dark: #111927;
    --navy-light: #243447;
    --red: #d32f2f;
    --red-hover: #b71c1c;
    --white: #ffffff;
    --gray-50: #f8f9fa;
    --gray-100: #f1f3f5;
    --gray-200: #e9ecef;
    --gray-400: #adb5bd;
    --gray-600: #6c757d;
    --gray-800: #343a40;
    --text: #2c3e50;
    --text-light: #5a6c7d;
    --radius: 12px;
    --shadow: 0 1px 3px rgba(0,0,0,0.04), 0 4px 16px rgba(0,0,0,0.07);
    --shadow-hover: 0 4px 8px rgba(0,0,0,0.06), 0 8px 32px rgba(0,0,0,0.11);
    --max-width: 1200px;
}

html { font-size: 16px; scroll-behavior: smooth; }

body {
    font-family: 'Segoe UI', -apple-system, BlinkMacSystemFont, sans-serif;
    color: var(--text);
    background-color: #ffffff;
    line-height: 1.7;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}
.site-main { flex: 1; }

a { color: var(--navy); text-decoration: none; }
a:hover { color: var(--red); }

img { max-width: 100%; height: auto; display: block; }

/* === Layout === */
.container { max-width: var(--max-width); margin: 0 auto; padding: 0 20px; }

.card {
    background: var(--white);
    border-radius: var(--radius);
    padding: 30px;
    box-shadow: var(--shadow);
    border: 1px solid var(--gray-200);
}

.page-content { margin-bottom: 40px; }

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

/* === Barre de progression de lecture === */
.reading-progress-bar {
    position: fixed;
    top: 80px; /* colle sous le header sticky */
    left: 0;
    width: 0%;
    height: 3px;
    background: var(--red);
    z-index: 99;
    transition: width 0.1s linear;
}

/* === Header === */
.site-header {
    background: #ffffff;
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 1px solid var(--gray-200);
}

.header-inner {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 20px; /* même approche que .container → alignement parfait avec le body */
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 80px;
}

.site-logo {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 10px;
    text-decoration: none;
}
.site-logo-svg {
    width: 34px;
    height: 34px;
    flex-shrink: 0;
    display: block;
}
.site-logo-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.site-logo-name {
    font-size: 0.92rem;
    font-weight: 800;
    color: var(--navy);
    line-height: 1.15;
    letter-spacing: -0.2px;
}
.site-logo-sub {
    font-size: 0.63rem;
    font-weight: 400;
    color: var(--text-light);
    letter-spacing: 0.2px;
    line-height: 1.3;
}
.site-logo:hover .site-logo-name { color: var(--red); }
/* currentColor = var(--red) par défaut ; les overrides (ex: sales) changent juste color */
.site-logo-svg { color: var(--red); }

.site-nav .nav-list {
    list-style: none;
    display: flex;
    align-items: center;
    gap: 4px;
}

.site-nav .nav-list a {
    color: var(--gray-600);
    padding: 7px 14px;
    border-radius: 7px;
    font-size: 0.88rem;
    transition: background 0.15s, color 0.15s;
}
/* "Blog" non-cliquable — même apparence que les liens nav, sans cursor pointer */
.nav-dropdown-label {
    display: inline-block;
    color: var(--gray-600);
    padding: 7px 14px;
    border-radius: 7px;
    font-size: 0.88rem;
    cursor: default;
    user-select: none;
}

/* Séparation visuelle entre les liens nav et le CTA */
.nav-cta-item { margin-left: 12px; }
.site-nav .nav-list a:hover {
    background: var(--gray-200);
    color: var(--navy);
}

.btn-cta {
    background: var(--red) !important;
    color: var(--white) !important;
    font-weight: 600;
    padding: 8px 18px !important;
    border-radius: 7px !important;
    font-size: 0.88rem !important;
    transition: background 0.15s !important;
}
.btn-cta:hover { background: var(--red-hover) !important; color: var(--white) !important; }

/* Dropdown catégories */
.nav-dropdown { position: relative; }
.dropdown-menu {
    position: absolute;
    top: 150%; /* Flush — pas de gap, hover conservé */
    left: 0;
    background: var(--white);
    border-radius: 10px;
    box-shadow: var(--shadow-hover);
    min-width: 200px;
    padding: 8px 0; /* padding-top comble visuellement la jonction */
    list-style: none;
    z-index: 200;
    visibility: hidden;
    opacity: 0;
    /* Délai de 2s avant de masquer — donne le temps de traverser la jonction */
    transition: opacity 0.15s ease 1s, visibility 0s linear 2.15s;
}
.nav-dropdown:hover .dropdown-menu {
    visibility: visible;
    opacity: 1;
    transition: opacity 0.15s ease 0s, visibility 0s linear 0s;
}
.dropdown-menu li a {
    display: block;
    padding: 9px 18px;
    color: var(--text) !important;
    font-size: 0.88rem;
    background: transparent !important;
    border-radius: 0 !important;
    transition: background 0.12s !important;
}
.dropdown-menu li a:hover {
    background: var(--gray-50) !important;
    color: var(--red) !important;
}

/* Nav mobile toggle (hidden on desktop, shown on mobile via media query) */
.nav-toggle {
    display: none;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--navy);
    border-radius: 8px;
    transition: background 0.15s;
    flex-shrink: 0;
}
.nav-toggle:hover { background: var(--gray-100); }
.nav-toggle svg { width: 20px; height: 20px; display: block; transition: transform 0.2s; }

/* === Retour au Hub === */
.article-back-hub {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 0.78rem;
    font-weight: 400;
    color: #9ca3af;
    margin-bottom: 14px;
    transition: color 0.15s;
    text-decoration: none;
}
.article-back-hub:hover { color: var(--gray-600); }
.article-back-hub svg { flex-shrink: 0; opacity: 0.6; }

/* === Hub articles — message fallback === */
.hub-articles-empty {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #fffbeb;
    border: 1px solid #fde68a;
    border-radius: 10px;
    padding: 14px 18px;
    font-size: 0.875rem;
    color: #92400e;
    margin: 24px 0;
}
.hub-articles-empty svg { flex-shrink: 0; color: #d97706; }

/* === Homepage — Derniers articles === */
.home-recent { padding: 48px 0; }
.home-section-title {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--navy);
    margin-bottom: 32px;
    text-align: center;
}

/* === Hub children — Articles enfants d'une page mère === */
.hub-children { margin-top: 48px; }
.hub-children-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--navy);
    margin-bottom: 24px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--gray-200);
}
.hub-children-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}
/* Carte = un seul <a> englobant — layout horizontal image gauche / texte droite */
.hub-child-card {
    display: flex;
    align-items: center;
    gap: 14px;
    background: var(--white);
    border-radius: var(--radius);
    border: 1px solid var(--gray-200);
    box-shadow: 0 1px 6px rgba(0,0,0,0.05);
    padding: 12px;
    text-decoration: none;
    color: inherit;
    transition: box-shadow 0.2s, transform 0.2s, border-color 0.2s;
}
.hub-child-card:hover {
}
/* Miniature à gauche */
.hub-child-img {
    flex-shrink: 0;
    width: 110px;
    height: 62px;
    border-radius: 6px;
    overflow: hidden;
}
.hub-child-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
/* Texte à droite */
.hub-child-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 6px;
    min-width: 0;
}
.hub-child-body h3 {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--navy);
    margin: 0;
    line-height: 1.35;
    /* Évite le débordement sur les titres longs */
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.hub-child-card:hover .hub-child-body h3 { color: var(--red); }
.hub-child-link {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--red);
}
.hub-child-card:hover .hub-child-link { text-decoration: underline; }

/* Mobile : liste minimaliste — titre + lien, séparateur gris, pas d'image ni de fond */
@media (max-width: 600px) {
    .hub-children-grid {
        grid-template-columns: 1fr;
        gap: 0;
    }
    .hub-child-card {
        background: transparent;
        border: none;
        border-bottom: 1px solid #d1d5db;
        border-radius: 0;
        box-shadow: none;
        padding: 14px 0;
        gap: 0;
    }
    .hub-child-card:hover {
        transform: none;
        box-shadow: none;
    }
    .hub-child-img { display: none; }
    .hub-child-body h3 {
        font-size: 0.925rem;
        -webkit-line-clamp: unset;
        overflow: visible;
        display: block;
    }
    .hub-children-grid .hub-child-card:last-child {
        border-bottom: none;
    }
}

/* === Sister links — liens sœurs === */
.sister-links {
    margin-top: 40px;
    background: var(--gray-50, #f8f9fa);
    border-radius: var(--radius);
    padding: 24px 28px;
}
.sister-links-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--navy);
    margin: 0 0 16px;
}
.sister-links-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.sister-links-list li::before { content: '→ '; color: var(--red); font-weight: 700; }
.sister-links-list a { color: var(--navy); font-weight: 500; }
.sister-links-list a:hover { color: var(--red); }

/* === Admin — checkbox label === */
.checkbox-label { display: flex; align-items: center; gap: 10px; cursor: pointer; font-weight: 500; }
.checkbox-label input[type="checkbox"] { width: 18px; height: 18px; accent-color: var(--red); cursor: pointer; }

/* =============================================
   === [hub-articles] — Rendu front-end SEXY ===
   ============================================= */
.hub-articles-block {
    margin: 44px 0;
}
.hub-articles-titre {
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--navy);
    margin: 0 0 24px;
    display: flex;
    align-items: center;
    gap: 12px;
}
.hub-articles-titre::before {
    content: '';
    display: inline-block;
    width: 5px;
    height: 1.3em;
    background: var(--red);
    border-radius: 3px;
    flex-shrink: 0;
}

/* Grille 3 colonnes */
.hub-articles-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
}

/* Card — entière cliquable via stretched link */
.hub-article-card {
    background: #fff;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 2px 14px rgba(26,35,50,0.07);
    display: flex;
    flex-direction: column;
    position: relative;           /* nécessaire pour le stretched link */
    transition: box-shadow 0.25s ease;
    cursor: pointer;
}
.hub-article-card:hover {
    box-shadow: 0 8px 36px rgba(26,35,50,0.16);
}

/* Image wrapper */
.hub-article-card-img {
    display: block;
    position: relative;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background: linear-gradient(135deg, #1a2332 0%, #2d3f57 100%);
}
.hub-article-card-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
/* Fallback sans image */
.hub-article-card-no-img {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #1a2332 0%, #2d3f57 100%);
    position: absolute;
    inset: 0;
}

/* Corps */
.hub-article-card-body {
    padding: 16px 18px 18px;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.hub-article-card-title {
    font-size: 0.95rem;
    font-weight: 400;          /* pas de gras */
    color: var(--navy);
    line-height: 1.45;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
/* Stretched link : la card entière est cliquable via le lien du titre */
.hub-article-card-title a {
    color: inherit;
    transition: color 0.15s;
}
.hub-article-card-title a::after {
    content: '';
    position: absolute;
    inset: 0;
    z-index: 1;
    border-radius: 14px;
}
.hub-article-card:hover .hub-article-card-title a { color: var(--red); }
.hub-article-card-excerpt {
    font-size: 0.82rem;
    color: #6b7280;
    line-height: 1.6;
    margin: 0;
    flex: 1;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Footer de la card */
.hub-article-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid var(--gray-100);
}
.hub-article-card-date {
    font-size: 0.73rem;
    color: #9ca3af;
}
.hub-article-card-cta {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--red);
    pointer-events: none;        /* le clic passe par le stretched link */
}

/* =============================================
   === Modal Hub Articles — Admin ===
   ============================================= */
.hub-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    z-index: 9000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}
.hub-modal {
    background: #fff;
    border-radius: 12px;
    width: 100%;
    max-width: 560px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 20px 60px rgba(0,0,0,0.25);
}
.hub-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px 16px;
    border-bottom: 1px solid #e5e7eb;
}
.hub-modal-header h3 { margin: 0; font-size: 1.1rem; color: #1a2332; }
.hub-modal-x {
    background: none;
    border: none;
    cursor: pointer;
    color: #6b7280;
    padding: 4px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    transition: background 0.15s;
}
.hub-modal-x:hover { background: #f3f4f6; color: #d32f2f; }
.hub-modal-body {
    padding: 20px 24px;
    overflow-y: auto;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 16px;
}
.hub-modal-body .form-group { margin: 0; }
.hub-modal-body label { font-size: 0.875rem; font-weight: 600; color: #374151; display: block; margin-bottom: 6px; }
.hub-modal-body input[type="text"] {
    width: 100%;
    padding: 9px 12px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font-size: 0.9rem;
    outline: none;
    box-sizing: border-box;
    transition: border-color 0.15s;
}
.hub-modal-body input[type="text"]:focus { border-color: #7c3aed; box-shadow: 0 0 0 3px rgba(124,58,237,0.1); }
.hub-modal-results {
    position: absolute;
    top: calc(100% + 4px);
    left: 0; right: 0;
    background: #fff;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.12);
    z-index: 10;
    max-height: 220px;
    overflow-y: auto;
}
.hub-modal-result-item {
    padding: 10px 14px;
    cursor: pointer;
    border-bottom: 1px solid #f3f4f6;
    transition: background 0.1s;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}
.hub-modal-result-item:last-child { border-bottom: none; }
.hub-modal-result-item:hover { background: #f5f3ff; }
.hub-modal-result-item strong { font-size: 0.875rem; color: #1a2332; flex: 1; }
.hub-modal-cat { font-size: 0.75rem; color: #7c3aed; background: #ede9fe; padding: 2px 8px; border-radius: 20px; white-space: nowrap; }
.hub-modal-no-result { padding: 12px 14px; font-size: 0.875rem; color: #9ca3af; }
.hub-modal-selected {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.hub-modal-selected-item {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #f5f3ff;
    border: 1px solid #ddd6fe;
    border-radius: 8px;
    padding: 8px 12px;
    font-size: 0.875rem;
}
.hub-modal-selected-num {
    background: #7c3aed;
    color: #fff;
    border-radius: 50%;
    width: 22px;
    height: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 700;
    flex-shrink: 0;
}
.hub-modal-selected-title { flex: 1; color: #1a2332; font-weight: 500; }
.hub-modal-selected-id { font-size: 0.75rem; color: #9ca3af; white-space: nowrap; }
.hub-modal-remove {
    background: none;
    border: none;
    cursor: pointer;
    color: #d32f2f;
    font-size: 1.1rem;
    line-height: 1;
    padding: 2px 4px;
    border-radius: 4px;
    transition: background 0.1s;
}
.hub-modal-remove:hover { background: #fee2e2; }
.hub-modal-footer {
    padding: 16px 24px;
    border-top: 1px solid #e5e7eb;
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}
.hub-modal-info {
    background: #eff6ff;
    border: 1px solid #bfdbfe;
    border-radius: 8px;
    padding: 12px 14px;
    font-size: 0.84rem;
    color: #1e40af;
    display: flex;
    align-items: flex-start;
    gap: 8px;
    line-height: 1.5;
}
.hub-modal-info svg { flex-shrink: 0; margin-top: 1px; }
.hub-modal-body select {
    width: 100%;
    padding: 9px 12px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font-size: 0.9rem;
    background: #fff;
    cursor: pointer;
    outline: none;
    transition: border-color 0.15s;
}
.hub-modal-body select:focus { border-color: #7c3aed; box-shadow: 0 0 0 3px rgba(124,58,237,0.1); }

/* === Footer === */
.site-footer {
    background: var(--navy-dark);
    color: var(--gray-400);
    padding: 16px 20px;
    margin-top: 0;
    font-size: 0.875rem;
}

.footer-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
}

.footer-copy { color: var(--gray-400); }

/* === Main content area === */
.site-main {
    padding: 28px 0 60px;
}

/* === Hero accueil === */
.hero { margin-bottom: 40px; }
.hero h1 {
    color: var(--red);
    font-size: 2rem;
    margin-bottom: 20px;
    line-height: 1.3;
}
.hero-intro {
    font-size: 1.1rem;
    color: var(--text-light);
    line-height: 1.8;
}

/* === Typographie contenu === */
.page-content h1, .article-main h1 {
    color: var(--red);
    font-size: 2rem;
    margin-bottom: 20px;
    line-height: 1.3;
    text-align: center;
}

.page-content h2, .article-body h2 {
    color: var(--navy);
    font-size: 1.5rem;
    font-weight: 700;
    margin: 35px 0 15px;
    padding-bottom: 8px;
    border-bottom: 2px solid var(--gray-200);
}

.page-content h3, .article-body h3 {
    color: var(--gray-600);
    font-size: 1.2rem;
    font-weight: 600;
    margin: 25px 0 10px;
}

.article-body p, .page-content p { margin-bottom: 16px; }
.article-body ul, .article-body ol,
.page-content ul, .page-content ol { margin: 16px 0; padding-left: 24px; }
.article-body li, .page-content li { margin-bottom: 6px; }
.article-body blockquote {
    border-left: 4px solid var(--red);
    padding: 16px 20px;
    margin: 20px 0;
    background: var(--gray-50);
    border-radius: 0 var(--radius) var(--radius) 0;
    font-style: italic;
    color: var(--text-light);
}
.article-body img,
.article-body video,
.page-content img,
.page-content video {
    border-radius: var(--radius);
    margin: 20px auto;
    display: block;
}
.article-body figure {
    margin: 20px 0;
}
.article-body figcaption {
    text-align: center;
    font-size: 0.85rem;
    color: var(--gray-600);
    margin-top: 8px;
}
.article-body a {
    color: var(--red);
    text-decoration: underline;
}

/* === Article cards === */
.articles-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 24px;
    margin-top: 20px;
}

.article-card {
    padding: 0;
    overflow: hidden;
    transition: box-shadow 0.22s, transform 0.22s, border-color 0.22s;
    border-top: 2px solid transparent; /* accent rouge au hover */
}
.article-card:hover {
    box-shadow: var(--shadow-hover);
    transform: translateY(-3px);
    border-top-color: var(--red);
}

.article-card-img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.article-card-body { padding: 20px; }
.article-card-body h3 {
    font-size: 1.1rem;
    margin: 8px 0;
    line-height: 1.4;
}
.article-card-body h3 a { color: var(--text); }
.article-card-body h3 a:hover { color: var(--red); }

.article-category {
    display: inline-block;
    background: var(--gray-100);
    color: var(--navy) !important;
    padding: 3px 10px;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.article-meta {
    font-size: 0.85rem;
    color: var(--gray-600);
    margin-top: 10px;
}
.article-meta time { margin-right: 12px; }

.article-excerpt {
    font-size: 0.95rem;
    color: var(--text-light);
    line-height: 1.6;
}

/* === Page catégorie sans card === */
.category-page-header {
    margin-bottom: 24px;
    text-align: center;
}
.category-page-title {
    color: var(--navy);
    font-size: 1.8rem;
    margin-bottom: 8px;
    text-align: center;
}
.category-description {
    color: var(--text-light);
    font-size: 1rem;
    margin-bottom: 0;
}
.category-empty {
    text-align: center;
    color: var(--text-light);
    padding: 40px 0;
}

/* === Article listing (list view) === */
.articles-list { margin-top: 0; }

.article-list-item {
    display: flex;
    gap: 24px;
    padding: 24px 0;
    border-bottom: 1px solid var(--gray-200);
}
.article-list-item:last-child { border-bottom: none; }

.article-list-img {
    flex-shrink: 0;
    width: 200px;
    height: 140px;
    overflow: hidden;
    border-radius: var(--radius);
}
.article-list-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.article-list-body h2 {
    font-size: 1.25rem;
    margin: 6px 0 8px;
    border: none;
    padding: 0;
}
.article-list-body h2 a { color: var(--text); }
.article-list-body h2 a:hover { color: var(--red); }
.article-list-body p {
    color: var(--text-light);
    font-size: 0.95rem;
}

/* === Article detail === */
.article-hero-image img {
    width: 100%;
    max-height: 400px;
    object-fit: cover;
    border-radius: 0; /* le card gère déjà le border-radius via overflow:hidden */
    margin: 0;
}
.article-hero-image figcaption {
    text-align: center;
    font-size: 0.85rem;
    color: var(--gray-600);
    padding: 10px 30px;
}

.article-header {
    margin-bottom: 24px;
    padding-top: 24px;
    text-align: center;
}
.article-header h1 {
    margin: 0 0 14px;
    text-align: center;
}
.article-header-meta {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px;
    font-size: 0.88rem;
    color: var(--gray-600);
}
.article-meta-sep { color: var(--gray-400); }

/* === Article detail — image hero flush avec le card === */
.article-main.card {
    overflow: hidden; /* clip border-radius sur l'image hero */
    padding-top: 0;   /* l'image occupe le haut, le padding est géré par article-header */
}

.article-hero-image {
    margin: 0 -30px 0; /* annule les paddings gauche/droite du card */
}

.article-header {
    padding-top: 24px; /* remplace le padding-top retiré du card */
}

/* === Layout article avec TOC sidebar === */
.article-layout {
    display: grid;
    grid-template-columns: 240px 1fr;
    gap: 28px;
    align-items: start;
    margin-bottom: 40px;
}

.article-toc-sidebar {
    position: sticky;
    top: 96px; /* header 80px + marge */
    /* Hauteur max = viewport - header (80px) - marge haut (16px) - marge bas (16px) */
    max-height: calc(100vh - 112px);
    align-self: start;
    display: flex;
    flex-direction: column;
}

.toc-sidebar-box {
    background: var(--white);
    border-radius: 0;
    box-shadow: none;
    border: none;
    padding: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    max-height: 100%;
}

/* Article dans le layout avec TOC — retire le margin-bottom propre */
.article-layout .article-main {
    margin-bottom: 0;
}

/* Sommaire partagé entre sidebar et inline (mobile) */
.toc-title {
    font-weight: 700;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--gray-400);
    margin: 0;
    padding: 14px 18px 12px;
    border-bottom: 1px solid var(--gray-200);
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}
.toc-title::before {
    display: none;
}

/* Zone scrollable du sommaire */
.toc-sidebar-box ul {
    list-style: none;
    padding: 8px 0 10px;
    margin: 0;
    overflow-y: auto;
    /* Scrollbar fine et discrète */
    scrollbar-width: thin;
    scrollbar-color: var(--gray-200) transparent;
}
.toc-sidebar-box ul::-webkit-scrollbar { width: 4px; }
.toc-sidebar-box ul::-webkit-scrollbar-track { background: transparent; }
.toc-sidebar-box ul::-webkit-scrollbar-thumb { background: var(--gray-200); border-radius: 2px; }

.toc-inline ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.toc-sidebar-box li,
.toc-inline li {
    padding: 0;
    position: relative;
}

/* Liens du sommaire sidebar */
.toc-sidebar-box li a {
    color: var(--text-light);
    font-size: 0.84rem;
    line-height: 1.45;
    transition: color 0.15s, font-weight 0.15s;
    display: block;
    padding: 5px 18px 5px 20px;
    border-left: 2px solid transparent;
}
.toc-sidebar-box li a:hover {
    color: var(--red);
}
/* Section active : indicateur rouge + texte gras */
.toc-sidebar-box li a.active {
    color: var(--red);
    font-weight: 700;
    border-left-color: var(--red);
    background: rgba(211, 47, 47, 0.04);
}

/* Liens du sommaire inline (mobile) */
.toc-inline li a {
    color: var(--text-light);
    font-size: 0.85rem;
    line-height: 1.4;
    transition: color 0.15s;
    display: block;
    padding: 3px 0;
}
.toc-inline li a:hover { color: var(--red); }
.toc-inline li a.active { color: var(--red); font-weight: 700; }

/* Sous-sections */
.toc-sidebar-box li.toc-sub a {
    font-size: 0.8rem;
    color: var(--gray-400);
    padding-left: 30px; /* indent supplémentaire pour les sous-items */
}
.toc-sidebar-box li.toc-sub a:hover { color: var(--red); }
.toc-sidebar-box li.toc-sub a.active {
    color: var(--red);
    font-weight: 600;
    border-left-color: var(--red);
}

.toc-inline li.toc-sub { padding-left: 14px; }
.toc-inline li.toc-sub a { font-size: 0.8rem; color: var(--gray-400); }
.toc-inline li.toc-sub a:hover { color: var(--red); }

/* === Sommaire inline (fallback mobile ou sans TOC) === */
.toc-inline {
    background: var(--gray-50);
    border: 1px solid var(--gray-200);
    border-radius: var(--radius);
    padding: 16px 20px 18px;
    margin: 0 0 28px;
    display: inline-block;
    min-width: 220px;
    max-width: 100%;
}

/* === CTA inline (dans l'article) === */
.cta-inline {
    background: var(--navy);
    border-radius: var(--radius);
    padding: 28px;
    text-align: center;
    margin: 30px 0;
}

.cta-inline p {
    color: var(--white) !important;
    font-size: 1.15rem;
    margin-bottom: 16px;
}

.cta-email-row {
    display: flex;
    gap: 8px;
    justify-content: center;
    max-width: 480px;
    margin: 0 auto;
}

.cta-inline input[type="email"] {
    flex: 1;
    padding: 12px 16px;
    border-radius: 8px;
    border: none;
    font-size: 0.95rem;
    outline: none;
}

.cta-inline button {
    background: var(--red);
    color: var(--white);
    border: none;
    padding: 12px 22px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    white-space: nowrap;
    transition: background 0.2s;
}
.cta-inline button:hover { background: var(--red-hover); }

/* === Métadonnées article === */
.article-updated { color: var(--gray-600); font-style: italic; }
.article-reading-time { color: var(--gray-600); }

/* === Partage article === */
.article-share {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 20px 0 0;
    margin-top: 36px;
    border-top: 1px solid var(--gray-200);
    flex-wrap: wrap;
}
.article-share-label {
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    color: var(--gray-400);
}
.article-share-links {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}
.article-share-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 14px;
    border-radius: 7px;
    font-size: 0.82rem;
    font-weight: 600;
    text-decoration: none;
    transition: opacity 0.15s, transform 0.15s;
    color: var(--white);
}
.article-share-btn:hover { opacity: 0.88; transform: translateY(-1px); color: var(--white); }
.article-share-x        { background: #000; }
.article-share-linkedin { background: #0A66C2; }
.article-share-facebook { background: #1877F2; }

/* === Bio auteur === */
.article-author-bio {
    display: flex;
    align-items: flex-start;
    gap: 18px;
    margin-top: 28px;
    padding: 22px 24px;
    background: var(--gray-50);
    border-radius: var(--radius);
    border: 1px solid var(--gray-200);
}
.author-bio-avatar {
    flex-shrink: 0;
}
.author-bio-avatar img {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    object-fit: cover;
    margin: 0;
}
.author-bio-initial {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: var(--navy);
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    font-weight: 700;
}
.author-bio-content { min-width: 0; }
.author-bio-name {
    display: block;
    font-weight: 700;
    font-size: 0.95rem;
    color: var(--navy);
    margin-bottom: 6px;
}
.author-bio-text {
    font-size: 0.88rem;
    color: var(--text-light);
    line-height: 1.65;
    margin: 0;
}

/* === Breadcrumbs === */
.breadcrumbs {
    padding: 12px 0;
    margin-bottom: 16px;
}

.breadcrumbs ol {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    font-size: 0.85rem;
}

.breadcrumbs li::after {
    content: '>';
    margin: 0 8px;
    color: var(--gray-400);
}
.breadcrumbs li:last-child::after { content: ''; margin: 0; }

.breadcrumbs a { color: var(--text-light); }
.breadcrumbs a:hover { color: var(--red); }
.breadcrumb-current { color: var(--navy); font-weight: 500; }

/* === Pagination === */
.pagination {
    display: flex;
    justify-content: center;
    gap: 6px;
    margin-top: 30px;
    flex-wrap: wrap;
}

.pagination-link {
    padding: 8px 14px;
    border-radius: 6px;
    background: var(--gray-100);
    color: var(--text);
    font-size: 0.9rem;
    transition: background 0.2s;
}
.pagination-link:hover { background: var(--gray-200); color: var(--text); }
.pagination-link.active {
    background: var(--navy);
    color: var(--white);
}

/* === Categories list (forum-style rows) === */
.blog-cats-list {
    background: var(--white);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    overflow: hidden;
    margin-top: 20px;
}

.blog-cat-row {
    display: grid;
    grid-template-columns: 52px 1fr 100px 24px;
    align-items: center;
    gap: 16px;
    padding: 18px 22px;
    border-bottom: 1px solid var(--gray-200);
    color: inherit;
    text-decoration: none;
    transition: background 0.15s;
}
.blog-cat-row:last-child { border-bottom: none; }
.blog-cat-row:hover { background: var(--gray-50); }

.blog-cat-icon {
    width: 44px;
    height: 44px;
    background: var(--navy);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.blog-cat-icon svg { width: 22px; height: 22px; stroke: var(--white); fill: none; stroke-width: 1.8; }

.blog-cat-main { min-width: 0; }
.blog-cat-name {
    display: block;
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--navy);
    margin-bottom: 3px;
}
.blog-cat-row:hover .blog-cat-name { color: var(--red); }
.blog-cat-desc {
    display: block;
    font-size: 0.8rem;
    color: var(--text-light);
    white-space: normal;
    word-wrap: break-word;
}

.blog-cat-count {
    font-size: 0.78rem;
    color: var(--gray-600);
    text-align: right;
    white-space: nowrap;
}

.blog-cat-arrow {
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gray-400);
}
.blog-cat-arrow svg { width: 16px; height: 16px; stroke: currentColor; fill: none; stroke-width: 2; }
.blog-cat-row:hover .blog-cat-arrow { color: var(--red); }

/* Legacy (garde la compatibilité si utilisé ailleurs) */
.category-count {
    font-size: 0.8rem;
    color: var(--gray-600);
    font-weight: 600;
}

/* === TOC Drawer mobile (FAB + slide-in) === */
.toc-fab { display: none; } /* visible uniquement sur mobile via media query */

.toc-drawer-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.45);
    z-index: 290;
}
.toc-drawer-overlay.open { display: block; }

.toc-drawer {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: 82%;
    max-width: 300px;
    background: var(--white);
    z-index: 300;
    overflow-y: auto;
    transform: translateX(-100%);
    transition: transform 0.28s cubic-bezier(0.4, 0, 0.2, 1);
}
.toc-drawer.open { transform: translateX(0); }

.toc-drawer-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 16px 14px;
    border-bottom: 1px solid var(--gray-200);
    position: sticky;
    top: 0;
    background: var(--white);
    z-index: 1;
}
.toc-drawer-title {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--gray-600);
}
.toc-drawer-close {
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text-light);
    display: flex;
    align-items: center;
    padding: 4px;
    border-radius: 6px;
    transition: color 0.15s;
}
.toc-drawer-close:hover { color: var(--navy); }

.toc-drawer ul {
    list-style: none;
    padding: 8px 0 24px;
    margin: 0;
}
.toc-drawer li a {
    display: block;
    padding: 10px 16px;
    font-size: 0.88rem;
    color: var(--text-light);
    border-left: 2px solid transparent;
    transition: color 0.15s, border-color 0.15s;
}
.toc-drawer li a.active {
    color: var(--red);
    font-weight: 700;
    border-left-color: var(--red);
}
.toc-drawer li a:hover { color: var(--red); }
.toc-drawer li.toc-sub a { padding-left: 30px; font-size: 0.82rem; }
.toc-drawer li.toc-sub a.active { color: var(--red); font-weight: 600; }

/* === Buttons === */
.btn {
    display: inline-block;
    padding: 10px 20px;
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
    border: none;
    text-align: center;
}

.btn-primary {
    background: var(--navy);
    color: var(--white);
}
.btn-primary:hover { background: var(--navy-light); color: var(--white); }

.btn-outline {
    background: transparent;
    border: 2px solid var(--navy);
    color: var(--navy);
    padding: 10px 24px;
    border-radius: 8px;
    font-weight: 600;
}
.btn-outline:hover {
    background: var(--navy);
    color: var(--white);
}

/* === Footer links === */
.footer-links {
    display: flex;
    justify-content: center;
    gap: 24px;
    margin-bottom: 0;
    flex-wrap: wrap;
}
.footer-links a {
    color: var(--gray-400);
    font-size: 0.9rem;
    transition: color 0.2s;
}
.footer-links a:hover { color: var(--white); }

/* === Contact form (inside page) === */
.contact-form .form-group { margin-bottom: 16px; }
.contact-form label {
    display: block;
    margin-bottom: 6px;
    font-weight: 600;
    font-size: 0.9rem;
}
.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid var(--gray-200);
    border-radius: 8px;
    font-size: 0.95rem;
    font-family: inherit;
}
.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: var(--navy);
    box-shadow: 0 0 0 3px rgba(26,35,50,0.1);
}

/* === Cookie banner === */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--navy-dark);
    color: var(--white);
    z-index: 9999;
    box-shadow: 0 -2px 12px rgba(0,0,0,0.3);
}

.cookie-inner {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
}

.cookie-inner p {
    flex: 1;
    font-size: 0.9rem;
    line-height: 1.5;
    margin: 0;
}
.cookie-inner a { color: var(--gray-200); text-decoration: underline; }

.cookie-buttons {
    display: flex;
    gap: 10px;
    flex-shrink: 0;
}

.btn-cookie {
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: background 0.2s;
}
.btn-cookie-accept { background: var(--red); color: var(--white); }
.btn-cookie-accept:hover { background: var(--red-hover); }
.btn-cookie-refuse { background: var(--gray-600); color: var(--white); }
.btn-cookie-refuse:hover { background: var(--gray-800); }

/* === Tablette : hub articles 2 colonnes === */
@media (max-width: 1024px) and (min-width: 769px) {
    .hub-articles-grid { grid-template-columns: repeat(2, 1fr); }
}

/* === Responsive === */
@media (max-width: 768px) {

    /* ── Full width : zéro marge gauche/droite, aucun arrondi ── */
    .container { padding: 0; }
    .card { padding: 20px 16px; border-radius: 0 !important; box-shadow: none; border-bottom: 1px solid var(--gray-200); }
    .breadcrumbs { padding: 10px 16px; margin-bottom: 8px; }

    /* Éléments blog sans classe .card mais avec border-radius */
    .blog-cats-list { border-radius: 0 !important; box-shadow: none; }
    .pagination-link { border-radius: 4px; }

    /* Hero */
    .hero h1 { font-size: 1.5rem; }
    .hero { margin-bottom: 0; }

    /* Article hero image déborde sur les bords de la card */
    .article-hero-image { margin: -20px -16px 20px; }

    /* Titres */
    .page-content h1, .article-main h1 { font-size: 1.5rem; }

    /* Grilles */
    .articles-grid { grid-template-columns: 1fr; }
    .article-list-item { flex-direction: column; }
    .article-list-img { width: 100%; height: 200px; }

    /* Hub articles — mobile : 1 colonne */
    .hub-articles-grid { grid-template-columns: 1fr; gap: 14px; }
    .hub-modal { max-height: 95vh; }

    /* ── Navigation mobile ── */
    .nav-toggle { display: flex; }

    /* Header reste au-dessus de l'overlay (z-index dans le root context) */
    .site-header { z-index: 400; }

    /* CRITIQUE : le logo et le bouton hamburger vivent DANS le stacking context
       de .site-header. La nav-list est aussi dedans (z-index: 1). Donc pour que
       logo + hamburger restent visibles au-dessus du menu ouvert, il leur faut
       un z-index plus élevé que la nav-list dans ce même contexte. */
    .site-logo { position: relative; z-index: 2; }
    .nav-toggle { position: relative; z-index: 2; }

    /* Overlay plein écran blanc */
    .site-nav .nav-list {
        position: fixed;
        inset: 0;
        padding: 80px 0 40px; /* 80px = hauteur header laissé visible au-dessus */
        background: var(--white);
        flex-direction: column;
        align-items: stretch;
        justify-content: flex-start;
        gap: 0;
        z-index: 1; /* relatif au contexte de .site-header */
        display: flex;
        opacity: 0;
        pointer-events: none;
        transform: translateY(-8px);
        transition: opacity 0.22s ease, transform 0.22s ease;
        overflow-y: auto;
        overscroll-behavior: contain;
    }
    .site-nav .nav-list.open {
        opacity: 1;
        pointer-events: auto;
        transform: translateY(0);
    }

    /* Items "normaux" (hors CTA) : flex avec chevron à droite et séparateur */
    .site-nav .nav-list > li:not(.nav-cta-item) > a,
    .site-nav .nav-list > li:not(.nav-cta-item) > button {
        display: flex;
        align-items: center;
        justify-content: space-between;
        width: 100%;
        padding: 18px 24px;
        color: var(--navy);
        font-size: 1.05rem;
        font-weight: 500;
        font-family: inherit;
        background: none;
        border: none;
        border-bottom: 1px solid var(--gray-100);
        cursor: pointer;
        text-align: left;
        transition: background 0.12s, color 0.12s;
    }
    .site-nav .nav-list > li:not(.nav-cta-item) > a:hover,
    .site-nav .nav-list > li:not(.nav-cta-item) > button:hover {
        background: var(--gray-50);
        color: var(--red);
    }

    /* Chevron à droite via ::after */
    .site-nav .nav-list > li:not(.nav-cta-item) > a::after,
    .site-nav .nav-list > li:not(.nav-cta-item) > button::after {
        content: '';
        display: inline-block;
        width: 7px;
        height: 7px;
        border-right: 2px solid var(--gray-400);
        border-top: 2px solid var(--gray-400);
        transform: rotate(45deg);
        flex-shrink: 0;
        margin-right: 4px;
    }

    /* Blog : visible sur mobile, sous-menu accordion (toggle JS) */
    .nav-dropdown { display: block !important; }
    .nav-dropdown-label {
        display: flex !important;
        align-items: center !important;
        justify-content: space-between !important;
        width: 100% !important;
        padding: 18px 24px !important;
        color: var(--navy) !important;
        font-size: 1.05rem !important;
        font-weight: 500 !important;
        text-transform: uppercase !important;
        letter-spacing: 0 !important;
        border-bottom: 1px solid var(--gray-100) !important;
        cursor: pointer !important;
        line-height: 1 !important;
        background: transparent !important;
        user-select: none !important;
        transition: background 0.12s, color 0.12s !important;
    }
    .nav-dropdown-label:hover { background: var(--gray-50) !important; color: var(--red) !important; }
    /* Chevron : pointe vers le bas par défaut, vers le haut si ouvert */
    .nav-dropdown-label::after {
        content: '';
        display: inline-block;
        width: 7px;
        height: 7px;
        border-right: 2px solid var(--gray-400);
        border-top: 2px solid var(--gray-400);
        transform: rotate(135deg);
        transition: transform 0.25s ease;
        flex-shrink: 0;
    }
    .nav-dropdown.open .nav-dropdown-label::after {
        transform: rotate(-45deg);
    }
    /* Sous-menu : caché par défaut (display:none), affiché avec .open */
    .nav-dropdown .dropdown-menu {
        display: none !important;
        position: static !important;
        visibility: visible !important;
        opacity: 1 !important;
        background: var(--gray-50) !important;
        box-shadow: none !important;
        border: none !important;
        border-radius: 0 !important;
        min-width: unset !important;
        padding: 0 !important;
        transition: none !important;
    }
    .nav-dropdown.open .dropdown-menu {
        display: block !important;
    }
    .nav-dropdown .dropdown-menu li a {
        color: var(--navy) !important;
        font-size: 0.95rem !important;
        font-weight: 500 !important;
        text-transform: none !important;
        letter-spacing: 0 !important;
        padding: 15px 24px 15px 40px !important;
        border-bottom: 1px solid var(--gray-100) !important;
        background: transparent !important;
        border-radius: 0 !important;
    }
    .nav-dropdown .dropdown-menu li a:hover {
        color: var(--red) !important;
        background: var(--white) !important;
    }
    .nav-dropdown .dropdown-menu li:last-child a { border-bottom: none !important; }

    /* CTA : padding sur le <li> pour créer les marges latérales sans overflow.
       (margin: 0 20px + width stretched = dépassement de 40px, d'où le padding ici.) */
    .nav-cta-item {
        margin: 20px 0 0;
        padding: 0 20px;
    }
    .nav-cta-item > a.btn-cta {
        display: block !important;
        width: 100%;
        padding: 15px 18px !important;
        border-radius: 10px !important;
        font-size: 1rem !important;
        font-weight: 600;
        text-align: center;
        border: none;
    }

    /* ── TOC sidebar : cachée sur mobile, remplacée par le drawer ── */
    .article-layout { display: block; }
    .article-toc-sidebar { display: none; }

    /* FAB sommaire (visible si TOC existe) */
    .toc-fab {
        display: flex;
        position: fixed;
        bottom: 80px;
        right: 16px;
        z-index: 200;
        background: var(--navy);
        color: var(--white);
        border: none;
        border-radius: 50px;
        padding: 11px 16px;
        font-size: 0.8rem;
        font-weight: 600;
        gap: 7px;
        align-items: center;
        cursor: pointer;
        box-shadow: 0 4px 18px rgba(0,0,0,0.28);
        white-space: nowrap;
    }

    /* ── Categories rows ── */
    .blog-cat-row { grid-template-columns: 44px 1fr 24px; }
    .blog-cat-count { display: none; }

    /* ── Divers ── */
    .toc-inline { display: none; }
    .cta-email-row { flex-direction: column; }

}


/* =============================================
   === Bouton recherche dans la nav ===
   ============================================= */
.nav-search-btn {
    background: none;
    border: none;
    cursor: pointer;
    color: var(--gray-600);
    padding: 7px 14px;
    border-radius: 7px;
    font-size: 0.88rem;
    font-family: inherit;
    transition: background 0.15s, color 0.15s;
    line-height: inherit;
    white-space: nowrap;
}
.nav-search-btn:hover { background: var(--gray-200); color: var(--navy); }

/* Masquer la croix native du navigateur sur input[type=search] */
#searchModalInput::-webkit-search-cancel-button { display: none; }
#searchModalInput::-moz-search-cancel-button { display: none; }

/* =============================================
   === Modal de recherche (overlay centré) ===
   ============================================= */
.search-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(10, 15, 25, 0.55);
    backdrop-filter: blur(3px);
    z-index: 1000;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding-top: 80px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
}
.search-modal-overlay.open {
    opacity: 1;
    pointer-events: auto;
}
.search-modal {
    background: var(--white);
    border-radius: 16px;
    box-shadow: 0 24px 60px rgba(0,0,0,0.25);
    width: 100%;
    max-width: 600px;
    margin: 0 16px;
    overflow: hidden;
    transform: translateY(-12px);
    transition: transform 0.2s ease;
}
.search-modal-overlay.open .search-modal {
    transform: translateY(0);
}
.search-modal-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 20px;
    border-bottom: 1px solid var(--gray-100);
}
.search-modal-header > svg {
    flex-shrink: 0;
    color: var(--gray-400);
}
.search-modal-input-wrap {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
}
.search-modal-input-wrap > svg { flex-shrink: 0; color: var(--gray-400); }
#searchModalInput {
    flex: 1;
    border: none;
    outline: none;
    font-size: 1.05rem;
    color: var(--text);
    background: transparent;
    padding: 0;
    min-width: 0;
}
#searchModalInput::placeholder { color: var(--gray-400); }
.search-modal-clear {
    background: none;
    border: none;
    cursor: pointer;
    color: var(--red);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 4px;
    border-radius: 50%;
    flex-shrink: 0;
    transition: background 0.15s;
}
.search-modal-clear:hover { background: rgba(211,47,47,0.08); }
.search-modal-close {
    background: var(--gray-100);
    border: none;
    border-radius: 6px;
    padding: 4px 10px;
    font-size: 0.78rem;
    color: var(--gray-600);
    cursor: pointer;
    white-space: nowrap;
    transition: background 0.15s;
    flex-shrink: 0;
    margin-left: 6px;
}
.search-modal-close:hover { background: var(--gray-200); }

/* Résultats */
.search-modal-results { max-height: 380px; overflow-y: auto; }
.search-suggestions {
    list-style: none;
}
.search-suggestions li a {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 20px;
    border-bottom: 1px solid var(--gray-100);
    transition: background 0.12s;
    text-decoration: none;
}
.search-suggestions li:last-child a { border-bottom: none; }
.search-suggestions li a:hover { background: var(--gray-50); }
.search-suggestions li a img {
    width: 48px;
    height: 48px;
    object-fit: cover;
    border-radius: 8px;
    flex-shrink: 0;
}
.search-sug-thumb-placeholder {
    width: 48px;
    height: 48px;
    border-radius: 8px;
    background: var(--gray-100);
    flex-shrink: 0;
}
.search-sug-text { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.search-sug-text strong { font-size: 0.92rem; color: var(--navy); line-height: 1.35; }
.search-sug-text em { font-size: 0.78rem; color: var(--red); font-style: normal; font-weight: 500; }
.search-suggestion-empty {
    padding: 32px 20px;
    text-align: center;
    color: var(--gray-600);
    font-size: 0.9rem;
}
.search-modal-footer {
    padding: 10px 20px;
    border-top: 1px solid var(--gray-100);
    min-height: 42px;
    display: flex;
    align-items: center;
}
.search-modal-all {
    font-size: 0.85rem;
    color: var(--red);
    font-weight: 600;
}
.search-modal-all:hover { color: var(--red-hover); }

/* =============================================
   === Page Recherche ===
   ============================================= */
.search-form { margin: 24px 0; }
.search-input-wrap {
    display: flex;
    gap: 10px;
    align-items: center;
}
.search-input-inner {
    flex: 1;
    position: relative;
    display: flex;
    align-items: center;
}
.search-input-inner input[type="search"] {
    width: 100%;
    padding: 12px 40px 12px 18px;
    border: 1px solid var(--gray-200);
    border-radius: 10px;
    font-size: 1rem;
    background: var(--white);
    outline: none;
    transition: border-color 0.15s;
}
.search-input-inner input[type="search"]:focus { border-color: var(--navy); }
.search-input-inner input[type="search"]::-webkit-search-cancel-button { display: none; }
.search-input-clear {
    position: absolute;
    right: 12px;
    color: var(--red);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3px;
    border-radius: 50%;
    transition: background 0.15s;
    flex-shrink: 0;
}
.search-input-clear:hover { background: rgba(211,47,47,0.08); }
.search-meta { font-size: 0.9rem; color: var(--gray-600); margin-bottom: 16px; }
.search-empty { padding: 24px 0; color: var(--gray-600); }
.search-empty a { color: var(--red); }

@media (max-width: 768px) {
    .search-input-wrap { flex-direction: column; align-items: stretch; }
    .search-input-inner { flex: none; }
    .search-form .btn { width: 100%; justify-content: center; }
}

/* =============================================
   === Page 404 ===
   ============================================= */
.page-404 { text-align: center; padding: 48px 32px; }
.error-404-icon {
    font-size: 5rem;
    font-weight: 900;
    color: var(--red);
    opacity: 0.15;
    line-height: 1;
    margin-bottom: 16px;
    letter-spacing: -4px;
}
.page-404 h1 { font-size: 2rem; color: var(--navy); margin-bottom: 12px; }
.error-404-desc { color: var(--gray-600); line-height: 1.7; margin-bottom: 28px; }
.search-form-404 { max-width: 480px; margin: 0 auto 28px; }
.error-404-links { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin-bottom: 16px; }

@media (max-width: 768px) {
    .page-404 { padding: 32px 16px; }
    .error-404-icon { font-size: 3.5rem; }
    .page-404 h1 { font-size: 1.5rem; }
    .search-form-404 .search-input-wrap { flex-direction: column; }
    .search-form-404 .search-input-wrap input[type="search"],
    .search-form-404 .search-input-wrap button { width: 100%; }
    .error-404-links { flex-direction: column; align-items: stretch; }
    .error-404-links .btn { text-align: center; }
}

/* =============================================
   === Auteur (liens sociaux) ===
   ============================================= */
.author-bio-links { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 10px; }
.author-bio-name a { color: var(--navy); }
.author-bio-name a:hover { color: var(--red); }
.author-social-link {
    font-size: 0.82rem;
    color: var(--gray-600);
    background: var(--gray-100);
    border-radius: 20px;
    padding: 3px 10px;
    transition: background 0.15s, color 0.15s;
}
.author-social-link:hover { background: var(--navy); color: var(--white); }

/* === Page auteur publique === */
.author-profile {
    padding: 32px;
    margin-bottom: 24px;
}
.author-profile-inner {
    display: flex;
    align-items: flex-start;
    gap: 28px;
}
.author-profile-avatar img {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid var(--white);
    box-shadow: 0 2px 16px rgba(0,0,0,0.12);
}
.author-profile-initial {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: var(--navy);
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    font-weight: 700;
}
.author-profile-name { font-size: 1.6rem; font-weight: 700; color: var(--navy); margin-bottom: 10px; }
.author-profile-bio { color: var(--text-light); line-height: 1.7; margin-bottom: 12px; }
.author-profile-links { display: flex; gap: 10px; flex-wrap: wrap; }
.author-articles-header { margin-bottom: 8px; }
.author-articles-header h2 { font-size: 1.15rem; color: var(--navy); font-weight: 600; }

@media (max-width: 600px) {
    .author-profile-inner { flex-direction: column; align-items: center; text-align: center; }
    .author-profile-links { justify-content: center; }
}

/* =============================================
   === Redesign header — style editorial ===
   ============================================= */
.site-header {
    background: rgba(255,255,255,0.96);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}
/* Nav items : uppercase black bold */
.site-nav .nav-list > li > a,
.site-nav .nav-list > li > .nav-search-btn {
    font-size: 0.72rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: #111827;
    border-radius: 0;
    padding: 8px 10px;
}
.site-nav .nav-list > li > a:hover,
.site-nav .nav-list > li > .nav-search-btn:hover {
    background: transparent;
    color: var(--red);
}
.nav-dropdown-label {
    font-size: 0.72rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: #111827;
    border-radius: 0;
    padding: 8px 10px;
}
/* Search button */
.nav-search-btn {
    font-size: 0.72rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: #111827;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}
/* Dropdown dark */
.dropdown-menu {
    background: #ffffff;
    border-radius: 0;
    box-shadow: 0 4px 24px rgba(0,0,0,0.10);
    border: 1px solid var(--gray-200);
    top: calc(100% + 4px);
    min-width: 240px;
}
.dropdown-menu li a {
    color: #111827 !important;
    font-size: 0.68rem !important;
    font-weight: 700 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.1em !important;
    padding: 12px 18px !important;
    background: transparent !important;
    border-radius: 0 !important;
    border-bottom: 1px solid var(--gray-100) !important;
    transition: color 0.15s, background 0.15s !important;
}
.dropdown-menu li:last-child a { border-bottom: none !important; }
.dropdown-menu li a:hover {
    color: var(--red) !important;
    background: var(--gray-50) !important;
}
/* CTA button */
.btn-cta {
    border-radius: 6px !important;
    font-size: 0.72rem !important;
    font-weight: 900 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.1em !important;
    padding: 10px 20px !important;
    cursor: pointer;
}

/* =============================================
   === Page d'accueil personnalisée ===
   ============================================= */

/* Hero */
.home-hero {
    padding: 96px 20px 80px;
    text-align: center;
    background: radial-gradient(circle at 50% 40%, rgba(211,47,47,0.03) 0%, rgba(255,255,255,0) 70%);
    max-width: var(--max-width);
    margin: 0 auto;
}
.home-hero h1 {
    font-size: clamp(2.4rem, 7vw, 5.5rem);
    font-weight: 900;
    color: #111827;
    line-height: 1.04;
    letter-spacing: -0.04em;
    margin: 0 auto 32px;
    max-width: 900px;
    text-align: center;
}
.home-hero h1 em {
    color: var(--red);
    font-style: italic;
}
.home-hero-sub {
    font-size: clamp(1rem, 2vw, 1.3rem);
    color: var(--gray-600);
    font-weight: 500;
    max-width: 680px;
    margin: 0 auto;
    line-height: 1.7;
}
.home-hero-sub strong {
    color: #111827;
    font-weight: 700;
    text-decoration: underline;
    text-decoration-color: var(--red);
    text-decoration-thickness: 3px;
    text-underline-offset: 6px;
}

/* Philosophie */
.home-philosophie {
    padding: 80px 20px;
    background: var(--white);
    border-top: 1px solid var(--gray-100);
    border-bottom: 1px solid var(--gray-100);
}
.home-philosophie-inner {
    max-width: var(--max-width);
    margin: 0 auto;
    display: flex;
    gap: 80px;
    align-items: flex-start;
}
.home-philosophie-left {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex-shrink: 0;
    width: 220px;
}
.home-philosophie-photo {
    width: 180px;
    height: 180px;
    border-radius: 50%;
    overflow: hidden;
    border: 4px solid var(--gray-100);
    background: var(--gray-100);
    margin-bottom: 24px;
}
.home-philosophie-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    margin: 0;
    border-radius: 0;
}
.home-badges {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 6px;
}
.home-badge {
    display: inline-block;
    padding: 4px 10px;
    font-size: 0.65rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    border-radius: 4px;
    line-height: 1.4;
}
.home-badge-red { background: #fef2f2; color: var(--red); border: 1px solid #fecaca; }
.home-badge-dark { background: #111827; color: #ffffff; }
.home-badge-gray { background: var(--gray-100); color: var(--gray-600); }
.home-badge-outline { background: var(--gray-100); color: var(--gray-600); border: 1px solid var(--gray-200); }

.home-philosophie-right { flex: 1; min-width: 0; }
.home-philosophie-right h2 {
    font-size: clamp(1.6rem, 3.5vw, 2.4rem);
    font-weight: 900;
    color: #111827;
    text-transform: uppercase;
    letter-spacing: -0.03em;
    line-height: 1.05;
    margin: 0 0 32px;
}
.home-philosophie-right p {
    font-size: 1.05rem;
    color: var(--gray-600);
    line-height: 1.8;
    margin-bottom: 20px;
}
.home-philosophie-right p strong { color: #111827; font-weight: 700; }
.home-quote {
    position: relative;
    padding: 28px 32px;
    background: var(--gray-50);
    border-left: 4px solid var(--red);
    margin-top: 32px;
}
.home-quote p {
    font-size: 1.1rem;
    font-weight: 700;
    color: #111827;
    line-height: 1.5;
    margin: 0;
    font-style: normal;
}
.home-quote-icon {
    position: absolute;
    top: 12px;
    right: 16px;
    color: var(--gray-200);
    width: 28px;
    height: 28px;
}

/* Mission */
.home-mission {
    padding: 80px 20px;
}
.home-mission-inner {
    max-width: var(--max-width);
    margin: 0 auto;
    background: #0d1117;
    border-radius: 16px;
    padding: 72px 60px;
    text-align: center;
    position: relative;
    overflow: hidden;
}
.home-mission-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    margin-bottom: 32px;
}
.home-mission-logo svg {
    width: 56px;
    height: 56px;
    color: #ffffff;
}
.home-mission-logo span {
    font-size: 2rem;
    font-weight: 900;
    color: #ffffff;
    text-transform: uppercase;
    letter-spacing: -0.04em;
}
.home-mission-desc {
    font-size: 1.1rem;
    color: rgba(255,255,255,0.5);
    max-width: 600px;
    margin: 0 auto 56px;
    line-height: 1.75;
}
.home-mission-desc strong {
    color: #ffffff;
    font-weight: 700;
    text-decoration: underline;
    text-decoration-color: var(--red);
    text-decoration-thickness: 2px;
    text-underline-offset: 5px;
}
.home-phases {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 10px;
    overflow: hidden;
}
.home-phase {
    padding: 32px 28px;
    text-align: left;
    border-right: 1px solid rgba(255,255,255,0.06);
}
.home-phase:last-child { border-right: none; }
.home-phase-num {
    font-size: 0.65rem;
    font-weight: 900;
    color: var(--red);
    text-transform: uppercase;
    letter-spacing: 0.25em;
    margin-bottom: 16px;
}
.home-phase h4 {
    font-size: 1rem;
    font-weight: 800;
    color: #ffffff;
    text-transform: uppercase;
    letter-spacing: -0.01em;
    margin: 0 0 12px;
}
.home-phase p {
    font-size: 0.82rem;
    color: rgba(255,255,255,0.4);
    line-height: 1.7;
    margin: 0;
}

/* Certitudes */
.home-certitudes {
    padding: 80px 20px;
    background: #fafafa;
}
.home-certitudes-inner {
    max-width: var(--max-width);
    margin: 0 auto;
}
.home-section-label {
    font-size: 0.65rem;
    font-weight: 900;
    color: var(--red);
    text-transform: uppercase;
    letter-spacing: 0.35em;
    margin-bottom: 12px;
    text-align: center;
}
.home-certitudes-inner > h2 {
    font-size: clamp(1.6rem, 3vw, 2.4rem);
    font-weight: 900;
    color: #111827;
    text-transform: uppercase;
    letter-spacing: -0.03em;
    text-align: center;
    margin: 0 0 48px;
}
.home-feat-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}
.home-feat-card {
    background: var(--white);
    padding: 40px 36px;
    border: 1px solid var(--gray-200);
    border-bottom: 3px solid transparent;
    text-align: left;
    transition: border-bottom-color 0.2s, background 0.2s;
}
.home-feat-card:hover {
    border-bottom-color: var(--red);
    background: #fdfdfd;
}
.home-feat-num {
    font-size: 3.5rem;
    font-weight: 900;
    color: var(--gray-200);
    line-height: 1;
    margin-bottom: 20px;
}
.home-feat-card h4 {
    font-size: 1rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: -0.01em;
    color: #111827;
    margin: 0 0 14px;
}
.home-feat-card p {
    font-size: 0.875rem;
    color: var(--gray-600);
    line-height: 1.75;
    font-weight: 500;
    margin: 0;
}

/* Pre-footer CTA home */
.home-prefooter {
    padding: 80px 20px;
    text-align: center;
    background: var(--white);
    border-top: 1px solid var(--gray-100);
}
.home-prefooter h2 {
    font-size: clamp(1.8rem, 4vw, 3.2rem);
    font-weight: 900;
    color: #111827;
    text-transform: uppercase;
    letter-spacing: -0.03em;
    margin: 0 0 36px;
}
.home-prefooter-btn {
    display: inline-block;
    background: var(--red);
    color: #ffffff !important;
    font-size: 0.78rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    padding: 18px 40px;
    border-radius: 6px;
    border: none;
    cursor: pointer;
    transition: background 0.15s;
    text-decoration: none;
}
.home-prefooter-btn:hover { background: var(--red-hover); color: #ffffff !important; }

/* Responsive homepage */
@media (max-width: 900px) {
    .home-philosophie-inner { flex-direction: column; gap: 40px; align-items: center; }
    .home-philosophie-left { width: 100%; }
    .home-phases { grid-template-columns: 1fr; }
    .home-phase { border-right: none; border-bottom: 1px solid rgba(255,255,255,0.06); }
    .home-phase:last-child { border-bottom: none; }
    .home-feat-grid { grid-template-columns: 1fr; }
    .home-mission-inner { padding: 48px 28px; }
    .home-mission-logo span { font-size: 1.4rem; }
}
@media (max-width: 600px) {
    .home-hero { padding: 64px 16px 56px; }
    .home-philosophie, .home-mission, .home-certitudes, .home-prefooter { padding: 56px 16px; }
}

/* =============================================
   === Article — nouveau style editorial ===
   ============================================= */

/* Breadcrumb */
.breadcrumbs ol {
    font-size: 0.68rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    gap: 2px;
}
.breadcrumbs li::after { content: '›'; margin: 0 8px; color: var(--gray-400); font-weight: 400; }
.breadcrumbs a { color: var(--gray-400); }
.breadcrumbs a:hover { color: var(--red); }
.breadcrumb-current { color: #111827; }

/* H1 article */
.article-main h1 {
    font-size: clamp(1.8rem, 4.5vw, 3.2rem);
    font-weight: 900;
    color: #111827;
    line-height: 1.05;
    letter-spacing: -0.035em;
    text-transform: uppercase;
    font-style: italic;
    text-align: left;
    margin: 0 0 32px;
}

/* Meta bar */
.article-header-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 16px;
    font-size: 0.68rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--gray-400);
    border-bottom: 1px solid var(--gray-100);
    padding-bottom: 28px;
    margin-bottom: 32px;
}
.article-category {
    background: #fef2f2;
    color: var(--red) !important;
    border: 1px solid #fecaca;
    font-size: 0.65rem !important;
    text-transform: uppercase !important;
    letter-spacing: 0.1em !important;
    padding: 4px 10px !important;
    border-radius: 4px !important;
}
.article-meta-sep { color: var(--gray-200);  }
.article-updated { color: var(--gray-400); font-style: normal;  font-size: 0.68rem; text-transform: uppercase; letter-spacing: 0.1em; }
.article-reading-time { font-size: 0.68rem;  color: var(--gray-400); }
.article-meta-date, .article-meta-author { display: inline-flex; align-items: center; gap: 5px; }
.article-header-meta > span:last-child,
.article-header-meta > span[class=""] {
    color: var(--gray-400);
    font-size: 0.68rem;
}

/* Hero image */
.article-hero-image {
    margin: 0 0 40px;
    border-radius: 12px;
    overflow: hidden;
}
.article-hero-image img {
    width: 100%;
    height: auto;
    border-radius: 12px;
    display: block;
    margin: 0;
}

/* H2/H3 dans article body — style editorial */
.article-body h2 {
    font-size: clamp(1.25rem, 2.5vw, 1.75rem);
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: -0.03em;
    color: #111827;
    margin: 3rem 0 1.25rem;
    padding-bottom: 0;
    border-bottom: none;
    line-height: 1.1;
}
.article-body h3 {
    font-size: 1rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--navy);
    margin: 2rem 0 0.75rem;
    line-height: 1.2;
}
/* Blockquote new */
.article-body blockquote {
    border-left: 6px solid var(--red);
    padding: 24px 32px;
    background: var(--gray-50);
    font-size: 1.15rem;
    font-weight: 900;
    font-style: italic;
    color: #111827;
    letter-spacing: -0.02em;
    text-transform: uppercase;
    margin: 32px 0;
    border-radius: 0 8px 8px 0;
}

/* TOC sidebar — titre sobre, sans cadre ni gras */
.toc-title {
    font-size: 0.62rem !important;
    font-weight: 500 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.28em !important;
    color: var(--gray-400) !important;
    margin: 0 0 16px !important;
    padding: 0 !important;
    border: none !important;
    display: block !important;
    line-height: 1 !important;
}
.toc-sidebar-box li a {
    font-size: 0.68rem !important;
    font-weight: 500 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.1em !important;
    color: var(--gray-400) !important;
    border-left: 2px solid var(--gray-100);
    padding: 6px 0 6px 16px !important;
    display: block;
    transition: color 0.15s, border-left-color 0.15s;
}
.toc-sidebar-box li a:hover { color: var(--red) !important; border-left-color: var(--red) !important; }
.toc-sidebar-box li a.active {
    color: var(--red) !important;
    font-weight: 700 !important;
    border-left-color: var(--red) !important;
    background: transparent !important;
}

/* =============================================
   === Pages secondaires — style editorial ===
   ============================================= */

/* Titres de section des pages secondaires */
.page-content h1,
.article-main h1:not(.article-main .article-main h1) {
    font-size: clamp(1.5rem, 3vw, 2rem);
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: -0.03em;
    color: #111827;
    text-align: left;
    margin: 0 0 24px;
    line-height: 1.1;
}
.category-page-title {
    font-size: clamp(1.5rem, 3vw, 2rem);
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: -0.03em;
    color: #111827;
    text-align: left;
    margin: 0 0 8px;
}

/* Listing articles — nouveau style */
.article-list-body h2 a {
    font-size: 1.05rem;
    font-weight: 800;
    color: #111827;
    letter-spacing: -0.01em;
}
.article-list-body h2 a:hover { color: var(--red); }
.article-list-body p { color: var(--gray-600); font-size: 0.9rem; }
.article-meta { font-size: 0.68rem; font-weight: 900; text-transform: uppercase; letter-spacing: 0.1em; color: var(--gray-400); margin-top: 8px; }
.article-meta time, .article-meta span { color: var(--gray-400); }

/* 404 */
.error-404-icon {
    font-size: 6rem;
    font-weight: 900;
    color: var(--gray-200);
    letter-spacing: -0.05em;
    line-height: 1;
    margin-bottom: 16px;
    font-style: italic;
}
.page-404 h1 {
    font-size: 1.5rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: -0.02em;
    color: #111827;
}
.error-404-desc { color: var(--gray-600); font-size: 0.95rem; }

/* Search */
.search-meta { font-size: 0.8rem; font-weight: 700; color: var(--gray-600); margin: 20px 0; }

/* Contact form */
.page-content form label {
    font-size: 0.72rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: #111827;
}

/* === Fix nav "Blog" vertical alignment (desktop uniquement) === */

/* =============================================
   === Article — H1 block (pleine largeur) ===
   ============================================= */
.article-h1-block {
    max-width: 900px;
    margin: 24px 0 48px;
}
.article-h1-block h1 {
    font-size: clamp(2.2rem, 5.5vw, 4rem);
    font-weight: 900;
    color: #111827;
    line-height: 1;
    letter-spacing: -0.05em;
    text-transform: uppercase;
    font-style: italic;
    margin: 0 0 28px;
    text-align: left;
}

/* Meta bar : supprime les séparateurs — tous sur une ligne */
.article-meta-sep { display: none !important; }
.article-header-meta {
    display: flex !important;
    flex-wrap: nowrap !important;
    align-items: center !important;
    justify-content: flex-start;
    gap: 16px;
    padding-bottom: 32px;
    margin-bottom: 0;
}

/* Article content — sans card */
.article-main-content {
    min-width: 0;
    background: none;
    border: none;
    box-shadow: none;
    border-radius: 0;
    padding: 0;
    margin-bottom: 40px;
}
.article-main-content .article-hero-image {
    margin: 0 0 48px;
    border-radius: 12px;
    overflow: hidden;
    background: var(--gray-100);
    border: 1px solid var(--gray-200);
}
.article-main-content .article-hero-image img {
    width: 100%;
    height: 400px;
    object-fit: cover;
    border-radius: 0;
    margin: 0;
    display: block;
    max-height: none;
}
.article-main-content .article-hero-image figcaption {
    text-align: center;
    font-size: 0.8rem;
    color: var(--gray-600);
    padding: 10px 20px;
    font-style: italic;
}
/* Layout article avec TOC — alignement top */
.article-layout {
    align-items: start;
    margin-bottom: 0;
}

@media (max-width: 768px) {
    .article-h1-block { margin: 16px 0 32px; }
    .article-h1-block h1 { font-size: clamp(1.9rem, 8vw, 2.8rem); }
    .article-main-content .article-hero-image img { height: 220px; }
}

/* =============================================
   === Articles listing — style editorial ===
   ============================================= */
.articles-page-h1 {
    font-size: clamp(2.2rem, 7vw, 4.5rem);
    font-weight: 900;
    color: #111827;
    text-transform: uppercase;
    font-style: italic;
    letter-spacing: -0.05em;
    line-height: 1;
    margin: 32px 0 48px;
}
.articles-editorial-list {
    background: var(--white);
    border-radius: var(--radius);
    overflow: hidden;
    margin-bottom: 40px;
}
.article-editorial-item {
    display: flex;
    gap: 40px;
    align-items: flex-start;
    padding: 40px;
    border-bottom: 1px solid #f3f4f6;
    transition: background 0.2s;
}
.article-editorial-item:last-child { border-bottom: none; }
.article-editorial-item:hover { background: #fcfcfc; }
.article-editorial-item:hover h2 a { color: var(--red); }
.article-editorial-img {
    width: 288px;
    height: 192px;
    flex-shrink: 0;
    border-radius: 8px;
    overflow: hidden;
    background: var(--gray-100);
    border: 1px solid var(--gray-100);
    display: block;
    transition: opacity 0.2s;
}
.article-editorial-img:hover { opacity: 0.9; }
.article-editorial-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    margin: 0;
    border-radius: 0;
}
.article-editorial-img-placeholder {
    width: 288px;
    height: 192px;
    flex-shrink: 0;
    border-radius: 8px;
    background: var(--gray-100);
    border: 1px solid var(--gray-100);
}
.article-editorial-body { flex: 1; min-width: 0; }
.article-editorial-meta-top {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 16px;
}
.article-editorial-date {
    font-size: 0.68rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--gray-400);
}
.article-editorial-item h2 {
    font-size: clamp(1.3rem, 2.5vw, 1.9rem);
    font-weight: 900;
    color: #111827;
    text-transform: uppercase;
    letter-spacing: -0.03em;
    font-style: italic;
    line-height: 1.1;
    margin: 0 0 16px;
    border: none;
    padding: 0;
    transition: color 0.2s;
}
.article-editorial-item h2 a { color: inherit; text-decoration: none; }
.article-editorial-item h2 a:hover { color: var(--red); }
.article-editorial-body > p {
    color: var(--gray-600);
    font-size: 0.92rem;
    line-height: 1.7;
    margin: 0 0 24px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.article-editorial-readmore {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.68rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: var(--red);
    text-decoration: none;
    transition: gap 0.2s;
}
.article-editorial-readmore:hover { gap: 14px; color: var(--red); }

@media (max-width: 768px) {
    .article-editorial-item {
        flex-direction: column;
        padding: 24px 16px;
        gap: 20px;
    }
    .article-editorial-img,
    .article-editorial-img-placeholder {
        width: 100%;
        height: 180px;
    }
    .articles-page-h1 {
        font-size: clamp(1.9rem, 9vw, 3rem);
        margin: 16px 0 32px;
        text-align: center;
    }
}

/* =============================================
   === Fix nav "Blog" alignment — desktop only ===
   Tous les <li> nav = 80px (hauteur header) + flex center
   => alignement vertical garanti pour tous les items
   ============================================= */
@media (min-width: 769px) {
    .site-nav .nav-list > li {
        display: flex !important;
        align-items: center !important;
        height: 80px !important;
    }
    .site-nav .nav-list > li > a,
    .site-nav .nav-list > li > .nav-search-btn {
        display: flex !important;
        align-items: center !important;
        line-height: 1 !important;
    }
    .nav-dropdown { position: relative !important; }
    .nav-dropdown-label {
        display: flex !important;
        align-items: center !important;
        line-height: 1 !important;
        cursor: default !important;
        user-select: none !important;
    }
}

/* =============================================
   === Fix menu mobile — backdrop-filter bug ===
   ============================================= */
@media (max-width: 768px) {
    .site-header {
        backdrop-filter: none !important;
        -webkit-backdrop-filter: none !important;
        background: #ffffff !important;
    }
}

/* =============================================
   === Mobile — corrections générales ===
   ============================================= */
@media (max-width: 768px) {
    /* Centre les H1 */
    .article-h1-block { padding: 0 16px; margin: 16px 0 28px; }
    .article-h1-block h1 { text-align: center; }
    .article-h1-block .article-header-meta { justify-content: center; flex-wrap: wrap !important; gap: 10px; }

    /* Padding contenu article */
    .article-main-content { padding: 0 16px; }

    /* TOC drawer au-dessus du header (z-index > 400) */
    .toc-drawer { z-index: 500; }
    .toc-drawer-overlay { z-index: 490; }

    /* FAB sommaire : icône seule, rond */
    .toc-fab {
        border-radius: 50% !important;
        width: 52px !important;
        height: 52px !important;
        min-width: 52px !important;
        padding: 0 !important;
        gap: 0 !important;
        font-size: 0 !important;
        bottom: 24px !important;
        right: 16px !important;
        justify-content: center !important;
        align-items: center !important;
        z-index: 200;
    }
    .toc-fab svg {
        width: 22px !important;
        height: 22px !important;
        flex-shrink: 0 !important;
        display: block !important;
        font-size: initial !important;
    }
}

/* =============================================
   === Article — author meta (inline, même style que les autres métas) ===
   ============================================= */
.article-meta-author {
    display: inline-flex !important;
    align-items: center !important;
    color: var(--gray-400) !important;
    text-decoration: none !important;
    font-size: 0.68rem !important;
    text-transform: uppercase !important;
    letter-spacing: 0.12em !important;
    gap: 0 !important;
}

/* =============================================
   === Articles sur ce thème — redesign ===
   ============================================= */
.hub-children {
    margin-top: 56px;
    padding-top: 40px;
    border-top: 1px solid var(--gray-100);
    margin-bottom: 48px;
}
.hub-children-title {
    font-size: clamp(1rem, 2vw, 1.3rem) !important;
    font-weight: 900 !important;
    color: #111827 !important;
    text-transform: uppercase !important;
    letter-spacing: -0.01em !important;
    font-style: italic !important;
    margin: 0 0 28px !important;
    border: none !important;
    padding: 0 !important;
}
.hub-children-grid {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 0 !important;
}
.hub-child-card {
    display: flex !important;
    gap: 14px !important;
    align-items: flex-start !important;
    padding: 18px 20px 18px 0 !important;
    border-bottom: 1px solid var(--gray-100) !important;
    border-left: none !important;
    border-right: none !important;
    border-top: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    background: none !important;
    text-decoration: none !important;
    color: inherit !important;
    transition: background 0.15s !important;
}
.hub-child-card:nth-child(even) {
    padding-left: 20px !important;
    padding-right: 0 !important;
    border-left: 1px solid var(--gray-100) !important;
}
.hub-child-card:hover { background: #fafafa !important; border-bottom-color: var(--red) !important; }
.hub-child-card:hover h3 { color: var(--red); }
.hub-child-card:hover .hub-child-link { letter-spacing: 0.2em !important; }
.hub-child-img {
    width: 96px !important;
    height: 54px !important;
    flex-shrink: 0 !important;
    border-radius: 6px !important;
    overflow: hidden !important;
    background: var(--gray-100) !important;
}
.hub-child-img img {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    display: block !important;
    margin: 0 !important;
    border-radius: 0 !important;
}
.hub-child-body { flex: 1; min-width: 0; }
.hub-child-body h3 {
    font-size: 0.82rem !important;
    font-weight: 700 !important;
    color: #111827 !important;
    line-height: 1.35 !important;
    margin: 0 0 6px !important;
    transition: color 0.15s;
    text-transform: none !important;
}
.hub-child-link {
    font-size: 0.62rem !important;
    font-weight: 900 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.15em !important;
    color: var(--red) !important;
    transition: letter-spacing 0.2s !important;
}

@media (max-width: 768px) {
    .hub-children { padding: 0 16px !important; }
    .hub-children-grid { grid-template-columns: 1fr !important; }
    .hub-child-card {
        padding-left: 0 !important;
        padding-right: 0 !important;
    }
    .hub-child-card:nth-child(even) {
        padding-left: 0 !important;
        border-left: none !important;
    }
}

/* =============================================
   === Pages Catégories ===
   ============================================= */
.categories-page-h1 {
    font-size: clamp(2rem, 6vw, 4rem);
    font-weight: 900;
    color: #111827;
    text-transform: uppercase;
    font-style: italic;
    letter-spacing: -0.05em;
    line-height: 1;
    margin: 32px 0 40px;
}
.blog-cats-list {
    box-shadow: none;
    border: 1px solid var(--gray-200);
}

/* =============================================
   === Page catégorie (liste articles) ===
   ============================================= */
.category-page-h1 {
    font-size: clamp(1.8rem, 5vw, 3.5rem);
    font-weight: 900;
    color: #111827;
    text-transform: uppercase;
    font-style: italic;
    letter-spacing: -0.05em;
    line-height: 1;
    margin: 24px 0 10px;
}
.category-page-desc {
    font-size: 1rem;
    color: var(--gray-600);
    margin: 0 0 40px;
    line-height: 1.65;
}

/* =============================================
   === Page Recherche — style éditorial ===
   ============================================= */
.search-page-h1 {
    font-size: clamp(1.8rem, 5vw, 3.5rem);
    font-weight: 900;
    color: #111827;
    text-transform: uppercase;
    font-style: italic;
    letter-spacing: -0.05em;
    line-height: 1;
    margin: 32px 0 32px;
}
.search-form-editorial { margin: 0 0 32px; }
.search-form-editorial .search-input-wrap { display: flex; gap: 12px; align-items: center; }
.search-form-editorial .search-input-inner {
    flex: 1;
    position: relative;
    display: flex;
    align-items: center;
}
.search-form-editorial input[type="search"] {
    width: 100%;
    padding: 14px 44px 14px 18px;
    border: 2px solid var(--gray-200);
    border-radius: 8px;
    font-size: 1rem;
    font-family: inherit;
    background: var(--white);
    outline: none;
    transition: border-color 0.15s;
    box-sizing: border-box;
}
.search-form-editorial input[type="search"]:focus { border-color: #111827; }
.search-form-editorial input[type="search"]::-webkit-search-cancel-button { display: none; }
.btn-search-submit {
    background: #111827;
    color: #ffffff;
    border: none;
    padding: 14px 28px;
    border-radius: 8px;
    font-size: 0.72rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    cursor: pointer;
    white-space: nowrap;
    transition: background 0.15s;
    font-family: inherit;
}
.btn-search-submit:hover { background: var(--red); }

/* =============================================
   === Page Contact — style éditorial ===
   ============================================= */
.contact-wrapper {
    max-width: 620px;
    margin: 0 auto;
    padding: 0 0 60px;
}
.contact-h1 {
    font-size: clamp(2rem, 6vw, 4rem);
    font-weight: 900;
    color: #111827;
    text-transform: uppercase;
    font-style: italic;
    letter-spacing: -0.05em;
    line-height: 1;
    margin: 32px 0 40px;
}
.contact-form-editorial .form-group { margin-bottom: 20px; }
.contact-form-editorial label {
    display: block;
    font-size: 0.68rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: #111827;
    margin-bottom: 8px;
}
.contact-form-editorial input[type="text"],
.contact-form-editorial input[type="email"],
.contact-form-editorial textarea {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--gray-200);
    border-radius: 8px;
    font-size: 0.95rem;
    font-family: inherit;
    transition: border-color 0.15s;
    box-sizing: border-box;
}
.contact-form-editorial input:focus,
.contact-form-editorial textarea:focus {
    outline: none;
    border-color: #111827;
    box-shadow: 0 0 0 3px rgba(17,24,39,0.07);
}
.contact-form-editorial textarea { resize: vertical; }
.contact-consent-label {
    display: flex !important;
    align-items: flex-start;
    gap: 12px;
    cursor: pointer;
    font-size: 0.82rem !important;
    font-weight: 400 !important;
    text-transform: none !important;
    letter-spacing: 0 !important;
    color: var(--gray-600);
}
.contact-consent-label input[type="checkbox"] { margin-top: 3px; flex-shrink: 0; }
.contact-btn-submit {
    width: 100%;
    padding: 15px;
    background: #111827;
    color: #ffffff;
    border: none;
    border-radius: 8px;
    font-size: 0.72rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    cursor: pointer;
    transition: background 0.15s;
    font-family: inherit;
    margin-top: 8px;
}
.contact-btn-submit:hover { background: var(--red); }

@media (max-width: 768px) {
    .categories-page-h1,
    .category-page-h1,
    .search-page-h1 { text-align: center; }
    .contact-h1 { text-align: center; }
    .search-form-editorial .search-input-wrap { flex-direction: column; align-items: stretch; }
    .btn-search-submit { width: 100%; text-align: center; }
    .contact-wrapper { padding: 0 16px 60px; }
}

/* === Lien popup MailerLite dans les articles === */
.ml-popup-link {
    color: var(--red) !important;
    font-weight: 700;
    text-decoration: underline;
    text-underline-offset: 3px;
    cursor: pointer;
    transition: color 0.15s, opacity 0.15s;
}
.ml-popup-link:hover { opacity: 0.75; }

/* === Tableaux dans les articles === */
.article-body table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
    margin: 24px 0;
    font-size: 0.9rem;
}
.article-body table th,
.article-body table td {
    border: 1px solid #d1d5db;
    padding: 10px 14px;
    text-align: left;
    word-break: break-word;
    vertical-align: top;
}
.article-body table thead th {
    background: #f1f3f5;
    font-weight: 700;
    color: var(--navy);
}
.article-body table tbody tr:nth-child(even) { background: #f8f9fa; }
@media (max-width: 768px) {
    .article-body table { font-size: 0.82rem; }
    .article-body table th,
    .article-body table td { padding: 8px 10px; }
}

/* === MailerLite popup : apparition instantanée === */
.ml-popup-overlay,
.ml-popup-container,
.ml-subscribe-popup,
[class*="ml-popup"],
[id*="mlb2"] {
    animation: none !important;
    animation-duration: 0s !important;
    transition: none !important;
}
.ml-popup-overlay { animation-fill-mode: none !important; }
.ml-popup-container * { transition: none !important; }
