/* ── Pyrénées — Page numéros ── v1.7 ─────────────────────────────────────── */

/* ── Articles de dossier : masquer la section featured image (token @ET-DC@
   non résolu dans le Theme Builder — img src cassée crée un grand espace blanc) */

body.pyr-article-dossier .et_pb_section_0_tb_body {
    display: none;
}

/* ── Navigation retour au dossier (articles appartenant à un dossier) ────── */

.pyr-post-dos-nav {
    margin-bottom: 32px;
    padding-bottom: 24px;
    border-bottom: 1px solid rgba(20, 29, 31, 0.10);
}

.pyr-post-dos-nav__back {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: #b4501f;
    text-decoration: none !important;
    transition: opacity 0.2s;
}

.pyr-post-dos-nav__back:hover { opacity: 0.7; }

/* Page numéros (ID 9247) — supprime les contraintes du row/column Divi */
body.page-id-9247 #main-content .et_pb_row,
body.page-id-9247 #main-content .et_pb_column,
body.page-id-9247 #main-content .et_pb_text,
body.page-id-9247 #main-content .et_pb_text_inner {
    max-width: none !important;
    width: 100% !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    box-sizing: border-box !important;
}

/* ── Hero ────────────────────────────────────────────────────────────────── */

.pyr-num-hero {
    background-color: #f3ede2;
    padding: 80px 5%;
    border-bottom: 1px solid rgba(20, 29, 31, 0.08);
}

.pyr-num-hero__inner {
    max-width: 1240px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 320px 1fr;
    gap: 80px;
    align-items: start;
}

/* ── Couverture (card verticale + tag) ───────────────────────────────────── */

.pyr-num-hero__cover-wrap {
    position: relative;
}

.pyr-num-hero__cov {
    display: block;
    position: relative;
    aspect-ratio: 34 / 50;
    overflow: hidden;
    border-radius: 10px;
    box-shadow:
        rgba(20, 29, 31, 0.40) 0px 20px 40px -12px,
        rgba(20, 29, 31, 0.12) 0px 6px 16px;
    transition: transform 0.45s cubic-bezier(0.2, 0.7, 0.3, 1),
                box-shadow 0.45s;
    text-decoration: none !important;
}

.pyr-num-hero__cov:hover {
    transform: translateY(-8px) rotate(-0.8deg);
    box-shadow:
        rgba(20, 29, 31, 0.50) 0px 30px 56px -14px,
        rgba(20, 29, 31, 0.14) 0px 10px 24px;
}

.pyr-num-hero__cov img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.pyr-num-hero__cov-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(170deg, #3b5054 0%, #8a9a93 74%, #c9bca5 100%);
}

/* Tag "DERNIER PARU" sur la couverture */
.pyr-num-hero__cov-tag {
    position: absolute;
    bottom: 32px;
    left: 0;
    background-color: #b4501f;
    color: #ffffff;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    padding: 9px 16px;
    pointer-events: none;
}

/* ── Infos ───────────────────────────────────────────────────────────────── */

.pyr-num-hero__info {
    padding-top: 12px;
}

.pyr-num-hero__kicker {
    display: block;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: #b4501f;
    margin-bottom: 18px;
}

.pyr-num-hero__num {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 56px;
    line-height: 1.0;
    color: #141d1f;
    margin: 0 0 24px;
    font-weight: normal;
}

.pyr-num-hero__num em {
    font-style: italic;
    color: #b4501f;
}

.pyr-num-hero__divider {
    border: none;
    border-top: 1px solid rgba(20, 29, 31, 0.15);
    margin: 20px 0;
}

.pyr-num-hero__intro {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 16px;
    line-height: 1.65;
    color: #3a3530;
    margin: 0;
}

/* Sommaire */
.pyr-num-hero__som-label {
    display: block;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: #b4501f;
    margin-bottom: 14px;
}

.pyr-num-hero__som-list {
    list-style: none;
    margin: 0 0 28px;
    padding: 0;
    columns: 2;
    column-gap: 40px;
}

.pyr-num-hero__som-list li {
    font-size: 14px;
    color: #3a3530;
    line-height: 1.45;
    padding: 5px 0 5px 16px;
    position: relative;
    break-inside: avoid;
}

.pyr-num-hero__som-list li::before {
    content: "—";
    position: absolute;
    left: 0;
    color: #b4501f;
}

.pyr-num-hero__btns {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 8px;
}

/* ── Boutons ─────────────────────────────────────────────────────────────── */

.pyr-btn {
    display: inline-block;
    padding: 13px 26px;
    border-radius: 3px;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.03em;
    text-decoration: none !important;
    line-height: 1;
    transition: opacity 0.2s, transform 0.15s;
}

.pyr-btn:hover {
    opacity: 0.80;
    transform: translateY(-1px);
}

.pyr-btn--gold {
    background-color: #b4501f;
    color: #ffffff !important;
    border: 2px solid #b4501f;
}

.pyr-btn--outline {
    background-color: transparent;
    color: #141d1f !important;
    border: 2px solid rgba(20, 29, 31, 0.3);
}

.pyr-btn--outline-dark {
    background-color: transparent;
    color: #141d1f !important;
    border: 1.5px solid rgba(20, 29, 31, 0.35);
    font-size: 13px;
    padding: 12px 24px;
}

.pyr-btn--outline-dark:hover {
    border-color: #141d1f;
}

/* ── Sections ────────────────────────────────────────────────────────────── */

.pyr-num-section {
    padding: 72px 5%;
}

.pyr-num-section--white { background-color: #fbf8f2; }
.pyr-num-section--beige { background-color: #eae1d2; }

.pyr-num-section__inner {
    max-width: 1240px;
    margin: 0 auto;
}

.pyr-num-section__head {
    margin-bottom: 48px;
}

.pyr-num-section__head h2 {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 32px;
    font-weight: normal;
    color: #141d1f;
    margin: 0 0 10px;
    line-height: 1.2;
}

.pyr-num-section__head h2 em {
    font-style: italic;
}

.pyr-num-section__head p {
    color: #6b6559;
    font-size: 15px;
    margin: 0;
}

/* ── Groupes par année ───────────────────────────────────────────────────── */

.pyr-num-year-group {
    margin-bottom: 52px;
}

.pyr-num-year-group:last-child {
    margin-bottom: 0;
}

.pyr-num-year-heading {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 22px;
    font-weight: normal;
    color: #141d1f;
    border-bottom: 2px solid #141d1f;
    padding-bottom: 8px;
    margin: 0 0 20px;
}

/* ── Grilles ─────────────────────────────────────────────────────────────── */

.pyr-num-grid {
    display: grid;
    gap: 24px 20px;
}

.pyr-num-grid--recent {
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
}

.pyr-num-grid--archive {
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
}

/* ── Cartes ──────────────────────────────────────────────────────────────── */

.pyr-num-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    text-decoration: none !important;
    color: inherit;
    gap: 8px;
}

.pyr-num-card__thumb {
    width: 100%;
    overflow: hidden;
    aspect-ratio: 34 / 50;
    border-radius: 7px;
    box-shadow:
        rgba(20, 29, 31, 0.28) 0px 10px 24px -8px,
        rgba(20, 29, 31, 0.08) 0px 3px 8px;
    transition: transform 0.45s cubic-bezier(0.2, 0.7, 0.3, 1),
                box-shadow 0.45s;
}

.pyr-num-card--recent .pyr-num-card__thumb { max-width: 220px; }
.pyr-num-card--archive .pyr-num-card__thumb { max-width: 160px; }

.pyr-num-card:hover .pyr-num-card__thumb {
    transform: translateY(-8px) rotate(-0.8deg);
    box-shadow:
        rgba(20, 29, 31, 0.45) 0px 22px 40px -10px,
        rgba(20, 29, 31, 0.10) 0px 6px 14px;
}

.pyr-num-card__thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.pyr-num-card__placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(170deg, #3b5054 0%, #c9bca5 100%);
}

.pyr-num-card__num {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 14px;
    font-weight: normal;
    color: #141d1f;
    display: block;
    margin: 0;
    line-height: 1.2;
}

.pyr-num-card--recent .pyr-num-card__num {
    font-size: 16px;
}

.pyr-num-card__period {
    font-size: 12px;
    color: #6b6559;
    line-height: 1.3;
    display: block;
}

/* ── Responsive ──────────────────────────────────────────────────────────── */

@media (max-width: 1024px) {
    .pyr-num-hero__inner {
        grid-template-columns: 260px 1fr;
        gap: 56px;
    }
    .pyr-num-hero__num { font-size: 46px; }
}

@media (max-width: 768px) {
    .pyr-num-hero { padding: 48px 5%; }
    .pyr-num-hero__inner {
        grid-template-columns: 1fr;
        gap: 36px;
        text-align: center;
    }
    .pyr-num-hero__cover-wrap {
        max-width: 200px;
        margin: 0 auto;
    }
    .pyr-num-hero__cov-tag { left: 0; }
    .pyr-num-hero__som-list { columns: 1; }
    .pyr-num-hero__btns { justify-content: center; }
    .pyr-num-hero__num { font-size: 38px; }

    .pyr-num-grid--recent {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    }
    .pyr-num-grid--archive {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    }
    .pyr-num-section { padding: 48px 5%; }
    .pyr-num-section__head h2 { font-size: 26px; }
}

@media (max-width: 480px) {
    .pyr-num-grid--recent  { grid-template-columns: repeat(2, 1fr); }
    .pyr-num-grid--archive { grid-template-columns: repeat(3, 1fr); }
}

/* ── Dossiers — neutralisation Divi (ciblé par classe, pas par page ID) ──── */

.pyr-dos-wrap.et_pb_section,
.pyr-dos-wrap .et_pb_row,
.pyr-dos-wrap .et_pb_column,
.pyr-dos-wrap .et_pb_text,
.pyr-dos-wrap .et_pb_text_inner {
    max-width: none !important;
    width: 100% !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    padding-top: 0 !important;
    padding-bottom: 0 !important;
    box-sizing: border-box !important;
}

/* ── Dossiers — mise en page ─────────────────────────────────────────────── */

.pyr-dos-section {
    padding: 72px 5%;
    background-color: #f3ede2;
}

.pyr-dos-inner {
    max-width: 1240px;
    margin: 0 auto;
}

.pyr-dos-head {
    margin-bottom: 48px;
}

.pyr-dos-head h2 {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 32px;
    font-weight: normal;
    color: #141d1f;
    margin: 0 0 10px;
    line-height: 1.2;
}

.pyr-dos-head h2 em { font-style: italic; }

.pyr-dos-head p {
    color: #6b6559;
    font-size: 15px;
    margin: 0;
}

.pyr-dos-list {
    list-style: none;
    margin: 0;
    padding: 0;
    border-top: 1px solid rgba(20, 29, 31, 0.12);
}

.pyr-dos-item {
    border-bottom: 1px solid rgba(20, 29, 31, 0.12);
}

.pyr-dos-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 14px 4px;
    text-decoration: none !important;
    color: inherit;
    transition: padding-left 0.2s;
}

.pyr-dos-link:hover {
    padding-left: 10px;
}

.pyr-dos-link__title {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 16px;
    line-height: 1.4;
    color: #141d1f;
    transition: color 0.2s;
}

.pyr-dos-link:hover .pyr-dos-link__title {
    color: #b4501f;
}

.pyr-dos-link__right {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-shrink: 0;
}

.pyr-dos-link__count {
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #6b6559;
}

.pyr-dos-link__arrow {
    font-size: 15px;
    color: rgba(20, 29, 31, 0.30);
    transition: transform 0.2s, color 0.2s;
}

.pyr-dos-link:hover .pyr-dos-link__arrow {
    transform: translateX(4px);
    color: #b4501f;
}

@media (max-width: 768px) {
    .pyr-dos-section { padding: 48px 5%; }
    .pyr-dos-link { padding: 12px 4px; }
    .pyr-dos-link__title { font-size: 15px; }
}

/* ── Hub actualités — grille de catégories ──────────────────────────────── */

.pyr-dos-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 12px;
}

.pyr-dos-card {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 20px 20px 18px;
    background: #ffffff;
    border: 1px solid rgba(20, 29, 31, 0.10);
    border-radius: 6px;
    text-decoration: none !important;
    color: inherit;
    transition: border-color 0.2s, box-shadow 0.2s, transform 0.2s;
}

.pyr-dos-card:hover {
    border-color: #b4501f;
    box-shadow: rgba(20, 29, 31, 0.08) 0px 4px 16px;
    transform: translateY(-2px);
}

.pyr-dos-card__title {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 15px;
    line-height: 1.3;
    color: #141d1f;
    transition: color 0.2s;
}

.pyr-dos-card:hover .pyr-dos-card__title { color: #b4501f; }

.pyr-dos-card__count {
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #6b6559;
}

@media (max-width: 768px) {
    .pyr-dos-grid { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 10px; }
}

/* ── Archive dossier — neutralise le container Divi en mode page classique ─ */

body.pyr-dossier-archive #main-content .container,
body.pyr-dossier-archive #main-content #content-area,
body.pyr-dossier-archive #main-content article.et_pb_post,
body.pyr-dossier-archive #main-content .entry-content {
    max-width: none !important;
    padding: 0 !important;
    margin: 0 !important;
    width: 100% !important;
    box-sizing: border-box !important;
}

/* ── Archive dossier ─────────────────────────────────────────────────────── */

.pyr-arc-header {
    background-color: #f3ede2;
    padding: 56px 5% 52px;
    border-bottom: 1px solid rgba(20, 29, 31, 0.08);
}

.pyr-arc-header__inner {
    max-width: 1240px;
    margin: 0 auto;
}

.pyr-arc-back {
    display: inline-block;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: #b4501f;
    text-decoration: none !important;
    margin-bottom: 28px;
    transition: opacity 0.2s;
}

.pyr-arc-back:hover { opacity: 0.7; }

.pyr-arc-header__title {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 40px;
    font-weight: normal;
    color: #141d1f;
    line-height: 1.2;
    margin: 0 0 18px;
    max-width: 800px;
}

.pyr-arc-header__desc {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 16px;
    color: #3a3530;
    line-height: 1.65;
    margin: 0 0 18px;
    max-width: 640px;
}

.pyr-arc-header__count {
    display: block;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: #b4501f;
}

/* ── Liste ───────────────────────────────────────────────────────────────── */

.pyr-arc-list {
    background-color: #fbf8f2;
    padding: 56px 5% 72px;
}

.pyr-arc-list__inner {
    max-width: 800px;
    margin: 0 auto;
    border-top: 1px solid rgba(20, 29, 31, 0.12);
}

/* ── Ligne article ───────────────────────────────────────────────────────── */

.pyr-arc-row {
    border-bottom: 1px solid rgba(20, 29, 31, 0.12);
}

.pyr-arc-row__link {
    display: block;
    padding: 24px 4px;
    text-decoration: none !important;
    color: inherit;
    transition: padding-left 0.2s;
}

.pyr-arc-row__link:hover {
    padding-left: 10px;
}

.pyr-arc-row__date {
    display: block;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #6b6559;
    margin-bottom: 8px;
}

.pyr-arc-row__title {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 20px;
    font-weight: normal;
    line-height: 1.35;
    color: #141d1f;
    margin: 0 0 10px;
    transition: color 0.2s;
}

.pyr-arc-row__link:hover .pyr-arc-row__title {
    color: #b4501f;
}

.pyr-arc-row__excerpt {
    font-size: 14px;
    line-height: 1.65;
    color: #6b6559;
    margin: 0;
}

/* ── Responsive archive ───────────────────────────────────────────────────── */

@media (max-width: 768px) {
    .pyr-arc-header { padding: 40px 5%; }
    .pyr-arc-header__title { font-size: 28px; }
    .pyr-arc-list { padding: 40px 5% 56px; }
    .pyr-arc-row__title { font-size: 18px; }
}

/* ── Actualités — neutralisation Divi (page hub) ────────────────────────── */

body.pyr-page-actualites #main-content .et_pb_row,
body.pyr-page-actualites #main-content .et_pb_column,
body.pyr-page-actualites #main-content .et_pb_text,
body.pyr-page-actualites #main-content .et_pb_text_inner {
    max-width: none !important;
    width: 100% !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    padding-top: 0 !important;
    padding-bottom: 0 !important;
    box-sizing: border-box !important;
}

/* ── Actualités — neutralisation Divi (archives sous-catégories) ─────────── */

body.pyr-actualites-archive #main-content .container,
body.pyr-actualites-archive #main-content #content-area,
body.pyr-actualites-archive #main-content article.et_pb_post,
body.pyr-actualites-archive #main-content .entry-content {
    max-width: none !important;
    padding: 0 !important;
    margin: 0 !important;
    width: 100% !important;
    box-sizing: border-box !important;
}

/* ── Actualités — header ────────────────────────────────────────────────── */

.pyr-act-header {
    background-color: #f3ede2;
    padding: 56px 5% 40px;
    border-bottom: 1px solid rgba(20, 29, 31, 0.08);
}

.pyr-act-header__inner {
    max-width: 1240px;
    margin: 0 auto;
}

.pyr-act-header__title {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 40px;
    font-weight: normal;
    color: #141d1f;
    line-height: 1.2;
    margin: 0 0 10px;
}

.pyr-act-header__title em {
    font-style: italic;
}

.pyr-act-header__desc {
    font-size: 15px;
    color: #6b6559;
    margin: 0 0 32px;
}

/* ── Date dans les cartes d'archive actualités ──────────────────────────── */

.pyr-act-card__meta {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    margin-bottom: 2px;
}

.pyr-act-card__date {
    font-size: 12px;
    color: #6b6559;
}

/* ── Filtres ─────────────────────────────────────────────────────────────── */

.pyr-act-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.pyr-act-filter {
    display: inline-block;
    padding: 7px 16px;
    border-radius: 3px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    text-decoration: none !important;
    border: 1.5px solid rgba(20, 29, 31, 0.22);
    color: #3a3530;
    background: transparent;
    transition: border-color 0.2s, background 0.2s, color 0.2s;
}

.pyr-act-filter:hover,
.pyr-act-filter--active {
    border-color: #b4501f;
    background-color: #b4501f;
    color: #ffffff !important;
}

/* ── Section liste ───────────────────────────────────────────────────────── */

.pyr-act-list {
    background-color: #fbf8f2;
    padding: 64px 5% 72px;
}

.pyr-act-list__inner {
    max-width: 1240px;
    margin: 0 auto;
}

/* ── Grille ──────────────────────────────────────────────────────────────── */

.pyr-act-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 28px;
    margin-bottom: 56px;
}

/* ── Carte ───────────────────────────────────────────────────────────────── */

.pyr-act-card {
    background: #ffffff;
    border-radius: 6px;
    overflow: hidden;
    box-shadow:
        rgba(20, 29, 31, 0.06) 0px 4px 16px,
        rgba(20, 29, 31, 0.04) 0px 1px 4px;
    display: flex;
    flex-direction: column;
    transition: box-shadow 0.3s, transform 0.3s;
}

.pyr-act-card:hover {
    box-shadow:
        rgba(20, 29, 31, 0.11) 0px 12px 32px -4px,
        rgba(20, 29, 31, 0.06) 0px 3px 10px;
    transform: translateY(-2px);
}

.pyr-act-card__thumb {
    display: block;
    aspect-ratio: 16 / 9;
    overflow: hidden;
}

.pyr-act-card__thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.4s cubic-bezier(0.2, 0.7, 0.3, 1);
}

.pyr-act-card:hover .pyr-act-card__thumb img {
    transform: scale(1.04);
}

.pyr-act-card__thumb--empty {
    aspect-ratio: 16 / 9;
    background: linear-gradient(135deg, #3b5054 0%, #8a9a93 60%, #c9bca5 100%);
}

.pyr-act-card__body {
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    flex: 1;
}

.pyr-act-card__meta {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.pyr-act-card__tag {
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: #b4501f;
}

.pyr-act-card__date {
    font-size: 12px;
    color: #6b6559;
}

.pyr-act-card__title {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 18px;
    font-weight: normal;
    line-height: 1.35;
    margin: 0;
    color: #141d1f;
}

.pyr-act-card__title a {
    color: inherit;
    text-decoration: none !important;
    transition: color 0.2s;
}

.pyr-act-card__title a:hover {
    color: #b4501f;
}

.pyr-act-card__excerpt {
    font-size: 14px;
    line-height: 1.65;
    color: #4a4540;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* ── Pagination ──────────────────────────────────────────────────────────── */

.pyr-act-pagination {
    display: flex;
    justify-content: center;
    gap: 6px;
    flex-wrap: wrap;
}

.pyr-act-pagination .page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 14px;
    border-radius: 3px;
    font-size: 14px;
    font-weight: 500;
    text-decoration: none !important;
    border: 1.5px solid rgba(20, 29, 31, 0.18);
    color: #3a3530;
    background: #ffffff;
    transition: border-color 0.2s, background 0.2s, color 0.2s;
}

.pyr-act-pagination .page-numbers:hover,
.pyr-act-pagination .page-numbers.current {
    border-color: #b4501f;
    background: #b4501f;
    color: #ffffff !important;
}

.pyr-act-pagination .page-numbers.dots {
    border-color: transparent;
    background: transparent;
    cursor: default;
}

/* ── Responsive actualités ───────────────────────────────────────────────── */

@media (max-width: 1024px) {
    .pyr-act-grid { grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
}

@media (max-width: 768px) {
    .pyr-act-header { padding: 40px 5% 32px; }
    .pyr-act-header__title { font-size: 28px; }
    .pyr-act-list { padding: 40px 5% 48px; }
    .pyr-act-grid { gap: 20px; }
}

@media (max-width: 480px) {
    .pyr-act-grid { grid-template-columns: 1fr; }
}

/* ── Tranches Gallica — neutralisation Divi ──────────────────────────────── */

body.pyr-tranche #main-content .et_pb_row,
body.pyr-tranche #main-content .et_pb_column,
body.pyr-tranche #main-content .et_pb_post_content,
body.pyr-tranche #main-content .et_pb_text,
body.pyr-tranche #main-content .et_pb_text_inner {
    max-width: none !important;
    width: 100% !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    box-sizing: border-box !important;
}

body.pyr-tranche #main-content .container,
body.pyr-tranche #main-content #content-area,
body.pyr-tranche #main-content article.et_pb_post,
body.pyr-tranche #main-content .entry-content {
    max-width: none !important;
    padding: 0 !important;
    margin: 0 !important;
    width: 100% !important;
    box-sizing: border-box !important;
}

/* ── Grille couvertures Gallica ──────────────────────────────────────────── */

.pyr-gal-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
    gap: 12px;
    margin: 0;
    padding: 40px 5%;
    background: #fbf8f2;
}

.pyr-gal-card {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    text-align: left;
    width: 100%;
    color: inherit;
}

.pyr-gal-card__cover {
    width: 100%;
    aspect-ratio: 34 / 50;
    border-radius: 5px;
    overflow: hidden;
    background: linear-gradient(170deg, #3b5054 0%, #6b7f7a 50%, #c9bca5 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 12px 8px;
    box-shadow:
        rgba(20, 29, 31, 0.25) 0px 6px 16px -4px,
        rgba(20, 29, 31, 0.08) 0px 2px 6px;
    transition: transform 0.35s cubic-bezier(0.2, 0.7, 0.3, 1), box-shadow 0.35s;
    position: relative;
}

.pyr-gal-card:hover .pyr-gal-card__cover {
    transform: translateY(-5px) rotate(-0.5deg);
    box-shadow:
        rgba(20, 29, 31, 0.38) 0px 14px 28px -6px,
        rgba(20, 29, 31, 0.10) 0px 4px 10px;
}

.pyr-gal-card__num {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 20px;
    font-weight: normal;
    color: #ffffff;
    line-height: 1;
    text-shadow: 0 1px 4px rgba(0,0,0,0.4);
}

.pyr-gal-card__year {
    font-size: 11px;
    color: rgba(255,255,255,0.75);
    letter-spacing: 0.06em;
}

.pyr-gal-card__tag {
    position: absolute;
    bottom: 8px;
    right: 8px;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: rgba(255,255,255,0.6);
}

/* Accordéon sommaires */
.pyr-gal-sommaires {
    border-top: 1px solid rgba(20, 29, 31, 0.12);
    margin-top: 16px;
    padding-top: 0;
}

.pyr-gal-sommaires summary {
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: #6b6559;
    cursor: pointer;
    padding: 16px 0;
    list-style: none;
    display: flex;
    align-items: center;
    gap: 8px;
}

.pyr-gal-sommaires summary::before {
    content: "▸";
    color: #b4501f;
    transition: transform 0.2s;
}

.pyr-gal-sommaires[open] summary::before {
    transform: rotate(90deg);
}

.pyr-gal-sommaires__content {
    padding-top: 8px;
}

@media (max-width: 768px) {
    .pyr-gal-grid { grid-template-columns: repeat(auto-fill, minmax(90px, 1fr)); gap: 14px 10px; }
}

/* ── Modal sommaire Gallica ──────────────────────────────────────────────── */

/*
 * Structure rendue dans le DOM :
 * .pyr-gal-modal > .pyr-gal-modal__panel >
 *   button.pyr-gal-modal__close
 *   #pyr-gal-modal-content >
 *     .pyr-gal-modal__header (titre + lien Gallica)
 *     .pyr-gal-modal__body (liste sommaire)
 */

.pyr-gal-modal {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 99999;
    background: rgba(20, 29, 31, 0.65);
    align-items: center;
    justify-content: center;
    padding: 24px;
    backdrop-filter: blur(2px);
}

.pyr-gal-modal.is-open {
    display: flex;
}

.pyr-gal-modal__panel {
    background: #fbf8f2;
    border-radius: 8px;
    max-width: 600px;
    width: 100%;
    max-height: 85vh;
    display: flex;
    flex-direction: column;
    position: relative;
    box-shadow:
        rgba(20, 29, 31, 0.45) 0px 32px 72px -16px,
        rgba(20, 29, 31, 0.12) 0px 8px 24px;
}

.pyr-gal-modal__close {
    position: absolute;
    top: 16px;
    right: 16px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px 6px;
    color: #6b6559;
    font-size: 22px;
    line-height: 1;
    transition: color 0.2s;
    z-index: 1;
}

.pyr-gal-modal__close:hover { color: #141d1f; }

#pyr-gal-modal-content {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    flex: 1;
    min-height: 0;
}

.pyr-gal-modal__header {
    padding: 24px 52px 20px 24px;
    border-bottom: 1px solid rgba(20, 29, 31, 0.10);
    flex-shrink: 0;
}

.pyr-gal-modal__title {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 20px;
    font-weight: normal;
    color: #141d1f;
    margin: 0 0 8px;
    line-height: 1.2;
}

.pyr-gal-modal__ext {
    display: inline-block;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: #b4501f;
    text-decoration: none !important;
    transition: opacity 0.2s;
}

.pyr-gal-modal__ext:hover { opacity: 0.7; }

.pyr-gal-modal__body {
    overflow-y: auto;
    padding: 20px 24px 28px;
    flex: 1;
}

.pyr-gal-som-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.pyr-gal-som-list li {
    font-size: 14px;
    line-height: 1.55;
    color: #3a3530;
    padding: 6px 0 6px 18px;
    position: relative;
    border-bottom: 1px solid rgba(20, 29, 31, 0.07);
}

.pyr-gal-som-list li:last-child { border-bottom: none; }

.pyr-gal-som-list li::before {
    content: "—";
    position: absolute;
    left: 0;
    color: #b4501f;
}

body.pyr-gal-noscroll { overflow: hidden; }

@media (max-width: 480px) {
    .pyr-gal-modal { padding: 0; align-items: flex-end; }
    .pyr-gal-modal__panel {
        max-height: 92vh;
        border-radius: 12px 12px 0 0;
        max-width: 100%;
    }
}

/* ── Archives — neutralisation Divi ──────────────────────────────────────── */

.pyr-arcp-wrap.et_pb_section,
.pyr-arcp-wrap .et_pb_row,
.pyr-arcp-wrap .et_pb_column,
.pyr-arcp-wrap .et_pb_text,
.pyr-arcp-wrap .et_pb_text_inner {
    max-width: none !important;
    width: 100% !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    padding-top: 0 !important;
    padding-bottom: 0 !important;
    box-sizing: border-box !important;
}

/* ── Archives — hero ─────────────────────────────────────────────────────── */

.pyr-arcp-hero {
    background-color: #f3ede2;
    padding: 72px 5%;
    border-bottom: 1px solid rgba(20, 29, 31, 0.08);
}

.pyr-arcp-hero__inner {
    max-width: 1240px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 64px;
    align-items: center;
}

.pyr-arcp-hero__kicker {
    display: block;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: #b4501f;
    margin-bottom: 18px;
}

.pyr-arcp-hero__titre {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 48px;
    font-weight: normal;
    color: #141d1f;
    line-height: 1.1;
    margin: 0 0 20px;
}

.pyr-arcp-hero__desc {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 16px;
    line-height: 1.65;
    color: #3a3530;
    margin: 0;
    max-width: 600px;
}

.pyr-arcp-hero__stats {
    display: flex;
    flex-direction: column;
    gap: 28px;
}

.pyr-arcp-hero__stat {
    text-align: right;
}

.pyr-arcp-hero__stat strong {
    display: block;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 40px;
    font-weight: normal;
    color: #b4501f;
    line-height: 1;
}

.pyr-arcp-hero__stat span {
    font-size: 12px;
    color: #6b6559;
    line-height: 1.4;
}

/* ── Archives — sections ─────────────────────────────────────────────────── */

.pyr-arcp-section {
    padding: 72px 5%;
}

.pyr-arcp-section--beige { background-color: #f3ede2; }
.pyr-arcp-section--white { background-color: #fbf8f2; }

.pyr-arcp-section__inner {
    max-width: 1240px;
    margin: 0 auto;
}

.pyr-arcp-section__head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 40px;
    margin-bottom: 40px;
}

.pyr-arcp-section__headtext h2 {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 32px;
    font-weight: normal;
    color: #141d1f;
    margin: 0 0 10px;
    line-height: 1.2;
}

.pyr-arcp-section__headtext h2 em { font-style: italic; }

.pyr-arcp-section__headtext p {
    font-size: 15px;
    color: #6b6559;
    margin: 0;
    max-width: 560px;
    line-height: 1.6;
}

.pyr-arcp-gallica-btn {
    flex-shrink: 0;
    white-space: nowrap;
}

/* ── Archives — grille de tranches ──────────────────────────────────────── */

.pyr-arcp-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 0;
    border: 1px solid rgba(20, 29, 31, 0.12);
    border-radius: 6px;
    overflow: hidden;
}

.pyr-arcp-card {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 20px 18px 16px;
    text-decoration: none !important;
    color: inherit;
    border-right: 1px solid rgba(20, 29, 31, 0.12);
    border-bottom: 1px solid rgba(20, 29, 31, 0.12);
    background: #ffffff;
    transition: background 0.15s;
}

.pyr-arcp-section--beige .pyr-arcp-card { background: rgba(255, 255, 255, 0.6); }

.pyr-arcp-card:hover { background: #ffffff; }

.pyr-arcp-card:nth-child(5n) { border-right: none; }

.pyr-arcp-card__nums {
    font-size: 13px;
    font-weight: 700;
    color: #141d1f;
    line-height: 1.3;
}

.pyr-arcp-card__annees {
    font-size: 11px;
    color: #6b6559;
    line-height: 1.3;
}

.pyr-arcp-card__label {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 13px;
    font-style: italic;
    color: #3a3530;
    line-height: 1.4;
    margin-top: 6px;
    flex: 1;
}

.pyr-arcp-card__action {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #b4501f;
    margin-top: 10px;
    transition: letter-spacing 0.2s;
}

.pyr-arcp-card:hover .pyr-arcp-card__action {
    letter-spacing: 0.1em;
}

.pyr-arcp-note {
    margin-top: 16px;
    font-size: 12px;
    color: #6b6559;
    font-style: italic;
}

/* ── Archives — responsive ───────────────────────────────────────────────── */

@media (max-width: 1024px) {
    .pyr-arcp-hero__titre { font-size: 38px; }
    .pyr-arcp-grid { grid-template-columns: repeat(4, 1fr); }
    .pyr-arcp-card:nth-child(5n) { border-right: 1px solid rgba(20, 29, 31, 0.12); }
    .pyr-arcp-card:nth-child(4n) { border-right: none; }
}

@media (max-width: 768px) {
    .pyr-arcp-hero { padding: 48px 5%; }
    .pyr-arcp-hero__inner { grid-template-columns: 1fr; gap: 36px; }
    .pyr-arcp-hero__stats { flex-direction: row; justify-content: space-between; }
    .pyr-arcp-hero__stat { text-align: left; }
    .pyr-arcp-hero__titre { font-size: 32px; }
    .pyr-arcp-section { padding: 48px 5%; }
    .pyr-arcp-section__head { flex-direction: column; gap: 20px; }
    .pyr-arcp-grid { grid-template-columns: repeat(3, 1fr); }
    .pyr-arcp-card:nth-child(4n) { border-right: 1px solid rgba(20, 29, 31, 0.12); }
    .pyr-arcp-card:nth-child(3n) { border-right: none; }
}

@media (max-width: 480px) {
    .pyr-arcp-grid { grid-template-columns: repeat(2, 1fr); }
    .pyr-arcp-card:nth-child(3n) { border-right: 1px solid rgba(20, 29, 31, 0.12); }
    .pyr-arcp-card:nth-child(2n) { border-right: none; }
    .pyr-arcp-hero__stats { flex-direction: column; gap: 16px; }
}
