/* ── Archives DUP ──────────────────────────────────────────────────── */

.archives-dup-7e3f1b2c { font-family: inherit; }

/* ── Search bar ───────────────────────────────────────────────────── */

.archives-dup-7e3f1b2c .ad-search-bar { margin-bottom: 10px; }

.archives-dup-7e3f1b2c .ad-search-form {
    display: flex;
    border: 1.5px solid #d8d8d8;
    border-radius: 8px;
    overflow: hidden;
    background: #fff;
}

.archives-dup-7e3f1b2c .ad-search-input {
    flex: 1;
    border: none;
    outline: none;
    padding: 12px 16px;
    font-size: 14px;
    color: #333;
    background: transparent;
    min-width: 0;
    /* Override theme resets */
    display: block;
    width: auto !important;
    box-shadow: none !important;
    border-radius: 0 !important;
}

.archives-dup-7e3f1b2c .ad-search-btn {
    display: inline-flex !important;
    align-items: center;
    gap: 6px;
    border: none;
    background: #c0501a;
    color: #fff;
    padding: 12px 22px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    flex-shrink: 0;
    transition: background 0.2s;
    border-radius: 0 !important;
    box-shadow: none;
}
.archives-dup-7e3f1b2c .ad-search-btn:hover { background: #a03d10; }

/* ── Filters bar ──────────────────────────────────────────────────── */

.archives-dup-7e3f1b2c .ad-filters-bar {
    background: #fff;
    border: 1.5px solid #ebebeb;
    border-radius: 8px;
    padding: 10px 16px;
    margin-bottom: 20px;
}

.archives-dup-7e3f1b2c .ad-filters-form {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    gap: 10px;
    flex-wrap: wrap;
}

.archives-dup-7e3f1b2c .ad-filter-label {
    font-size: 13px;
    color: #666;
    font-weight: 500;
    white-space: nowrap;
    flex-shrink: 0;
}

/* Inline select — override theme width:100% / display:block */
.archives-dup-7e3f1b2c .ad-filter-select {
    display: inline-block !important;
    width: auto !important;
    max-width: 180px;
    flex: 0 0 auto;
    border: 1.5px solid #d0d0d0 !important;
    border-radius: 6px !important;
    padding: 6px 28px 6px 10px !important;
    font-size: 13px;
    color: #333;
    background-color: #fff !important;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23888'%3E%3Cpath d='M7 10l5 5 5-5z'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: right 6px center !important;
    background-size: 16px !important;
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    appearance: none !important;
    cursor: pointer;
    outline: none;
    transition: border-color 0.2s;
    box-shadow: none !important;
    line-height: 1.4;
    height: auto !important;
}
.archives-dup-7e3f1b2c .ad-filter-select:focus { border-color: #c0501a !important; }

.archives-dup-7e3f1b2c .ad-reset-link {
    display: inline-block !important;
    margin-left: auto;
    font-size: 12px;
    color: #c0501a;
    text-decoration: none;
    white-space: nowrap;
    flex-shrink: 0;
}
.archives-dup-7e3f1b2c .ad-reset-link:hover { text-decoration: underline; }

/* ── Stats cards ──────────────────────────────────────────────────── */

.archives-dup-7e3f1b2c .ad-stats-bar {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 14px;
    margin-bottom: 24px;
}

.archives-dup-7e3f1b2c .ad-stat {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: #fff;
    border: 1.5px solid #ebebeb;
    border-top: 3px solid #c0501a;
    border-radius: 10px;
    padding: 20px 12px 16px;
    text-align: center;
    gap: 4px;
    transition: box-shadow 0.2s, transform 0.2s;
}
.archives-dup-7e3f1b2c .ad-stat:hover {
    box-shadow: 0 4px 16px rgba(192, 80, 26, 0.1);
    transform: translateY(-2px);
}

.archives-dup-7e3f1b2c .ad-stat-icon {
    color: #c0501a;   /* override via contrôle Elementor "Couleur des icônes" */
    opacity: 1;       /* override via contrôle Elementor "Opacité des icônes" */
    line-height: 1;
    margin-bottom: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.archives-dup-7e3f1b2c .ad-stat-icon svg,
.archives-dup-7e3f1b2c .ad-stat-icon i {
    display: block;
    width: 24px;
    height: 24px;
    font-size: 24px;
    line-height: 1;
    /* color/fill hérité du parent .ad-stat-icon */
}

/* Icônes dans les lignes de doc — blanc forcé sur fond coloré */
.archives-dup-7e3f1b2c .ad-doc-icon i,
.archives-dup-7e3f1b2c .ad-doc-icon svg {
    display: block;
    width: 20px;
    height: 20px;
    font-size: 20px;
    line-height: 1;
    color: #fff !important;
    fill: #fff !important;
}
.archives-dup-7e3f1b2c .ad-doc-icon svg path {
    fill: #fff !important;
}

.archives-dup-7e3f1b2c .ad-stat-number {
    display: block;
    font-size: 32px;
    font-weight: 800;
    color: #c0501a;
    line-height: 1;
}

.archives-dup-7e3f1b2c .ad-stat-label {
    display: block;
    font-size: 11px;
    color: #999;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    line-height: 1.3;
    margin-top: 2px;
}

/* ── Year groups ──────────────────────────────────────────────────── */

.archives-dup-7e3f1b2c .ad-groups {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.archives-dup-7e3f1b2c .ad-year-group {
    border-radius: 10px;
    overflow: hidden;
    border: 1.5px solid rgba(0, 0, 0, 0.06);
}

.archives-dup-7e3f1b2c .ad-year-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 20px;
    background: #c0501a;
    color: #fff;
    cursor: pointer;
    -webkit-user-select: none;
    user-select: none;
    transition: filter 0.15s;
}
.archives-dup-7e3f1b2c .ad-year-group:nth-child(even) .ad-year-header { background: #6b3010; }
.archives-dup-7e3f1b2c .ad-year-header:hover { filter: brightness(1.1); }

.archives-dup-7e3f1b2c .ad-year-title { font-size: 18px; font-weight: 700; }

.archives-dup-7e3f1b2c .ad-year-badge {
    font-size: 12px;
    background: rgba(255, 255, 255, 0.22);
    border-radius: 20px;
    padding: 3px 10px;
    font-weight: 500;
}

.archives-dup-7e3f1b2c .ad-year-chevron {
    margin-left: auto;
    display: flex;
    align-items: center;
    transition: transform 0.25s;
}
.archives-dup-7e3f1b2c .ad-year-group.is-open .ad-year-chevron { transform: rotate(180deg); }

/* ── Year content ─────────────────────────────────────────────────── */

.archives-dup-7e3f1b2c .ad-year-content { background: #fff; }

/* ── Document row ─────────────────────────────────────────────────── */

.archives-dup-7e3f1b2c .ad-document {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 13px 20px;
    border-bottom: 1px solid #f2edea;
    transition: background 0.15s;
}
.archives-dup-7e3f1b2c .ad-document:last-of-type { border-bottom: none; }
.archives-dup-7e3f1b2c .ad-document:hover { background: #fdf9f6; }
.archives-dup-7e3f1b2c .ad-doc-hidden { display: none !important; }

/* ── Doc icon ─────────────────────────────────────────────────────── */

.archives-dup-7e3f1b2c .ad-doc-icon {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: #fff;
    /* background set via inline style from category color mapping */
}

/* ── Doc body ─────────────────────────────────────────────────────── */

.archives-dup-7e3f1b2c .ad-doc-body { flex: 1; min-width: 0; }

.archives-dup-7e3f1b2c .ad-doc-title {
    font-size: 14px;
    font-weight: 600;
    color: #2a2a2a;
    margin-bottom: 5px;
    line-height: 1.4;
    transition: color 0.15s;
}
.archives-dup-7e3f1b2c .ad-document:hover .ad-doc-title { color: #c0501a; }

.archives-dup-7e3f1b2c .ad-doc-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.archives-dup-7e3f1b2c .ad-doc-date { font-size: 12px; color: #999; }
.archives-dup-7e3f1b2c .ad-doc-size { font-size: 12px; color: #bbb; }

/* ── Type badges ──────────────────────────────────────────────────── */

.archives-dup-7e3f1b2c .ad-badge {
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.5px;
    padding: 3px 7px;
    border-radius: 4px;
    color: #fff;
    white-space: nowrap;
    /* background set via inline style from category color mapping */
}

/* ── Action buttons ───────────────────────────────────────────────── */

.archives-dup-7e3f1b2c .ad-doc-actions {
    display: flex;
    gap: 8px;
    flex-shrink: 0;
    align-items: center;
}

.archives-dup-7e3f1b2c .ad-btn {
    display: inline-flex !important;
    align-items: center;
    font-size: 12px;
    font-weight: 600;
    padding: 6px 14px;
    border-radius: 6px;
    text-decoration: none !important;
    transition: all 0.15s;
    white-space: nowrap;
    line-height: 1;
}

.archives-dup-7e3f1b2c .ad-btn-read {
    color: #c0501a !important;
    border: 1.5px solid #c0501a;
    background: transparent;
}
.archives-dup-7e3f1b2c .ad-btn-read:hover { background: #c0501a; color: #fff !important; }

.archives-dup-7e3f1b2c .ad-btn-pdf {
    background: #c0501a;
    color: #fff !important;
    border: 1.5px solid #c0501a;
}
.archives-dup-7e3f1b2c .ad-btn-pdf:hover { background: #a03d10; border-color: #a03d10; }

/* ── Voir plus ────────────────────────────────────────────────────── */

.archives-dup-7e3f1b2c .ad-more-row {
    padding: 12px 20px;
    background: #fdf8f5;
    border-top: 1px solid #f2edea;
    text-align: center;
}

.archives-dup-7e3f1b2c .ad-more-btn {
    background: none;
    border: none;
    color: #c0501a;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    text-decoration: underline;
    padding: 0;
}
.archives-dup-7e3f1b2c .ad-more-btn:hover { color: #a03d10; }

/* ── Empty state ──────────────────────────────────────────────────── */

.archives-dup-7e3f1b2c .ad-empty {
    text-align: center;
    color: #999;
    padding: 40px;
    background: #f8f8f8;
    border-radius: 10px;
    font-size: 14px;
}

/* ── Responsive ───────────────────────────────────────────────────── */

@media (max-width: 900px) {
    .archives-dup-7e3f1b2c .ad-stats-bar { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 600px) {
    .archives-dup-7e3f1b2c .ad-filter-select { max-width: 140px; }

    /* ── Ligne document : icône + corps sur la même ligne, actions en dessous ── */
    .archives-dup-7e3f1b2c .ad-document {
        flex-wrap: wrap;
        align-items: flex-start;
        padding: 12px 14px;
        gap: 10px;
    }
    /* L'icône garde sa taille fixe */
    .archives-dup-7e3f1b2c .ad-doc-icon {
        flex: 0 0 auto;
    }
    /* Le corps prend TOUT l'espace restant à côté de l'icône */
    .archives-dup-7e3f1b2c .ad-doc-body {
        flex: 1 1 0;        /* base 0 → occupe tout ce qui reste après l'icône */
        min-width: 0;
    }
    /* Boutons en ligne complète sous icône + corps */
    .archives-dup-7e3f1b2c .ad-doc-actions {
        width: 100%;
        padding-left: 50px; /* 40px icône + 10px gap */
        gap: 6px;
    }
    .archives-dup-7e3f1b2c .ad-year-title { font-size: 16px; }
    .archives-dup-7e3f1b2c .ad-doc-title  { font-size: 13px; }
}

@media (max-width: 480px) {
    .archives-dup-7e3f1b2c .ad-stats-bar { grid-template-columns: repeat(2, 1fr); }
    .archives-dup-7e3f1b2c .ad-reset-link { margin-left: 0; width: 100%; }

    /* Sur très petits écrans, boutons pleine largeur côte à côte */
    .archives-dup-7e3f1b2c .ad-doc-actions {
        padding-left: 0;
    }
    .archives-dup-7e3f1b2c .ad-btn {
        flex: 1;
        justify-content: center;
    }
}
