/**
 * Revues juridiques en accès ouvert — Liste
 * UIkit 3 (jl-*) + BEM .rv-card
 */

/* ── Chapeau page (override styles inline hérités de Seblod) ── */
.cck_page_desc h2[style],
.cck_page_desc h2 {
    margin: 40px 0 20px !important;
    font-size: 1.9rem;
    font-weight: 600;
    color: #1d1d1d;
}
.cck_page_desc p[style],
.cck_page_desc p {
    margin: 0 0 24px !important;
    color: #555;
    font-size: 1rem;
    line-height: 1.55;
}
.cck_page_desc hr {
    border: 0;
    border-top: 1px solid #e0e0e0;
    margin: 0 0 30px;
}

/* ── Neutralisation wrappers seb_blog ── */
.cck_page_list .cck-line-blog-middle1 {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 22px;
    width: 100%;
    float: none;
}
.cck_page_list .cck-line-blog-middle1 > [id^="cck1r_middle1-"],
.cck_page_list .cck-w25,
.cck_page_list .cck-w33,
.cck_page_list .cck-w50 {
    width: auto !important;
    float: none !important;
    padding: 0 !important;
}
.cck_page_list .cck-plr,
.cck_page_list .cck-ptb,
.cck_page_list .cck-pad-4,
.cck_page_list .cck-line-body,
.cck_page_list .cck-deepest-blog {
    padding: 0 !important;
    margin: 0 !important;
    border: 0 !important;
    background: transparent !important;
}
.cck_page_list .cck-line-body > .cck-plr,
.cck_page_list [class*="cck-f100"] {
    padding: 0 !important;
}
.cck_page_list .clr {
    display: none;
}

/* ── Visually hidden (accessibilité) ── */
.rv-sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* ── Filtres (variante ud-filters à 1 champ + reset) ── */
.rv-filters.ud-filters .ud-filters__grid {
    grid-template-columns: 1fr auto;
}
@media (max-width: 639px) {
    .rv-filters.ud-filters .ud-filters__grid {
        grid-template-columns: 1fr;
    }
}

.rv-empty {
    grid-column: 1 / -1;
    padding: 40px 20px;
    text-align: center;
    color: #777;
    font-size: .95rem;
    background: #f7f7f7;
    border-radius: 8px;
    display: none;
}
.rv-empty.is-visible {
    display: block;
}

/* ── Carte revue ── */
.rv-card {
    position: relative;
    display: flex;
    flex-direction: column;
    height: 100%;
    background: #fff;
    border: 1px solid #e8e8e8;
    border-radius: 8px;
    overflow: hidden;
    transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.rv-card:hover,
.rv-card:focus-within {
    transform: translateY(-3px);
    box-shadow: 0 8px 22px rgba(0, 0, 0, .10);
    border-color: #d40000;
}

.rv-card__media {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 150px;
    padding: 18px;
    background: #fafafa;
    border-bottom: 1px solid #efefef;
}
.rv-card__media img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    transition: transform .3s ease;
}
.rv-card:hover .rv-card__media img {
    transform: scale(1.04);
}
.rv-card__media--placeholder {
    background: linear-gradient(135deg, #0f7173 0%, #155e75 100%);
    color: #fff;
    font-size: 1.4rem;
    font-weight: 700;
    letter-spacing: .02em;
}

.rv-card__body {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 14px 16px 18px;
    min-height: 96px;
}
.rv-card__title {
    margin: 0;
    font-size: .95rem;
    font-weight: 600;
    line-height: 1.35;
    color: #1d1d1d;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.rv-card__cta {
    margin-top: 10px;
    font-size: .82rem;
    font-weight: 500;
    color: #d40000;
    letter-spacing: .02em;
    text-transform: uppercase;
    opacity: 0;
    transform: translateY(4px);
    transition: opacity .2s ease, transform .2s ease;
}
.rv-card:hover .rv-card__cta,
.rv-card:focus-within .rv-card__cta {
    opacity: 1;
    transform: translateY(0);
}
.rv-card__cta::after {
    content: " →";
}

.rv-card__link {
    position: absolute;
    inset: 0;
    z-index: 2;
    text-indent: -9999em;
    overflow: hidden;
}
.rv-card__link:focus-visible {
    outline: 2px solid #d40000;
    outline-offset: -2px;
}

/* ── Responsive ── */
@media (max-width: 640px) {
    .cck_page_list .cck-line-blog-middle1 {
        grid-template-columns: repeat(2, 1fr);
        gap: 14px;
    }
    .rv-card__media {
        height: 120px;
        padding: 12px;
    }
    .rv-card__body {
        padding: 10px 12px 14px;
    }
    .rv-card__title {
        font-size: .85rem;
    }
    .cck_page_desc h2 {
        font-size: 1.5rem;
    }
}
@media (min-width: 960px) {
    .cck_page_list .cck-line-blog-middle1 {
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    }
}
