/* ============================================================
   DILAC — Feuille de style du site public
   ------------------------------------------------------------
   Design léger, responsive et accessible.
   Aucune dépendance externe (pas de Bootstrap, pas de jQuery).
   ============================================================ */

/* ------------------------------------------------------------
   1. Variables & reset
   ------------------------------------------------------------ */
:root {
    --navy: #0b1f3a;
    --navy-700: #12325c;
    --blue: #1f6feb;
    --blue-dark: #1557b8;
    --blue-soft: #e8f0ff;
    --teal: #0f9d7a;
    --teal-dark: #0a6b54;
    --teal-soft: #e2f7f1;
    --coral: #d6455d;
    --coral-dark: #a92f45;
    --coral-soft: #fdecef;
    --gold: #e9a23b;
    --gold-dark: #8a5a00;
    --gold-soft: #fff4df;
    --purple: #6b4fd8;
    --purple-dark: #4b34a8;
    --purple-soft: #f0ecff;
    --ink: #12233d;
    --muted: #5b6b82;
    --muted-2: #7b8aa0;
    --line: #e3e8ef;
    --bg: #f5f7fb;
    --surface: #ffffff;
    --surface-2: #eef3f9;
    --success: #0a7a55;
    --danger: #b42318;
    --radius-sm: 10px;
    --radius: 18px;
    --radius-lg: 26px;
    --shadow-sm: 0 4px 14px rgba(11, 31, 58, .06);
    --shadow: 0 14px 40px rgba(11, 31, 58, .09);
    --container: 1180px;
    --font-sans: "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
    --font-serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, "Times New Roman", serif;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    font-family: var(--font-sans);
    font-size: 16px;
    line-height: 1.65;
    color: var(--ink);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

body.nav-open {
    overflow: hidden;
}

img,
svg {
    max-width: 100%;
}

img {
    display: block;
    height: auto;
}

a {
    color: var(--blue-dark);
    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
}

a:hover {
    color: var(--blue);
}

button,
input,
select,
textarea {
    font: inherit;
}

button {
    cursor: pointer;
}

h1, h2, h3, h4, p, ul, ol, figure, blockquote {
    margin-top: 0;
}

h1, h2, h3, h4 {
    color: var(--navy);
    line-height: 1.18;
    letter-spacing: -.02em;
}

::selection {
    background: var(--blue);
    color: #fff;
}

:focus-visible {
    outline: 3px solid var(--blue);
    outline-offset: 3px;
}

.container {
    width: min(var(--container), calc(100% - 2rem));
    margin-inline: auto;
}

.site-main {
    display: block;
    min-height: 40vh;
}

.visually-hidden {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

.skip-link {
    position: fixed;
    top: .5rem;
    left: .5rem;
    z-index: 1000;
    transform: translateY(-150%);
    background: var(--navy);
    color: #fff;
    padding: .7rem 1rem;
    border-radius: 8px;
    font-weight: 700;
    text-decoration: none;
    transition: transform .2s ease;
}

.skip-link:focus {
    transform: translateY(0);
    color: #fff;
}

/* ------------------------------------------------------------
   2. Boutons
   ------------------------------------------------------------ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: .55rem;
    min-height: 46px;
    padding: .7rem 1.2rem;
    border: 1px solid transparent;
    border-radius: 999px;
    font-size: .93rem;
    font-weight: 700;
    line-height: 1.2;
    text-decoration: none;
    transition: transform .18s ease, box-shadow .18s ease, background-color .18s ease, border-color .18s ease;
}

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

.btn--primary {
    background: var(--blue);
    color: #fff;
    box-shadow: 0 8px 18px rgba(31, 111, 235, .22);
}

.btn--primary:hover {
    background: var(--blue-dark);
    color: #fff;
    box-shadow: 0 10px 24px rgba(31, 111, 235, .3);
}

.btn--ghost {
    background: #fff;
    color: var(--navy);
    border-color: var(--line);
}

.btn--ghost:hover {
    border-color: #b9c7db;
    color: var(--navy);
    background: #f8fafc;
}

.btn--light {
    background: #fff;
    color: var(--navy);
}

.btn--light:hover {
    background: #eef3f9;
    color: var(--navy);
}

.btn--sm {
    min-height: 38px;
    padding: .5rem .9rem;
    font-size: .82rem;
}

.btn--block {
    width: 100%;
}

/* ------------------------------------------------------------
   3. Barre supérieure
   ------------------------------------------------------------ */
.topbar {
    background: var(--navy);
    color: #dbe6f5;
    font-size: .78rem;
}

.topbar__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    min-height: 38px;
}

.topbar__message {
    display: flex;
    align-items: center;
    gap: .55rem;
    margin: 0;
    min-width: 0;
}

.topbar__dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #43d6a5;
    box-shadow: 0 0 0 4px rgba(67, 214, 165, .14);
    flex: 0 0 auto;
}

.topbar__label {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.topbar__links {
    display: flex;
    align-items: center;
    gap: 1.2rem;
    margin-left: auto;
}

.topbar__links a {
    color: #dbe6f5;
    text-decoration: none;
}

.topbar__links a:hover {
    color: #fff;
    text-decoration: underline;
}

/* ------------------------------------------------------------
   4. En-tête principal
   ------------------------------------------------------------ */
.site-header {
    position: sticky;
    top: 0;
    z-index: 60;
    background: rgba(255, 255, 255, .96);
    border-bottom: 1px solid var(--line);
    backdrop-filter: blur(12px);
    transition: box-shadow .2s ease;
}

.site-header.is-scrolled {
    box-shadow: 0 8px 24px rgba(11, 31, 58, .08);
}

.site-header__inner {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    min-height: 74px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: .7rem;
    text-decoration: none;
    color: var(--navy);
    flex: 0 0 auto;
}

.brand img {
    width: 46px;
    height: 46px;
    border-radius: 12px;
    object-fit: contain;
    background: #fff;
}

.brand__text {
    display: flex;
    flex-direction: column;
    line-height: 1.1;
}

.brand__text strong {
    font-size: 1.2rem;
    letter-spacing: .04em;
    color: var(--navy);
}

.brand__text small {
    margin-top: .2rem;
    font-size: .68rem;
    font-weight: 600;
    letter-spacing: .08em;
    text-transform: uppercase;
    color: var(--muted-2);
}

.site-nav {
    margin-left: auto;
}

.site-nav__list {
    display: flex;
    align-items: center;
    gap: 1.35rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.site-nav__list a {
    display: inline-block;
    padding: .35rem 0;
    color: var(--muted);
    font-size: .92rem;
    font-weight: 650;
    text-decoration: none;
    white-space: nowrap;
    border-bottom: 2px solid transparent;
    transition: color .15s ease, border-color .15s ease;
}

.site-nav__list a:hover,
.site-nav__list a[aria-current="page"] {
    color: var(--blue-dark);
    border-bottom-color: var(--blue);
}

.header-cta {
    flex: 0 0 auto;
}

.nav-toggle {
    display: none;
    width: 44px;
    height: 44px;
    margin-left: auto;
    padding: 0;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #fff;
    color: var(--navy);
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 5px;
}

.nav-toggle span {
    display: block;
    width: 19px;
    height: 2px;
    border-radius: 2px;
    background: currentColor;
    transition: transform .2s ease, opacity .2s ease;
}

body.nav-open .nav-toggle span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

body.nav-open .nav-toggle span:nth-child(2) {
    opacity: 0;
}

body.nav-open .nav-toggle span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* ------------------------------------------------------------
   5. Barre des trois espaces
   ------------------------------------------------------------ */
.spaces-bar {
    background: linear-gradient(180deg, #fff 0%, #f8fafc 100%);
    border-bottom: 1px solid var(--line);
}

.spaces-bar__grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.35rem;
    padding-block: .9rem;
}

.space-link {
    --accent: var(--blue);
    --accent-dark: var(--blue-dark);
    --accent-soft: var(--blue-soft);
    display: flex;
    align-items: center;
    gap: .75rem;
    min-width: 0;
    padding: .7rem .85rem;
    border: 1px solid var(--line);
    border-left: 4px solid var(--accent);
    border-radius: 14px;
    background: #fff;
    color: var(--navy);
    text-decoration: none;
    box-shadow: 0 2px 6px rgba(11, 31, 58, .03);
    transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}

.space-link:hover {
    transform: translateY(-2px);
    border-color: var(--accent);
    color: var(--navy);
    box-shadow: 0 10px 22px rgba(11, 31, 58, .09);
}

.space-link--prof {
    --accent: var(--teal);
    --accent-dark: var(--teal-dark);
    --accent-soft: var(--teal-soft);
}

.space-link--admin {
    --accent: var(--coral);
    --accent-dark: var(--coral-dark);
    --accent-soft: var(--coral-soft);
}

.space-link__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    flex: 0 0 42px;
    border-radius: 12px;
    background: var(--accent-soft);
    color: var(--accent-dark);
}

.space-link__body {
    display: flex;
    flex-direction: column;
    min-width: 0;
    line-height: 1.25;
}

.space-link__body strong {
    font-size: .93rem;
    color: var(--navy);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.space-link__body small {
    margin-top: .18rem;
    font-size: .75rem;
    color: var(--muted);
    white-space: normal;
    overflow: visible;
    text-overflow: clip;
}

.space-link__arrow {
    margin-left: auto;
    color: var(--accent-dark);
    font-size: 1.15rem;
    font-weight: 700;
    transition: transform .18s ease;
}

.space-link:hover .space-link__arrow {
    transform: translateX(3px);
}

/* ------------------------------------------------------------
   6. Emplacements publicitaires
   ------------------------------------------------------------ */
html[data-consent="pending"] .ad-slot {
    display: none;
}

.ad-slot {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: .45rem;
    width: 100%;
    margin: 1.4rem auto;
    padding: .55rem;
    text-align: center;
}

.ad-slot__label {
    font-size: .62rem;
    font-weight: 700;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: var(--muted-2);
}

.ad-slot__placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: .2rem;
    width: 100%;
    min-height: 90px;
    padding: 1rem;
    border: 1px dashed #c8d4e4;
    border-radius: 12px;
    background:
        repeating-linear-gradient(135deg, rgba(31, 111, 235, .035) 0 10px, transparent 10px 20px),
        #fbfcfe;
    color: var(--muted);
}

.ad-slot__placeholder span {
    font-size: .85rem;
    font-weight: 650;
}

.ad-slot__placeholder small {
    font-size: .72rem;
    color: var(--muted-2);
}

.ad-slot--leaderboard .ad-slot__placeholder {
    min-height: 90px;
}

.ad-slot--infeed .ad-slot__placeholder,
.ad-slot--in-article .ad-slot__placeholder {
    min-height: 120px;
}

.ad-slot--sidebar {
    max-width: 300px;
}

.ad-slot--sidebar .ad-slot__placeholder {
    min-height: 250px;
}

.ad-slot--infeed {
    grid-column: 1 / -1;
}

/* ------------------------------------------------------------
   7. Hero
   ------------------------------------------------------------ */
.hero {
    position: relative;
    overflow: hidden;
    padding: clamp(2.8rem, 6vw, 5.2rem) 0 clamp(2.4rem, 5vw, 4.2rem);
    background:
        radial-gradient(circle at 12% 18%, rgba(31, 111, 235, .13), transparent 34%),
        radial-gradient(circle at 88% 8%, rgba(15, 157, 122, .11), transparent 32%),
        linear-gradient(180deg, #f8faff 0%, var(--bg) 100%);
}

.hero::before {
    content: "";
    position: absolute;
    top: -120px;
    right: -120px;
    width: 420px;
    height: 420px;
    border: 1px solid rgba(31, 111, 235, .13);
    border-radius: 50%;
    pointer-events: none;
}

.hero::after {
    content: "";
    position: absolute;
    bottom: -180px;
    left: -100px;
    width: 360px;
    height: 360px;
    border: 1px solid rgba(15, 157, 122, .13);
    border-radius: 50%;
    pointer-events: none;
}

.hero__grid {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: minmax(0, 1.08fr) minmax(0, .92fr);
    align-items: center;
    gap: clamp(2rem, 5vw, 4rem);
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    margin-bottom: 1rem;
    padding: .35rem .75rem;
    border: 1px solid rgba(31, 111, 235, .18);
    border-radius: 999px;
    background: rgba(255, 255, 255, .75);
    color: var(--blue-dark);
    font-size: .76rem;
    font-weight: 700;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.eyebrow::before {
    content: "";
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--blue);
}

.hero h1 {
    max-width: 15ch;
    margin-bottom: 1.1rem;
    font-family: var(--font-serif);
    font-size: clamp(2.4rem, 4.8vw, 4.15rem);
    font-weight: 700;
    line-height: 1.05;
    letter-spacing: -.035em;
    color: var(--navy);
}

.hero__highlight {
    position: relative;
    display: inline;
    z-index: 0;
}

.hero__highlight::after {
    content: "";
    position: absolute;
    left: -.05em;
    right: -.05em;
    bottom: .06em;
    height: .28em;
    z-index: -1;
    border-radius: 4px;
    background: linear-gradient(90deg, rgba(31, 111, 235, .22), rgba(15, 157, 122, .2));
}

.hero__lead {
    max-width: 60ch;
    margin-bottom: 1.6rem;
    color: var(--muted);
    font-size: clamp(1rem, 1.4vw, 1.12rem);
    line-height: 1.75;
}

.hero__actions {
    display: flex;
    flex-wrap: wrap;
    gap: .7rem;
    margin-bottom: 1.7rem;
}

.hero__trust {
    display: flex;
    flex-wrap: wrap;
    gap: .55rem 1.2rem;
    margin: 0;
    padding: 0;
    list-style: none;
    color: var(--muted);
    font-size: .82rem;
}

.hero__trust li {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
}

.hero__trust svg {
    color: var(--teal-dark);
    flex: 0 0 auto;
}

/* Carte visuelle du hero */
.hero__visual {
    position: relative;
    padding: 1rem 0;
}

.study-card {
    position: relative;
    z-index: 2;
    width: min(100%, 430px);
    margin-inline: auto;
    padding: 1.25rem;
    border: 1px solid rgba(255, 255, 255, .8);
    border-radius: 24px;
    background: rgba(255, 255, 255, .92);
    box-shadow: 0 24px 60px rgba(11, 31, 58, .16);
    transform: rotate(-1.5deg);
}

.study-card__header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1.1rem;
}

.study-card__header p {
    margin: 0 0 .15rem;
    color: var(--muted-2);
    font-size: .7rem;
    font-weight: 700;
    letter-spacing: .12em;
    text-transform: uppercase;
}

.study-card__header h2 {
    margin: 0;
    font-size: 1.15rem;
}

.study-card__badge {
    flex: 0 0 auto;
    padding: .3rem .55rem;
    border-radius: 999px;
    background: var(--teal-soft);
    color: var(--teal-dark);
    font-size: .68rem;
    font-weight: 750;
}

.study-card__progress {
    display: grid;
    gap: .7rem;
    margin-bottom: 1.1rem;
}

.progress__row {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: .2rem .5rem;
    align-items: center;
    font-size: .78rem;
    font-weight: 650;
    color: var(--ink);
}

.progress__row span:last-child {
    color: var(--muted);
    font-weight: 700;
}

.progress {
    grid-column: 1 / -1;
    height: 7px;
    overflow: hidden;
    border-radius: 999px;
    background: #e8eef7;
}

.progress__bar {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, var(--blue), #5c9bff);
}

.progress__bar--teal {
    background: linear-gradient(90deg, var(--teal), #47c7a5);
}

.progress__bar--gold {
    background: linear-gradient(90deg, var(--gold), #f4c26f);
}

.study-card__list {
    display: grid;
    gap: .55rem;
    margin: 0;
    padding: .9rem 0 0;
    border-top: 1px solid var(--line);
    list-style: none;
}

.study-card__item {
    display: flex;
    align-items: center;
    gap: .55rem;
    color: var(--muted);
    font-size: .8rem;
}

.study-card__check {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    flex: 0 0 20px;
    border-radius: 50%;
    background: var(--blue-soft);
    color: var(--blue-dark);
    font-size: .7rem;
    font-weight: 800;
}

.study-card__check--done {
    background: var(--teal-soft);
    color: var(--teal-dark);
}

.floating-chip {
    position: absolute;
    z-index: 3;
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    padding: .5rem .7rem;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #fff;
    color: var(--navy);
    box-shadow: var(--shadow-sm);
    font-size: .74rem;
    font-weight: 750;
    white-space: nowrap;
}

.floating-chip--one {
    top: 4%;
    left: -2%;
    transform: rotate(-3deg);
}

.floating-chip--two {
    right: -2%;
    bottom: 8%;
    transform: rotate(2deg);
}

.floating-chip__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border-radius: 8px;
    background: var(--gold-soft);
    color: var(--gold-dark);
    font-size: .8rem;
}

/* ------------------------------------------------------------
   8. Sections & titres
   ------------------------------------------------------------ */
.section {
    padding: clamp(2.6rem, 5vw, 4.4rem) 0;
}

.section--tight {
    padding-top: clamp(1.4rem, 3vw, 2.2rem);
}

.section--surface {
    background: #fff;
    border-block: 1px solid var(--line);
}

.section-head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 1.5rem;
    margin-bottom: 1.6rem;
}

.section-head__text {
    max-width: 65ch;
}

.section-kicker {
    margin-bottom: .35rem;
    color: var(--blue-dark);
    font-size: .72rem;
    font-weight: 800;
    letter-spacing: .12em;
    text-transform: uppercase;
}

.section-title {
    margin-bottom: .45rem;
    font-family: var(--font-serif);
    font-size: clamp(1.75rem, 2.6vw, 2.4rem);
    letter-spacing: -.025em;
}

.section-subtitle {
    margin: 0;
    color: var(--muted);
    font-size: .96rem;
}

.link-arrow {
    display: inline-flex;
    align-items: center;
    gap: .35rem;
    flex: 0 0 auto;
    color: var(--blue-dark);
    font-size: .88rem;
    font-weight: 750;
    text-decoration: none;
    white-space: nowrap;
}

.link-arrow:hover {
    gap: .55rem;
    color: var(--blue);
}

/* ------------------------------------------------------------
   9. Cartes des trois espaces
   ------------------------------------------------------------ */
.spaces-section {
    padding-top: 0;
}

.spaces-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
}

.space-card {
    --accent: var(--blue);
    --accent-dark: var(--blue-dark);
    --accent-soft: var(--blue-soft);
    display: flex;
    flex-direction: column;
    padding: 1.4rem;
    border: 1px solid var(--line);
    border-top: 4px solid var(--accent);
    border-radius: var(--radius);
    background: #fff;
    box-shadow: var(--shadow-sm);
    transition: transform .2s ease, box-shadow .2s ease;
}

.space-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow);
}

.space-card--prof {
    --accent: var(--teal);
    --accent-dark: var(--teal-dark);
    --accent-soft: var(--teal-soft);
}

.space-card--admin {
    --accent: var(--coral);
    --accent-dark: var(--coral-dark);
    --accent-soft: var(--coral-soft);
}

.space-card__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    margin-bottom: .9rem;
    border-radius: 14px;
    background: var(--accent-soft);
    color: var(--accent-dark);
}

.space-card__title {
    margin-bottom: .35rem;
    font-size: 1.15rem;
}

.space-card__desc {
    flex: 1;
    margin-bottom: 1rem;
    color: var(--muted);
    font-size: .9rem;
}

.space-card__link {
    display: inline-flex;
    align-items: center;
    gap: .35rem;
    color: var(--accent-dark);
    font-size: .86rem;
    font-weight: 750;
    text-decoration: none;
}

.space-card__link:hover {
    gap: .55rem;
    color: var(--accent-dark);
}

/* ------------------------------------------------------------
   10. À la une
   ------------------------------------------------------------ */
.featured-card {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr);
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    background: #fff;
    box-shadow: var(--shadow);
}

.featured-card__media {
    position: relative;
    min-height: 300px;
    /* La couverture contient du texte : on la montre en entier plutôt que
       de la recadrer, avec un fond bleu assorti pour les bandes éventuelles. */
    background: linear-gradient(135deg, #081a33 0%, #1f6feb 100%);
}

.featured-card__media img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    position: absolute;
    inset: 0;
}

.featured-card__media::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(11, 31, 58, .05), rgba(11, 31, 58, .2));
    pointer-events: none;
}

.featured-card__label {
    position: absolute;
    top: 1rem;
    left: 1rem;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    gap: .35rem;
    padding: .38rem .7rem;
    border-radius: 999px;
    background: #fff;
    color: var(--navy);
    font-size: .7rem;
    font-weight: 800;
    letter-spacing: .06em;
    text-transform: uppercase;
    box-shadow: var(--shadow-sm);
}

.featured-card__body {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: clamp(1.5rem, 3vw, 2.4rem);
}

.featured-card__title {
    margin-bottom: .75rem;
    font-family: var(--font-serif);
    font-size: clamp(1.55rem, 2.4vw, 2.25rem);
    line-height: 1.14;
}

.featured-card__title a {
    color: var(--navy);
    text-decoration: none;
}

.featured-card__title a:hover {
    color: var(--blue-dark);
}

.featured-card__excerpt {
    margin-bottom: 1.2rem;
    color: var(--muted);
    font-size: .97rem;
}

/* ------------------------------------------------------------
   11. Badges & métadonnées
   ------------------------------------------------------------ */
.badge {
    display: inline-flex;
    align-items: center;
    gap: .3rem;
    padding: .3rem .55rem;
    border-radius: 999px;
    background: var(--blue-soft);
    color: var(--blue-dark);
    font-size: .68rem;
    font-weight: 800;
    letter-spacing: .04em;
    text-transform: uppercase;
    line-height: 1.2;
}

.cat-methodo {
    background: var(--blue-soft);
    color: var(--blue-dark);
}

.cat-math {
    background: var(--teal-soft);
    color: var(--teal-dark);
}

.cat-orientation {
    background: var(--coral-soft);
    color: var(--coral-dark);
}

.cat-langues {
    background: var(--purple-soft);
    color: var(--purple-dark);
}

.cat-info {
    background: #e6f7ef;
    color: #086b48;
}

.cat-vie {
    background: var(--gold-soft);
    color: var(--gold-dark);
}

.cat-default {
    background: var(--blue-soft);
    color: var(--blue-dark);
}

.meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: .45rem .75rem;
    margin: 0;
    padding: 0;
    list-style: none;
    color: var(--muted);
    font-size: .78rem;
}

.meta__item {
    display: inline-flex;
    align-items: center;
    gap: .3rem;
}

.meta__dot {
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background: #b7c2d2;
}

/* ------------------------------------------------------------
   12. Grille de contenu + sidebar
   ------------------------------------------------------------ */
.content-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    align-items: start;
    gap: 2rem;
}

.content-main {
    min-width: 0;
}

.sidebar {
    display: grid;
    gap: 1.1rem;
    min-width: 0;
}

.sidebar__sticky {
    position: sticky;
    top: 92px;
    display: grid;
    gap: 1.1rem;
}

.sidebar-card {
    padding: 1.15rem;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #fff;
    box-shadow: var(--shadow-sm);
}

.sidebar-card__title {
    display: flex;
    align-items: center;
    gap: .45rem;
    margin-bottom: .85rem;
    font-size: .98rem;
    letter-spacing: -.01em;
}

.sidebar-card__title::before {
    content: "";
    width: 4px;
    height: 16px;
    border-radius: 2px;
    background: var(--blue);
}

.sidebar-list {
    display: grid;
    gap: .75rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.sidebar-list__item {
    display: grid;
    grid-template-columns: 64px minmax(0, 1fr);
    gap: .65rem;
    align-items: center;
    padding-bottom: .75rem;
    border-bottom: 1px solid var(--line);
}

.sidebar-list__item:last-child {
    padding-bottom: 0;
    border-bottom: 0;
}

.sidebar-list__thumb {
    width: 64px;
    height: 48px;
    overflow: hidden;
    border-radius: 8px;
    background: var(--surface-2);
}

.sidebar-list__thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.sidebar-list__body {
    min-width: 0;
}

.sidebar-list__title {
    display: -webkit-box;
    overflow: hidden;
    margin: 0 0 .2rem;
    color: var(--navy);
    font-size: .8rem;
    font-weight: 700;
    line-height: 1.35;
    text-decoration: none;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.sidebar-list__title:hover {
    color: var(--blue-dark);
}

.sidebar-list__meta {
    color: var(--muted-2);
    font-size: .68rem;
}

.category-list {
    display: grid;
    gap: .2rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.category-list__item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .5rem;
    padding: .48rem 0;
    border-bottom: 1px dashed #e7ecf3;
    color: var(--muted);
    font-size: .83rem;
    text-decoration: none;
}

.category-list__item:last-child {
    border-bottom: 0;
}

.category-list__item:hover {
    color: var(--blue-dark);
}

.category-list__count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 24px;
    height: 22px;
    padding: 0 .4rem;
    border-radius: 999px;
    background: var(--surface-2);
    color: var(--muted);
    font-size: .68rem;
    font-weight: 750;
}

.cta-card {
    position: relative;
    overflow: hidden;
    padding: 1.35rem;
    border-radius: var(--radius);
    background:
        radial-gradient(circle at 100% 0%, rgba(31, 111, 235, .45), transparent 42%),
        linear-gradient(145deg, var(--navy), var(--navy-700));
    color: #dbe6f5;
    box-shadow: var(--shadow);
}

.cta-card::after {
    content: "";
    position: absolute;
    right: -40px;
    bottom: -55px;
    width: 150px;
    height: 150px;
    border: 1px solid rgba(255, 255, 255, .16);
    border-radius: 50%;
    pointer-events: none;
}

.cta-card__title {
    margin-bottom: .4rem;
    color: #fff;
    font-size: 1.08rem;
}

.cta-card__text {
    margin-bottom: .9rem;
    font-size: .82rem;
    line-height: 1.6;
}

.cta-card__links {
    display: grid;
    gap: .4rem;
    position: relative;
    z-index: 1;
}

.cta-card__links a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .5rem;
    padding: .45rem .6rem;
    border: 1px solid rgba(255, 255, 255, .16);
    border-radius: 8px;
    color: #fff;
    font-size: .78rem;
    font-weight: 650;
    text-decoration: none;
    background: rgba(255, 255, 255, .06);
}

.cta-card__links a:hover {
    background: rgba(255, 255, 255, .14);
    color: #fff;
}

/* ------------------------------------------------------------
   13. Filtres, recherche, grille de cartes
   ------------------------------------------------------------ */
.feed-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1.1rem;
    padding: .75rem;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #fff;
    box-shadow: var(--shadow-sm);
}

.filter-pills {
    display: flex;
    flex-wrap: wrap;
    gap: .35rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.filter-pill {
    display: inline-flex;
    align-items: center;
    gap: .3rem;
    padding: .42rem .7rem;
    border: 1px solid transparent;
    border-radius: 999px;
    color: var(--muted);
    font-size: .78rem;
    font-weight: 650;
    text-decoration: none;
    background: transparent;
    white-space: nowrap;
}

.filter-pill:hover {
    background: var(--surface-2);
    color: var(--navy);
}

.filter-pill.is-active {
    background: var(--navy);
    color: #fff;
    border-color: var(--navy);
}

.filter-pill__count {
    opacity: .7;
    font-size: .68rem;
}

.search-form {
    display: flex;
    align-items: center;
    gap: .35rem;
    flex: 0 0 auto;
}

.search-form__input {
    width: 190px;
    min-height: 38px;
    padding: .45rem .7rem;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: #fbfcfe;
    color: var(--ink);
    font-size: .8rem;
}

.search-form__input:focus {
    border-color: var(--blue);
    background: #fff;
    outline: none;
    box-shadow: 0 0 0 3px rgba(31, 111, 235, .14);
}

.search-form__button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: var(--blue);
    color: #fff;
}

.search-form__button:hover {
    background: var(--blue-dark);
}

.results-note {
    margin-bottom: 1rem;
    color: var(--muted);
    font-size: .85rem;
}

.card-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.15rem;
}

.card {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #fff;
    box-shadow: var(--shadow-sm);
    transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}

.card:hover {
    transform: translateY(-4px);
    border-color: #cfdaea;
    box-shadow: var(--shadow);
}

.card__media {
    position: relative;
    display: block;
    /* Les visuels éditoriaux sont produits en 1200 × 675 (16:9) :
       ce ratio évite de couper les titres et les repères des couvertures. */
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background: var(--surface-2);
}

.card__image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .35s ease;
}

.card:hover .card__image {
    transform: scale(1.025);
}

.card__badge {
    position: absolute;
    top: .7rem;
    left: .7rem;
    z-index: 2;
    box-shadow: 0 2px 8px rgba(11, 31, 58, .12);
}

.card__type {
    position: absolute;
    top: .7rem;
    right: .7rem;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    gap: .25rem;
    padding: .25rem .45rem;
    border-radius: 999px;
    background: rgba(11, 31, 58, .78);
    color: #fff;
    font-size: .62rem;
    font-weight: 700;
    letter-spacing: .03em;
    text-transform: uppercase;
    backdrop-filter: blur(4px);
}

.card__play {
    position: absolute;
    top: 50%;
    left: 50%;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    border: 2px solid rgba(255, 255, 255, .9);
    border-radius: 50%;
    background: rgba(11, 31, 58, .72);
    color: #fff;
    transform: translate(-50%, -50%);
    backdrop-filter: blur(3px);
    transition: transform .2s ease, background .2s ease;
}

.card:hover .card__play {
    transform: translate(-50%, -50%) scale(1.06);
    background: var(--blue);
}

.card__body {
    display: flex;
    flex-direction: column;
    flex: 1;
    padding: 1.1rem 1.15rem 1.15rem;
}

.card__title {
    margin-bottom: .45rem;
    font-size: 1.08rem;
    line-height: 1.32;
    letter-spacing: -.015em;
}

.card__title a {
    color: var(--navy);
    text-decoration: none;
}

.card__title a:hover {
    color: var(--blue-dark);
}

.card__excerpt {
    display: -webkit-box;
    overflow: hidden;
    margin-bottom: .9rem;
    color: var(--muted);
    font-size: .86rem;
    line-height: 1.6;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
}

.card__footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .6rem;
    margin-top: auto;
    padding-top: .75rem;
    border-top: 1px solid var(--line);
}

.card__meta {
    color: var(--muted-2);
    font-size: .7rem;
}

.card__link {
    display: inline-flex;
    align-items: center;
    gap: .25rem;
    color: var(--blue-dark);
    font-size: .78rem;
    font-weight: 750;
    text-decoration: none;
    white-space: nowrap;
}

.card__link:hover {
    gap: .4rem;
    color: var(--blue);
}

.empty-state {
    grid-column: 1 / -1;
    padding: 2.5rem 1.5rem;
    border: 1px dashed #c8d4e4;
    border-radius: var(--radius);
    background: #fff;
    text-align: center;
}

.empty-state h3 {
    margin-bottom: .35rem;
    font-size: 1.2rem;
}

.empty-state p {
    margin-bottom: 1rem;
    color: var(--muted);
}

.pagination {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: .35rem;
    margin-top: 1.6rem;
}

.pagination__link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 38px;
    height: 38px;
    padding: 0 .65rem;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #fff;
    color: var(--muted);
    font-size: .8rem;
    font-weight: 700;
    text-decoration: none;
}

.pagination__link:hover {
    border-color: var(--blue);
    color: var(--blue-dark);
}

.pagination__link.is-active {
    border-color: var(--navy);
    background: var(--navy);
    color: #fff;
}

/* ------------------------------------------------------------
   14. Article — en-tête
   ------------------------------------------------------------ */
.article-hero {
    padding: clamp(1.8rem, 4vw, 3.2rem) 0 1.4rem;
    background:
        radial-gradient(circle at 90% 0%, rgba(31, 111, 235, .08), transparent 32%),
        #fff;
    border-bottom: 1px solid var(--line);
}

.breadcrumb {
    margin-bottom: 1.1rem;
    color: var(--muted-2);
    font-size: .76rem;
}

.breadcrumb__list {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: .35rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.breadcrumb__list a {
    color: var(--muted);
    text-decoration: none;
}

.breadcrumb__list a:hover {
    color: var(--blue-dark);
    text-decoration: underline;
}

.breadcrumb__sep {
    color: #b7c2d2;
}

.article-hero__badges {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: .45rem;
    margin-bottom: .8rem;
}

.article-hero__title {
    max-width: 24ch;
    margin-bottom: .75rem;
    font-family: var(--font-serif);
    font-size: clamp(2.1rem, 4.2vw, 3.55rem);
    line-height: 1.08;
    letter-spacing: -.03em;
}

.article-hero__standfirst {
    max-width: 72ch;
    margin-bottom: 1rem;
    color: var(--muted);
    font-size: clamp(1.02rem, 1.5vw, 1.15rem);
    line-height: 1.7;
}

.article-hero__meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding-top: .9rem;
    border-top: 1px solid var(--line);
}

.article-hero__author {
    display: flex;
    align-items: center;
    gap: .65rem;
}

.author-avatar {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    flex: 0 0 42px;
    border-radius: 50%;
    background: linear-gradient(145deg, var(--navy), var(--blue));
    color: #fff;
    font-size: .8rem;
    font-weight: 800;
    letter-spacing: .02em;
}

.article-hero__author strong {
    display: block;
    color: var(--navy);
    font-size: .84rem;
}

/* Cible uniquement la ligne de métadonnées : l'avatar est aussi un <span>
   et doit conserver son centrage et sa couleur blanche. */
.article-hero__author > div > span {
    display: block;
    color: var(--muted-2);
    font-size: .72rem;
}

.article-actions {
    display: flex;
    align-items: center;
    gap: .4rem;
}

.share {
    display: flex;
    align-items: center;
    gap: .35rem;
}

.share__button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    padding: 0;
    border: 1px solid var(--line);
    border-radius: 50%;
    background: #fff;
    color: var(--muted);
    transition: color .15s ease, border-color .15s ease, background .15s ease;
}

.share__button:hover {
    border-color: var(--blue);
    background: var(--blue-soft);
    color: var(--blue-dark);
}

.share__button svg {
    width: 16px;
    height: 16px;
}

/* ------------------------------------------------------------
   15. Article — média & contenu
   ------------------------------------------------------------ */
.article-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    align-items: start;
    gap: 2rem;
    padding-top: 1.8rem;
}

.article-main {
    min-width: 0;
}

.article-media {
    margin: 0 0 1.6rem;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    background: var(--surface-2);
    box-shadow: var(--shadow-sm);
}

.article-media img {
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 9;
    object-fit: cover;
}

.article-media figcaption {
    padding: .65rem .9rem;
    border-top: 1px solid var(--line);
    background: #fff;
    color: var(--muted-2);
    font-size: .72rem;
}

.video-embed {
    position: relative;
    aspect-ratio: 16 / 9;
    background: #000;
}

.video-embed iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

.prose {
    max-width: 72ch;
    color: #26374f;
    font-size: 1.045rem;
    line-height: 1.85;
}

.prose > p,
.prose > ul,
.prose > ol,
.prose > blockquote,
.prose > .table-wrap,
.prose > .callout,
.prose > .key-points,
.prose > .checklist {
    margin-bottom: 1.2rem;
}

.prose p.lead {
    color: var(--ink);
    font-size: 1.16rem;
    line-height: 1.75;
}

.prose h2 {
    margin-top: 2.6rem;
    margin-bottom: .85rem;
    padding-top: 1.1rem;
    border-top: 1px solid var(--line);
    font-family: var(--font-serif);
    font-size: clamp(1.5rem, 2.5vw, 1.95rem);
    scroll-margin-top: 100px;
}

.prose h2:first-child {
    margin-top: 0;
    padding-top: 0;
    border-top: 0;
}

.prose h3 {
    margin-top: 1.8rem;
    margin-bottom: .55rem;
    font-size: 1.2rem;
    scroll-margin-top: 100px;
}

.prose strong {
    color: var(--navy);
    font-weight: 750;
}

.prose a {
    color: var(--blue-dark);
}

.prose ul,
.prose ol {
    padding-left: 1.35rem;
}

.prose li {
    margin-bottom: .4rem;
}

.prose li::marker {
    color: var(--blue);
    font-weight: 700;
}

.prose blockquote {
    margin-inline: 0;
    padding: 1rem 1.15rem;
    border-left: 4px solid var(--blue);
    border-radius: 0 10px 10px 0;
    background: var(--surface-2);
    color: var(--navy);
    font-family: var(--font-serif);
    font-size: 1.08rem;
    font-style: italic;
}

.prose blockquote p:last-child {
    margin-bottom: 0;
}

.prose .formula {
    padding: .85rem 1rem;
    border: 1px solid #dbe6f5;
    border-radius: 10px;
    background: #f7faff;
    color: var(--navy);
    font-family: "Cambria Math", Cambria, Georgia, serif;
    font-size: 1.12rem;
    text-align: center;
}

.prose code {
    padding: .12em .35em;
    border-radius: 5px;
    background: #eef3f9;
    color: #0b4f9e;
    font-family: Consolas, "SFMono-Regular", Menlo, monospace;
    font-size: .88em;
}

.prose pre {
    overflow-x: auto;
    margin: 0 0 1.2rem;
    padding: 1rem;
    border: 1px solid #1c3a60;
    border-radius: 12px;
    background: #0d2340;
    color: #e7f0fb;
    line-height: 1.6;
    tab-size: 4;
}

.prose pre code {
    padding: 0;
    background: transparent;
    color: inherit;
    font-size: .84rem;
    white-space: pre;
}

.table-wrap {
    overflow-x: auto;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #fff;
}

.prose table {
    width: 100%;
    min-width: 520px;
    border-collapse: collapse;
    font-size: .88rem;
    line-height: 1.55;
}

.prose th,
.prose td {
    padding: .7rem .8rem;
    border-bottom: 1px solid var(--line);
    text-align: left;
    vertical-align: top;
}

.prose th {
    background: var(--surface-2);
    color: var(--navy);
    font-size: .78rem;
    font-weight: 750;
    letter-spacing: .02em;
}

.prose tr:last-child td {
    border-bottom: 0;
}

.prose tbody tr:nth-child(even) td {
    background: #fbfcfe;
}

.callout {
    padding: 1rem 1.1rem;
    border: 1px solid #dbe6f5;
    border-left: 4px solid var(--blue);
    border-radius: 0 12px 12px 0;
    background: #f7faff;
    color: #1d3552;
    font-size: .95rem;
}

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

.callout--warning {
    border-color: #f3d9a6;
    border-left-color: var(--gold);
    background: #fffaf0;
    color: #5c4213;
}

.key-points {
    padding: 1.1rem 1.2rem;
    border: 1px solid #cfe9df;
    border-radius: 14px;
    background: #f2fbf7;
    color: #1b4437;
    font-size: .95rem;
}

.key-points p:last-child,
.key-points ul:last-child {
    margin-bottom: 0;
}

.key-points ul {
    margin-bottom: 0;
}

.key-points li::marker {
    color: var(--teal);
}

.checklist {
    padding: 1rem 1.2rem;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: #fff;
    box-shadow: var(--shadow-sm);
}

.checklist ul {
    margin: 0;
    padding-left: 0;
    list-style: none;
}

.checklist li {
    position: relative;
    padding-left: 1.7rem;
}

.checklist li::before {
    content: "✓";
    position: absolute;
    left: 0;
    top: .05rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 19px;
    height: 19px;
    border-radius: 50%;
    background: var(--teal-soft);
    color: var(--teal-dark);
    font-size: .72rem;
    font-weight: 800;
}

/* ------------------------------------------------------------
   16. Article — sommaire, pied, navigation
   ------------------------------------------------------------ */
.toc {
    position: sticky;
    top: 92px;
}

.toc__list {
    display: grid;
    gap: .15rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.toc__item--h3 {
    padding-left: .8rem;
}

.toc__link {
    display: block;
    padding: .38rem .55rem;
    border-left: 2px solid var(--line);
    color: var(--muted);
    font-size: .78rem;
    line-height: 1.4;
    text-decoration: none;
}

.toc__link:hover,
.toc__link.is-active {
    border-left-color: var(--blue);
    background: var(--blue-soft);
    color: var(--blue-dark);
    font-weight: 700;
}

.toc-mobile {
    display: none;
    margin-bottom: 1.2rem;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #fff;
}

.toc-mobile summary {
    padding: .75rem 1rem;
    color: var(--navy);
    font-size: .86rem;
    font-weight: 750;
    cursor: pointer;
}

.toc-mobile .toc__list {
    padding: 0 1rem 1rem;
}

.article-footer {
    margin-top: 2rem;
    padding-top: 1.4rem;
    border-top: 1px solid var(--line);
}

.author-box {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    padding: 1.1rem;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #fff;
    box-shadow: var(--shadow-sm);
}

.author-box__avatar {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 54px;
    height: 54px;
    flex: 0 0 54px;
    border-radius: 50%;
    background: linear-gradient(145deg, var(--navy), var(--blue));
    color: #fff;
    font-size: 1rem;
    font-weight: 800;
}

.author-box h2 {
    margin-bottom: .25rem;
    font-size: 1rem;
}

.author-box p {
    margin-bottom: .45rem;
    color: var(--muted);
    font-size: .84rem;
    line-height: 1.6;
}

.author-box a {
    font-size: .8rem;
    font-weight: 750;
    text-decoration: none;
}

.article-tags {
    display: flex;
    flex-wrap: wrap;
    gap: .4rem;
    margin-top: 1rem;
}

.article-nav {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: .8rem;
    margin-top: 1.5rem;
}

.article-nav__link {
    display: flex;
    flex-direction: column;
    gap: .2rem;
    padding: .85rem 1rem;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #fff;
    color: var(--navy);
    text-decoration: none;
    box-shadow: var(--shadow-sm);
}

.article-nav__link:hover {
    border-color: var(--blue);
    color: var(--navy);
}

.article-nav__link--next {
    text-align: right;
    align-items: flex-end;
}

.article-nav__label {
    color: var(--muted-2);
    font-size: .68rem;
    font-weight: 750;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.article-nav__title {
    display: -webkit-box;
    overflow: hidden;
    font-size: .82rem;
    font-weight: 700;
    line-height: 1.35;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

.related {
    margin-top: 2.5rem;
}

.related .card-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.related .card__title {
    font-size: .98rem;
}

/* Barre de progression de lecture */
.reading-progress {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 100;
    width: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--blue), var(--teal));
    transition: width .1s linear;
}

/* ------------------------------------------------------------
   17. Pages éditoriales (à propos, légales)
   ------------------------------------------------------------ */
.page-hero {
    padding: clamp(2.4rem, 5vw, 4rem) 0 2rem;
    background:
        radial-gradient(circle at 90% 10%, rgba(31, 111, 235, .1), transparent 35%),
        linear-gradient(180deg, #fff, #f8faff);
    border-bottom: 1px solid var(--line);
}

.page-hero__kicker {
    margin-bottom: .5rem;
    color: var(--blue-dark);
    font-size: .74rem;
    font-weight: 800;
    letter-spacing: .12em;
    text-transform: uppercase;
}

.page-hero__title {
    max-width: 20ch;
    margin-bottom: .65rem;
    font-family: var(--font-serif);
    font-size: clamp(2.1rem, 4vw, 3.2rem);
    letter-spacing: -.03em;
}

.page-hero__lead {
    max-width: 70ch;
    margin: 0;
    color: var(--muted);
    font-size: 1.02rem;
    line-height: 1.75;
}

.legal-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 280px;
    align-items: start;
    gap: 2rem;
    padding-block: 2.4rem 3.5rem;
}

.legal-content {
    min-width: 0;
}

.legal-content .prose {
    max-width: 78ch;
}

.legal-meta {
    position: sticky;
    top: 92px;
    padding: 1.1rem;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #fff;
    box-shadow: var(--shadow-sm);
    font-size: .82rem;
    color: var(--muted);
}

.legal-meta h2 {
    margin-bottom: .5rem;
    font-size: .95rem;
}

.legal-meta p {
    margin-bottom: .55rem;
}

.legal-meta p:last-child {
    margin-bottom: 0;
}

.legal-meta a {
    font-weight: 700;
}

.legal-note {
    margin-bottom: 1.4rem;
    padding: 1rem 1.1rem;
    border: 1px solid #f3d9a6;
    border-radius: 12px;
    background: #fffaf0;
    color: #5c4213;
    font-size: .86rem;
}

.article-tags a.badge {
    text-decoration: none;
}

.about-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
    margin-block: 1.5rem 2rem;
}

.about-card {
    padding: 1.2rem;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #fff;
    box-shadow: var(--shadow-sm);
}

.about-card__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    margin-bottom: .7rem;
    border-radius: 12px;
    background: var(--blue-soft);
    color: var(--blue-dark);
}

.about-card h2,
.about-card h3 {
    margin-bottom: .35rem;
    font-size: 1.02rem;
}

.about-card p {
    margin: 0;
    color: var(--muted);
    font-size: .86rem;
    line-height: 1.6;
}

.values-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: .8rem;
    margin-block: 1rem 2rem;
}

.value-card {
    padding: 1rem 1.1rem;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #fff;
}

.value-card h3 {
    margin-bottom: .3rem;
    font-size: .95rem;
}

.value-card p {
    margin: 0;
    color: var(--muted);
    font-size: .84rem;
}

.charter-list {
    counter-reset: charter;
    margin: 0;
    padding: 0;
    list-style: none;
}

.charter-list li {
    position: relative;
    padding: .8rem 0 .8rem 2.6rem;
    border-bottom: 1px dashed #e7ecf3;
}

.charter-list li:last-child {
    border-bottom: 0;
}

.charter-list li::before {
    counter-increment: charter;
    content: counter(charter);
    position: absolute;
    left: 0;
    top: .8rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--blue-soft);
    color: var(--blue-dark);
    font-size: .76rem;
    font-weight: 800;
}

.charter-list strong {
    display: block;
    margin-bottom: .15rem;
    color: var(--navy);
}

.charter-list span {
    color: var(--muted);
    font-size: .9rem;
}

.team-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: .8rem;
}

.team-card {
    padding: 1rem;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #fff;
}

.team-card h3 {
    margin-bottom: .2rem;
    font-size: .95rem;
}

.team-card p {
    margin: 0;
    color: var(--muted);
    font-size: .84rem;
}

/* ------------------------------------------------------------
   18. Contact
   ------------------------------------------------------------ */
.contact-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(0, .8fr);
    align-items: start;
    gap: 1.5rem;
    padding-block: 2.2rem 1.5rem;
}

.contact-form-card {
    padding: clamp(1.2rem, 2.5vw, 1.8rem);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #fff;
    box-shadow: var(--shadow-sm);
}

.contact-form-card h2 {
    margin-bottom: .35rem;
    font-size: 1.3rem;
}

.contact-form-card > p {
    margin-bottom: 1.2rem;
    color: var(--muted);
    font-size: .88rem;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: .85rem;
}

.form-field {
    display: flex;
    flex-direction: column;
    gap: .3rem;
}

.form-field--full {
    grid-column: 1 / -1;
}

.form-label {
    color: var(--navy);
    font-size: .82rem;
    font-weight: 700;
}

.form-label span {
    color: var(--coral-dark);
}

.form-input,
.form-select,
.form-textarea {
    width: 100%;
    padding: .65rem .75rem;
    border: 1px solid #cfdaea;
    border-radius: 10px;
    background: #fbfcfe;
    color: var(--ink);
    font-size: .88rem;
    transition: border-color .15s ease, box-shadow .15s ease, background .15s ease;
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
    border-color: var(--blue);
    background: #fff;
    outline: none;
    box-shadow: 0 0 0 3px rgba(31, 111, 235, .13);
}

.form-textarea {
    min-height: 150px;
    resize: vertical;
}

.form-hint {
    color: var(--muted-2);
    font-size: .72rem;
}

.form-hint--error {
    color: var(--danger);
    font-weight: 650;
}

.form-check {
    display: flex;
    align-items: flex-start;
    gap: .55rem;
    color: var(--muted);
    font-size: .8rem;
    line-height: 1.55;
}

.form-check input {
    margin-top: .25rem;
    flex: 0 0 auto;
}

.form-status {
    margin-bottom: 1rem;
    padding: .8rem 1rem;
    border-radius: 10px;
    font-size: .86rem;
}

.form-status--success {
    border: 1px solid #bfe6d8;
    background: #f1fbf7;
    color: #0a5b40;
}

.form-status--error {
    border: 1px solid #f2c7c4;
    background: #fff5f5;
    color: #8a1c14;
}

.hp-field {
    position: absolute !important;
    left: -9999px !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
}

.contact-aside {
    display: grid;
    gap: 1rem;
}

.contact-info {
    padding: 1.2rem;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #fff;
    box-shadow: var(--shadow-sm);
}

.contact-info h2 {
    margin-bottom: .8rem;
    font-size: 1.05rem;
}

.contact-info__item {
    display: flex;
    gap: .65rem;
    padding: .55rem 0;
    border-bottom: 1px dashed #e7ecf3;
    font-size: .84rem;
}

.contact-info__item:last-child {
    border-bottom: 0;
}

.contact-info__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    flex: 0 0 32px;
    border-radius: 9px;
    background: var(--blue-soft);
    color: var(--blue-dark);
}

.contact-info__item strong {
    display: block;
    color: var(--navy);
    font-size: .8rem;
}

.contact-info__item span,
.contact-info__item a {
    color: var(--muted);
    font-size: .82rem;
}

.faq {
    padding-block: 1.5rem 3rem;
}

.faq h2 {
    margin-bottom: 1rem;
    font-family: var(--font-serif);
    font-size: clamp(1.6rem, 2.5vw, 2rem);
}

.faq__item {
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #fff;
    margin-bottom: .55rem;
}

.faq__item summary {
    padding: .85rem 1rem;
    color: var(--navy);
    font-size: .9rem;
    font-weight: 700;
    cursor: pointer;
}

.faq__answer {
    padding: 0 1rem .9rem;
    color: var(--muted);
    font-size: .86rem;
    line-height: 1.65;
}

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

/* ------------------------------------------------------------
   19. Pied de page
   ------------------------------------------------------------ */
.site-footer {
    background: var(--navy);
    color: #b9c8db;
    font-size: .84rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.5fr) repeat(3, minmax(0, 1fr));
    gap: 2rem;
    padding-block: 2.8rem 2rem;
}

.footer-brand__link {
    display: inline-flex;
    align-items: center;
    gap: .65rem;
    margin-bottom: .8rem;
    color: #fff;
    text-decoration: none;
}

.footer-brand__logo {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    border-radius: 50%;
    background: #fff;
    padding: 5px;
}

.footer-brand__logo img {
    width: 42px;
    height: 42px;
    object-fit: contain;
}

.footer-brand__link strong {
    display: block;
    color: #fff;
    font-size: 1.15rem;
    letter-spacing: .04em;
}

.footer-brand__link small {
    display: block;
    color: #93a8c2;
    font-size: .68rem;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.footer-brand p {
    max-width: 36ch;
    margin-bottom: .7rem;
    color: #9fb2c9;
    font-size: .82rem;
    line-height: 1.65;
}

.footer-brand__email {
    color: #dbe6f5;
    font-weight: 650;
}

.footer-social {
    display: flex;
    flex-wrap: wrap;
    gap: .8rem;
    margin: .8rem 0 0;
    padding: 0;
    list-style: none;
}

.footer-social a {
    color: #9fb2c9;
    font-size: .78rem;
    text-decoration: none;
}

.footer-social a:hover {
    color: #fff;
    text-decoration: underline;
}

.footer-column h2 {
    margin-bottom: .7rem;
    color: #fff;
    font-size: .86rem;
    letter-spacing: .02em;
}

.footer-column ul {
    display: grid;
    gap: .35rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.footer-column a {
    color: #9fb2c9;
    font-size: .8rem;
    text-decoration: none;
}

.footer-column a:hover {
    color: #fff;
    text-decoration: underline;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, .1);
}

.footer-bottom__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding-block: .9rem;
    color: #8298b3;
    font-size: .72rem;
}

.footer-bottom__inner p {
    margin: 0;
}

.footer-bottom a {
    color: #b9c8db;
}

/* ------------------------------------------------------------
   20. Bandeau cookies
   ------------------------------------------------------------ */
.cookie-banner {
    position: fixed;
    left: 1rem;
    right: 1rem;
    bottom: 1rem;
    z-index: 200;
    max-width: 1080px;
    margin-inline: auto;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #fff;
    box-shadow: 0 20px 60px rgba(11, 31, 58, .22);
    opacity: 0;
    transform: translateY(18px);
    transition: opacity .25s ease, transform .25s ease;
}

.cookie-banner.is-visible {
    opacity: 1;
    transform: translateY(0);
}

.cookie-banner[hidden] {
    display: none !important;
}

.cookie-banner__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.2rem;
    padding: 1rem 1.1rem;
}

.cookie-banner__text h2 {
    margin-bottom: .2rem;
    font-size: .95rem;
}

.cookie-banner__text p {
    margin: 0;
    color: var(--muted);
    font-size: .8rem;
    line-height: 1.55;
}

.cookie-banner__actions {
    display: flex;
    flex-wrap: wrap;
    gap: .5rem;
    flex: 0 0 auto;
}

.cookie-banner__actions .btn {
    min-height: 38px;
    padding: .45rem .8rem;
    font-size: .76rem;
}

/* ------------------------------------------------------------
   21. Responsive
   ------------------------------------------------------------ */
@media (max-width: 1100px) {
    .content-layout,
    .article-layout,
    .legal-layout {
        grid-template-columns: minmax(0, 1fr);
    }

    .sidebar__sticky,
    .toc,
    .legal-meta {
        position: static;
    }

    .toc-mobile {
        display: block;
    }

    .toc-card {
        display: none;
    }

    .sidebar {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .sidebar__sticky {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .related .card-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 960px) {
    .hero__grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .hero__visual {
        order: 2;
        max-width: 520px;
        margin-inline: auto;
    }

    .hero h1 {
        max-width: 18ch;
    }

    .featured-card {
        grid-template-columns: minmax(0, 1fr);
    }

    .featured-card__media {
        min-height: 250px;
    }

    .featured-card__body {
        padding: 1.5rem;
    }

    .footer-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 1100px) {
    .site-header__inner {
        gap: 1rem;
    }

    /* Le nom long de l'académie est masqué pour laisser respirer le menu
       et le bouton « Préparation au concours » sur les écrans intermédiaires. */
    .brand__text small {
        display: none;
    }

    .header-cta {
        padding-inline: 1rem;
        font-size: .88rem;
    }
}

@media (max-width: 940px) {
    /* Évite tout débordement du menu et garde le même rythme que
       la barre des espaces sur les écrans intermédiaires. */
    .site-nav__list,
    .spaces-bar__grid {
        gap: 1rem;
    }
}

@media (max-width: 900px) {
    .topbar__links {
        display: none;
    }

    .site-header__inner {
        min-height: 66px;
    }

    .nav-toggle {
        display: inline-flex;
    }

    .site-nav {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        display: none;
        margin: 0;
        border-top: 1px solid var(--line);
        border-bottom: 1px solid var(--line);
        background: #fff;
        box-shadow: 0 18px 30px rgba(11, 31, 58, .12);
    }

    body.nav-open .site-nav {
        display: block;
    }

    .site-nav__list {
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        padding: .5rem 1rem 1rem;
    }

    .site-nav__list a {
        display: block;
        padding: .8rem .25rem;
        border-bottom: 1px solid var(--line);
    }

    .site-nav__list li:last-child a {
        border-bottom: 0;
    }

    /* Le bouton « Préparation au concours » reste visible à côté du
       menu hamburger sur mobile. */
    .header-cta {
        display: inline-flex;
        min-height: 40px;
        margin-left: 0;
        padding: .5rem .85rem;
        gap: .4rem;
        font-size: .8rem;
        white-space: nowrap;
    }

    .header-cta svg {
        width: 14px;
        height: 14px;
    }

    .spaces-bar__grid {
        gap: .5rem;
    }

    .space-link {
        padding: .6rem;
    }

    .space-link__body small {
        display: none;
    }

    .space-link__icon {
        width: 36px;
        height: 36px;
        flex-basis: 36px;
    }

    .space-link__body strong {
        font-size: .8rem;
    }

    .space-link__arrow {
        font-size: .95rem;
    }

    .feed-toolbar {
        align-items: stretch;
        flex-direction: column;
    }

    .search-form {
        width: 100%;
    }

    .search-form__input {
        width: 100%;
    }

    .contact-layout {
        grid-template-columns: minmax(0, 1fr);
    }
}

@media (max-width: 720px) {
    .container {
        width: min(var(--container), calc(100% - 1.25rem));
    }

    .spaces-bar__grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: .4rem;
        padding-block: .55rem;
    }

    /* Sur mobile, les trois espaces restent visibles d'un coup d'œil
       sans repousser le contenu éditorial sous la ligne de flottaison. */
    .space-link {
        flex-direction: column;
        align-items: flex-start;
        gap: .35rem;
        padding: .55rem;
    }

    .space-link__body small,
    .space-link__arrow {
        display: none;
    }

    .space-link__body strong {
        font-size: .72rem;
        line-height: 1.25;
        white-space: normal;
    }

    .space-link__icon {
        width: 32px;
        height: 32px;
        flex-basis: 32px;
    }

    .hero {
        padding-top: 2.2rem;
    }

    .hero h1 {
        font-size: clamp(2.15rem, 10vw, 2.9rem);
    }

    .hero__actions .btn {
        flex: 1 1 auto;
    }

    .floating-chip--one {
        left: 0;
    }

    .floating-chip--two {
        right: 0;
    }

    .spaces-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .card-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .related .card-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .sidebar,
    .sidebar__sticky {
        grid-template-columns: minmax(0, 1fr);
    }

    .article-hero__meta {
        align-items: flex-start;
        flex-direction: column;
    }

    .article-actions {
        width: 100%;
        justify-content: space-between;
    }

    .article-nav {
        grid-template-columns: minmax(0, 1fr);
    }

    .article-nav__link--next {
        text-align: left;
        align-items: flex-start;
    }

    .about-grid,
    .values-grid,
    .team-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .form-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .footer-grid {
        grid-template-columns: minmax(0, 1fr);
        gap: 1.6rem;
        padding-block: 2.2rem 1.5rem;
    }

    .footer-bottom__inner {
        flex-direction: column;
        align-items: flex-start;
        gap: .35rem;
    }

    .cookie-banner {
        left: .6rem;
        right: .6rem;
        bottom: .6rem;
    }

    .cookie-banner__inner {
        flex-direction: column;
        align-items: stretch;
        gap: .8rem;
    }

    .cookie-banner__actions {
        flex-direction: column;
    }

    .cookie-banner__actions .btn {
        width: 100%;
    }

    .ad-slot--leaderboard .ad-slot__placeholder {
        min-height: 100px;
    }

    .article-hero__title {
        font-size: clamp(1.85rem, 8vw, 2.5rem);
    }

    .prose {
        font-size: 1rem;
        line-height: 1.8;
    }

    .prose p.lead {
        font-size: 1.06rem;
    }

    .prose h2 {
        margin-top: 2.1rem;
    }

    .author-box {
        flex-direction: column;
    }
}

@media (max-width: 520px) {
    .topbar {
        font-size: .7rem;
    }

    .topbar__message {
        gap: .4rem;
    }

    .topbar__extra {
        display: none;
    }

    .brand {
        gap: .5rem;
    }

    .brand__text small {
        display: none;
    }

    .brand img {
        width: 36px;
        height: 36px;
    }

    .brand__text strong {
        font-size: 1rem;
    }

    .header-cta {
        padding: .5rem .65rem;
        font-size: .78rem;
    }

    .header-cta svg {
        display: none;
    }

    .space-link__body small {
        display: none;
    }

    .hero__trust {
        font-size: .76rem;
    }

    .study-card {
        transform: none;
        padding: 1rem;
    }

    .floating-chip {
        font-size: .66rem;
        padding: .4rem .55rem;
    }

    .floating-chip--one {
        top: -2%;
    }

    .floating-chip--two {
        bottom: 0;
    }

    .section-head {
        align-items: flex-start;
        flex-direction: column;
        gap: .6rem;
    }

    .section-head .link-arrow {
        align-self: flex-start;
    }

    .featured-card__media {
        min-height: 200px;
    }

    .featured-card__title {
        font-size: 1.45rem;
    }

    .card__title {
        font-size: 1.02rem;
    }

    .article-hero__title {
        font-size: 1.85rem;
    }

    .share__button {
        width: 34px;
        height: 34px;
    }

    .prose .table-wrap {
        margin-inline: -.25rem;
    }

    /* Sur mobile, les tableaux à deux ou trois colonnes tiennent dans la
       largeur de l'écran. Les tableaux plus larges restent défilables. */
    .prose table {
        min-width: 100%;
        font-size: .75rem;
        line-height: 1.45;
    }

    .prose th,
    .prose td {
        padding: .55rem .45rem;
        overflow-wrap: break-word;
        hyphens: auto;
    }

    .prose table code {
        font-size: .82em;
    }
}

@media (max-width: 360px) {
    /* Très petits écrans : on ne garde que le logo pour laisser la place
       au bouton « Préparation au concours » à côté du menu. */
    .brand__text {
        display: none;
    }

    .header-cta {
        padding: .5rem .55rem;
    }
}

/* ------------------------------------------------------------
   22. Accessibilité & impression
   ------------------------------------------------------------ */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        animation-duration: .01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: .01ms !important;
    }

    .card:hover,
    .space-card:hover,
    .space-link:hover,
    .btn:hover {
        transform: none;
    }
}

@media print {
    .topbar,
    .site-header,
    .spaces-bar,
    .site-footer,
    .sidebar,
    .share,
    .article-actions,
    .article-nav,
    .related,
    .ad-slot,
    .cookie-banner,
    .skip-link,
    .reading-progress,
    .toc-mobile {
        display: none !important;
    }

    body {
        background: #fff;
        color: #000;
        font-size: 11pt;
    }

    .container,
    .article-layout,
    .content-layout {
        display: block;
        width: 100%;
        max-width: none;
    }

    .article-hero,
    .article-media,
    .author-box,
    .callout,
    .key-points,
    .table-wrap {
        border-color: #ccc;
        box-shadow: none;
    }

    .article-hero__title {
        font-size: 24pt;
    }

    .prose {
        max-width: none;
        font-size: 11pt;
    }

    .prose a {
        color: #000;
        text-decoration: underline;
    }

    .qcm-layout {
        display: block;
    }

    .qcm-sidebar,
    .qcm-toolbar__actions,
    .qcm-help {
        display: none !important;
    }

    .qcm-content {
        padding: 0;
        border: 0;
        box-shadow: none;
    }

    .qcm-content .collapseomatic {
        display: none !important;
    }

    .qcm-content .collapseomatic_content {
        display: block !important;
    }
}

/* ------------------------------------------------------------
   22. Offres d'emploi
   ------------------------------------------------------------ */
.sr-only {
    position: absolute !important;
    width: 1px;
    height: 1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.jobs-hero .page-hero__title {
    max-width: 34ch;
}

.jobs-hero .page-hero__lead {
    max-width: 72ch;
}

.jobs-stats {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: .75rem;
    margin: 1.5rem 0 0;
    padding: 0;
    list-style: none;
}

.jobs-stats li {
    padding: .9rem 1rem;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: #fff;
    box-shadow: var(--shadow-sm);
}

.jobs-stats strong {
    display: block;
    margin-bottom: .15rem;
    color: var(--navy);
    font-family: var(--font-serif);
    font-size: 1.35rem;
    letter-spacing: -.02em;
}

.jobs-stats span {
    color: var(--muted);
    font-size: .73rem;
}

.ad-container {
    padding-top: 1rem;
}

.jobs-filter-section {
    padding-top: 1.35rem;
}

.jobs-filter {
    padding: 1rem;
    border: 1px solid var(--line);
    border-radius: 18px;
    background: #fff;
    box-shadow: var(--shadow-sm);
}

.jobs-filter__search {
    display: flex;
    gap: .55rem;
    margin-bottom: .8rem;
}

.jobs-filter__search input {
    flex: 1 1 auto;
    min-width: 0;
    padding: .72rem .9rem;
    border: 1px solid #cfdaea;
    border-radius: 10px;
    background: #fbfcfe;
    color: var(--ink);
    font-size: .88rem;
}

.jobs-filter__search input:focus {
    border-color: var(--blue);
    background: #fff;
    outline: none;
    box-shadow: 0 0 0 3px rgba(31, 111, 235, .13);
}

.jobs-filter__grid {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: .7rem;
    align-items: end;
}

.jobs-filter .form-field label {
    margin-bottom: .25rem;
    color: var(--muted);
    font-size: .68rem;
    font-weight: 800;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.jobs-filter .form-field select {
    width: 100%;
    min-height: 42px;
    padding: .55rem .65rem;
    border: 1px solid #cfdaea;
    border-radius: 9px;
    background: #fbfcfe;
    color: var(--ink);
    font-size: .78rem;
}

.jobs-filter .form-field select:focus {
    border-color: var(--blue);
    background: #fff;
    outline: none;
    box-shadow: 0 0 0 3px rgba(31, 111, 235, .13);
}

.form-field--check {
    justify-content: flex-end;
    min-height: 42px;
}

.checkbox {
    display: flex;
    align-items: center;
    gap: .45rem;
    color: var(--muted);
    font-size: .75rem;
    line-height: 1.3;
    cursor: pointer;
}

.checkbox input {
    width: 16px;
    height: 16px;
    accent-color: var(--blue);
}

.form-field--action .btn {
    min-height: 42px;
    padding-inline: .75rem;
    font-size: .76rem;
}

.jobs-filter__reset {
    margin: .7rem 0 0;
    font-size: .78rem;
}

.jobs-domain-pills {
    margin-top: .9rem;
}

.jobs-source-pills {
    margin-top: .45rem;
}

.jobs-results-head {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    justify-content: space-between;
    gap: .5rem 1rem;
    margin-bottom: 1rem;
    color: var(--muted);
    font-size: .8rem;
}

.jobs-results-head p {
    margin: 0;
}

.jobs-results-head strong {
    color: var(--navy);
}

.jobs-results-head__filters {
    color: var(--muted-2);
}

.jobs-results-head__source {
    color: var(--muted-2);
    font-size: .72rem;
}

.job-list {
    display: grid;
    gap: .95rem;
}

.job-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: .95rem;
}

.job-card {
    display: flex;
    flex-direction: column;
    min-width: 0;
    padding: 1.1rem;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: #fff;
    box-shadow: var(--shadow-sm);
}

.job-card__head {
    display: flex;
    align-items: flex-start;
    gap: .8rem;
    min-width: 0;
}

.job-card__logo {
    display: grid;
    flex: 0 0 46px;
    place-items: center;
    width: 46px;
    height: 46px;
    border-radius: 12px;
    background: linear-gradient(145deg, var(--blue-soft), #fff);
    color: var(--blue-dark);
    font-size: .86rem;
    font-weight: 850;
    letter-spacing: .02em;
    box-shadow: inset 0 0 0 1px rgba(31, 111, 235, .08);
}

.job-card__identity {
    min-width: 0;
}

.job-card__badges {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: .35rem;
    margin-bottom: .35rem;
}

.job-domain {
    border: 0;
    font-size: .64rem;
    font-weight: 800;
    letter-spacing: .02em;
}

.job-domain--dev {
    background: var(--blue-soft);
    color: var(--blue-dark);
}

.job-domain--network {
    background: var(--teal-soft);
    color: var(--teal-dark);
}

.job-domain--data {
    background: var(--purple-soft);
    color: var(--purple-dark);
}

.job-domain--cyber {
    background: var(--coral-soft);
    color: var(--coral-dark);
}

.job-domain--cloud {
    background: #e8f7ff;
    color: #0b6385;
}

.job-domain--project {
    background: var(--gold-soft);
    color: var(--gold-dark);
}

.job-domain--teaching {
    background: #f3f0e8;
    color: #6d5a2e;
}

.job-domain--default {
    background: var(--surface-2);
    color: var(--muted);
}

.job-card__new {
    display: inline-flex;
    align-items: center;
    padding: .14rem .42rem;
    border-radius: 999px;
    background: var(--teal-soft);
    color: var(--teal-dark);
    font-size: .6rem;
    font-weight: 800;
    letter-spacing: .04em;
    text-transform: uppercase;
}

.job-card__title {
    margin: 0 0 .25rem;
    font-size: 1rem;
    line-height: 1.35;
}

.job-card__title a {
    color: var(--navy);
    text-decoration: none;
}

.job-card__title a:hover {
    color: var(--blue-dark);
    text-decoration: underline;
    text-underline-offset: 3px;
}

.job-card__company {
    display: flex;
    flex-wrap: wrap;
    gap: .25rem;
    margin: 0;
    color: var(--muted);
    font-size: .76rem;
}

.job-card__excerpt {
    margin: .7rem 0 .55rem;
    color: var(--muted);
    font-size: .81rem;
    line-height: 1.55;
}

.job-card__skills {
    display: flex;
    flex-wrap: wrap;
    gap: .28rem;
    margin: 0 0 .7rem;
    padding: 0;
    list-style: none;
}

.job-card__skills li {
    padding: .2rem .48rem;
    border-radius: 999px;
    background: var(--surface-2);
    color: var(--muted);
    font-size: .65rem;
    line-height: 1.35;
}

.job-card__meta {
    display: grid;
    gap: .28rem;
    margin: 0 0 .8rem;
    padding: 0;
    list-style: none;
    color: var(--muted);
    font-size: .72rem;
    line-height: 1.4;
}

.job-card__meta li {
    display: flex;
    gap: .35rem;
    min-width: 0;
}

.job-card__meta span {
    flex: 0 0 62px;
    color: var(--muted-2);
    font-size: .6rem;
    font-weight: 800;
    letter-spacing: .04em;
    text-transform: uppercase;
    line-height: 1.6;
}

.job-card__footer {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: .35rem .6rem;
    margin-top: auto;
    padding-top: .7rem;
    border-top: 1px solid var(--line);
    color: var(--muted-2);
    font-size: .67rem;
}

.job-card__date {
    white-space: nowrap;
}

.job-card__source {
    white-space: nowrap;
}

.job-card__link {
    margin-left: auto;
    color: var(--blue-dark);
    font-weight: 800;
    text-decoration: none;
    white-space: nowrap;
}

.job-card__link:hover {
    color: var(--blue);
}

.job-card--compact {
    padding: .8rem;
}

.job-card--compact .job-card__logo {
    flex-basis: 36px;
    width: 36px;
    height: 36px;
    border-radius: 9px;
    font-size: .7rem;
}

.job-card--compact .job-card__title {
    font-size: .8rem;
    line-height: 1.35;
}

.job-card--compact .job-card__company {
    font-size: .68rem;
}

.job-card--compact .job-card__excerpt,
.job-card--compact .job-card__skills,
.job-card--compact .job-card__meta,
.job-card--compact .job-card__date,
.job-card--compact .job-card__source {
    display: none;
}

.job-card--compact .job-card__footer {
    padding-top: .55rem;
}

.job-card--compact .job-card__link {
    font-size: .7rem;
}

.jobs-sidebar__text {
    margin: 0 0 .7rem;
    color: var(--muted);
    font-size: .78rem;
    line-height: 1.55;
}

.jobs-sidebar__text:last-child {
    margin-bottom: 0;
}

.jobs-advice-list {
    margin: 0 0 .8rem;
    padding-left: 1.1rem;
    color: var(--muted);
    font-size: .78rem;
    line-height: 1.55;
}

.jobs-advice-list li + li {
    margin-top: .4rem;
}

.job-hero {
    padding: clamp(2.2rem, 4vw, 3.4rem) 0 2.2rem;
    background:
        radial-gradient(circle at 92% 8%, rgba(31, 111, 235, .1), transparent 34%),
        linear-gradient(180deg, #fff, #f8faff);
    border-bottom: 1px solid var(--line);
}

.job-hero__grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 300px;
    align-items: start;
    gap: 2rem;
}

.job-hero__content {
    min-width: 0;
}

.job-hero__badges {
    display: flex;
    flex-wrap: wrap;
    gap: .4rem;
    margin-bottom: .7rem;
}

.badge--soft {
    background: var(--teal-soft);
    color: var(--teal-dark);
}

.job-hero__title {
    max-width: 28ch;
    margin-bottom: .6rem;
    font-family: var(--font-serif);
    font-size: clamp(1.9rem, 3.2vw, 2.8rem);
    letter-spacing: -.03em;
}

.job-hero__company {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: .35rem;
    margin-bottom: 1rem;
    color: var(--muted);
    font-size: .9rem;
}

.job-hero__company strong {
    color: var(--navy);
}

.job-hero__meta {
    display: flex;
    flex-wrap: wrap;
    gap: .4rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.job-hero__meta li {
    padding: .38rem .62rem;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: #fff;
    color: var(--muted);
    font-size: .7rem;
}

.job-hero__meta span {
    margin-right: .2rem;
    color: var(--muted-2);
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .04em;
    font-size: .6rem;
}

.job-hero__apply {
    padding: 1.1rem;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: #fff;
    box-shadow: var(--shadow-sm);
}

.job-hero__apply p {
    margin: .65rem 0 0;
    color: var(--muted);
    font-size: .72rem;
    line-height: 1.5;
}

.job-hero__apply-unavailable {
    margin-top: 0 !important;
}

.job-hero__all {
    display: inline-block;
    margin-top: .75rem;
    color: var(--muted);
    font-size: .76rem;
    font-weight: 700;
    text-decoration: none;
}

.job-hero__all:hover {
    color: var(--blue-dark);
}

.job-detail {
    min-width: 0;
}

.job-facts {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: .6rem;
    margin: 0 0 1.4rem;
    padding: 0;
    list-style: none;
}

.job-facts li {
    padding: .7rem .8rem;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: #fff;
    box-shadow: var(--shadow-sm);
}

.job-facts__label {
    display: block;
    margin-bottom: .18rem;
    color: var(--muted-2);
    font-size: .6rem;
    font-weight: 800;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.job-facts strong {
    display: block;
    overflow: hidden;
    color: var(--navy);
    font-size: .78rem;
    line-height: 1.4;
    text-overflow: ellipsis;
}

.job-prose {
    max-width: 76ch;
}

.job-source-inline {
    padding: .75rem .9rem;
    border-left: 3px solid var(--blue);
    border-radius: 0 10px 10px 0;
    background: var(--blue-soft);
    color: var(--muted);
    font-size: .8rem;
    line-height: 1.55;
}

.job-skills {
    display: flex;
    flex-wrap: wrap;
    gap: .35rem;
    margin: 0 0 1rem;
    padding: 0;
    list-style: none;
}

.job-skills li {
    padding: .3rem .58rem;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: #fff;
    color: var(--navy);
    font-size: .72rem;
    font-weight: 650;
}

.job-steps li,
.job-questions li {
    margin-bottom: .45rem;
}

.job-detail__footer {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-top: 1.6rem;
    padding: 1.1rem;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: #fff;
    box-shadow: var(--shadow-sm);
}

.job-detail__footer p {
    margin: .2rem 0 0;
    color: var(--muted);
    font-size: .78rem;
}

.job-summary {
    display: grid;
    gap: .55rem;
    margin: 0 0 .9rem;
}

.job-summary > div {
    display: flex;
    justify-content: space-between;
    gap: .8rem;
    padding-bottom: .5rem;
    border-bottom: 1px solid var(--line);
    font-size: .76rem;
}

.job-summary > div:last-child {
    padding-bottom: 0;
    border-bottom: 0;
}

.job-summary dt {
    color: var(--muted-2);
    font-weight: 700;
}

.job-summary dd {
    margin: 0;
    color: var(--navy);
    text-align: right;
}

.job-sidebar__apply {
    margin-top: .2rem;
}

.job-sidebar__similar {
    display: grid;
    gap: .6rem;
}

.notice {
    margin: 1.2rem 0;
    padding: .9rem 1rem;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--surface-2);
    color: var(--muted);
    font-size: .82rem;
    line-height: 1.55;
}

.notice strong {
    display: block;
    margin-bottom: .25rem;
    color: var(--navy);
}

.notice p {
    margin: 0;
}

.notice--info {
    border-color: #cfe0ff;
    background: var(--blue-soft);
}

.notice--warning {
    border-color: #f3d59b;
    background: var(--gold-soft);
}

.jobs-home {
    background:
        radial-gradient(circle at 8% 20%, rgba(15, 157, 122, .08), transparent 30%),
        linear-gradient(180deg, #fff, #f7fbfa);
    border-block: 1px solid var(--line);
}

.jobs-home__note {
    margin: 1rem 0 0;
    color: var(--muted-2);
    font-size: .72rem;
    line-height: 1.5;
}

.jobs-home__note a {
    color: var(--muted);
}

@media (max-width: 1100px) {
    .jobs-filter__grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .job-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .job-hero__grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .job-hero__apply {
        max-width: 420px;
    }

    .jobs-stats {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .job-facts {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 760px) {
    .jobs-filter__search {
        flex-direction: column;
    }

    .jobs-filter__grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .form-field--action {
        grid-column: 1 / -1;
    }

    .job-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .job-hero__title {
        max-width: none;
    }

    .job-facts {
        grid-template-columns: minmax(0, 1fr);
    }

    .job-detail__footer {
        align-items: flex-start;
    }

    .job-card__footer {
        align-items: flex-start;
    }

    .job-card__link {
        margin-left: 0;
    }
}

@media (max-width: 480px) {
    .jobs-stats {
        grid-template-columns: minmax(0, 1fr);
    }

    .jobs-filter__grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .jobs-hero .page-hero__title {
        font-size: 1.8rem;
    }
}

/* ------------------------------------------------------------
   Carrousel des offres d'emploi (accueil)
   ------------------------------------------------------------ */
.jobs-carousel {
    --jobs-carousel-gap: 1rem;
    position: relative;
    min-width: 0;
}

.jobs-carousel__viewport {
    overflow-x: auto;
    overflow-y: hidden;
    scroll-behavior: smooth;
    scroll-snap-type: x mandatory;
    overscroll-behavior-x: contain;
    scrollbar-width: none;
    -ms-overflow-style: none;
    padding: .25rem 0 .75rem;
}

.jobs-carousel__viewport::-webkit-scrollbar {
    display: none;
}

.jobs-carousel__viewport:focus-visible {
    outline: 3px solid rgba(37, 99, 235, .45);
    outline-offset: 4px;
    border-radius: 18px;
}

.jobs-carousel__track {
    display: flex;
    align-items: stretch;
    gap: var(--jobs-carousel-gap);
}

.jobs-carousel__item {
    display: flex;
    flex: 0 0 calc((100% - (2 * var(--jobs-carousel-gap))) / 3);
    min-width: 0;
    scroll-snap-align: start;
}

.jobs-carousel__item > .job-card {
    width: 100%;
    height: 100%;
}

.jobs-carousel__bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-top: .35rem;
}

.jobs-carousel__status {
    margin: 0;
    color: var(--muted-2);
    font-size: .76rem;
    font-weight: 700;
    letter-spacing: .02em;
}

.jobs-carousel__controls {
    display: flex;
    align-items: center;
    gap: .55rem;
}

.jobs-carousel__arrow {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    padding: 0;
    border: 1px solid var(--line);
    border-radius: 50%;
    background: #fff;
    color: var(--navy);
    font-size: 1.05rem;
    line-height: 1;
    cursor: pointer;
    transition: border-color .2s ease, color .2s ease, transform .2s ease;
}

.jobs-carousel__arrow:hover {
    border-color: var(--blue);
    color: var(--blue-dark);
    transform: translateY(-1px);
}

.jobs-carousel__arrow:focus-visible {
    outline: 3px solid rgba(37, 99, 235, .35);
    outline-offset: 2px;
}

.jobs-carousel__dots {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: .35rem;
    min-height: 38px;
}

.jobs-carousel__dot {
    width: 8px;
    height: 8px;
    padding: 0;
    border: 0;
    border-radius: 999px;
    background: #c8d2df;
    cursor: pointer;
    transition: width .2s ease, background .2s ease;
}

.jobs-carousel__dot[aria-current="true"] {
    width: 24px;
    background: var(--blue);
}

.jobs-carousel__dot:focus-visible {
    outline: 3px solid rgba(37, 99, 235, .35);
    outline-offset: 3px;
}

.jobs-carousel:not([data-carousel-ready="true"]) .jobs-carousel__bar {
    display: none;
}

@media (max-width: 900px) {
    .jobs-carousel__item {
        flex-basis: calc((100% - var(--jobs-carousel-gap)) / 2);
    }
}

@media (max-width: 600px) {
    .jobs-carousel__item {
        flex-basis: 100%;
    }

    .jobs-carousel__bar {
        align-items: flex-start;
        flex-direction: column;
        gap: .5rem;
    }

    .jobs-carousel__controls {
        justify-content: space-between;
        width: 100%;
    }
}

@media (prefers-reduced-motion: reduce) {
    .jobs-carousel__viewport {
        scroll-behavior: auto;
    }

    .jobs-carousel__arrow {
        transition: none;
    }
}

/* ------------------------------------------------------------
   QCM — Préparation au concours
   ------------------------------------------------------------ */
.qcm-hero {
    padding: clamp(2.2rem, 4.5vw, 3.6rem) 0;
    background:
        radial-gradient(circle at 12% 20%, rgba(31, 111, 235, .12), transparent 34%),
        radial-gradient(circle at 88% 10%, rgba(15, 157, 122, .10), transparent 30%),
        linear-gradient(180deg, #f8faff 0%, var(--bg) 100%);
    border-bottom: 1px solid var(--line);
}

.qcm-hero__inner {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(0, .65fr);
    gap: 2rem;
    align-items: center;
}

.qcm-hero h1 {
    margin-bottom: .65rem;
    font-family: var(--font-serif);
    font-size: clamp(2rem, 4vw, 3.1rem);
    letter-spacing: -.03em;
}

.qcm-hero__lead {
    max-width: 68ch;
    margin-bottom: 0;
    color: var(--muted);
    font-size: 1.02rem;
}

.qcm-hero__points {
    display: grid;
    gap: .6rem;
    margin: 0;
    padding: 1.1rem 1.2rem;
    list-style: none;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: rgba(255, 255, 255, .82);
    box-shadow: var(--shadow-sm);
}

.qcm-hero__points li {
    display: flex;
    align-items: center;
    gap: .55rem;
    color: var(--navy);
    font-size: .88rem;
    font-weight: 650;
}

.qcm-hero__points li::before {
    content: "✓";
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    flex: 0 0 20px;
    border-radius: 999px;
    background: var(--teal-soft);
    color: var(--teal-dark);
    font-size: .72rem;
    font-weight: 800;
}

.qcm-section {
    padding-top: clamp(1.6rem, 3vw, 2.6rem);
}

.qcm-layout {
    display: grid;
    grid-template-columns: 290px minmax(0, 1fr);
    gap: 1.5rem;
    align-items: start;
}

.qcm-sidebar {
    position: sticky;
    top: 92px;
    padding: 1rem;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--surface);
    box-shadow: var(--shadow-sm);
}

.qcm-sidebar__head {
    margin-bottom: .8rem;
}

.qcm-sidebar__head .section-kicker {
    margin-bottom: .2rem;
}

.qcm-sidebar__head h2 {
    margin-bottom: 0;
    font-size: 1.15rem;
}

.qcm-cats {
    display: grid;
    gap: .3rem;
    max-height: min(64vh, 640px);
    overflow: auto;
    padding-right: .25rem;
    scrollbar-width: thin;
}

.qcm-cat {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: .5rem;
    padding: .5rem .6rem;
    border: 1px solid transparent;
    border-radius: 11px;
    color: var(--ink);
    text-decoration: none;
    transition: background-color .15s ease, border-color .15s ease, transform .15s ease;
}

.qcm-cat:hover {
    background: var(--surface-2);
    color: var(--navy);
    transform: translateX(2px);
}

.qcm-cat.is-active {
    border-color: rgba(31, 111, 235, .35);
    background: var(--blue-soft);
}

.qcm-cat__label {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: .85rem;
    font-weight: 600;
    color: var(--navy);
}

.qcm-cat__count {
    flex: 0 0 auto;
    min-width: 24px;
    padding: .1rem .4rem;
    border-radius: 999px;
    background: var(--surface-2);
    color: var(--muted);
    font-size: .68rem;
    font-weight: 700;
    text-align: center;
}

.qcm-cat.is-active .qcm-cat__count {
    background: var(--blue);
    color: #fff;
}

.qcm-items {
    display: flex;
    flex-wrap: wrap;
    gap: .45rem;
}

.qcm-item {
    display: inline-flex;
    align-items: center;
    padding: .4rem .75rem;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--surface);
    color: var(--navy);
    font-size: .78rem;
    font-weight: 650;
    text-decoration: none;
    white-space: nowrap;
    transition: background-color .15s ease, border-color .15s ease, color .15s ease;
}

.qcm-item:hover {
    border-color: var(--blue);
    color: var(--blue-dark);
}

.qcm-item.is-active {
    border-color: var(--blue);
    background: var(--blue);
    color: #fff;
}

.qcm-main {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    min-width: 0;
}

.qcm-toolbar {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 1.25rem;
    padding: 1.1rem 1.2rem;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--surface);
    box-shadow: var(--shadow-sm);
}

.qcm-toolbar__text {
    min-width: 0;
}

.qcm-toolbar__text .section-kicker {
    margin-bottom: .25rem;
}

.qcm-toolbar__text h2 {
    margin-bottom: .3rem;
    font-family: var(--font-serif);
    font-size: clamp(1.35rem, 2.4vw, 1.8rem);
}

.qcm-toolbar__text p:last-child {
    margin-bottom: 0;
    color: var(--muted);
    font-size: .9rem;
}

.qcm-toolbar__actions {
    display: flex;
    flex-wrap: wrap;
    gap: .5rem;
    flex: 0 0 auto;
}

.qcm-content {
    padding: clamp(1rem, 2.2vw, 1.65rem);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--surface);
    box-shadow: var(--shadow-sm);
    overflow-wrap: break-word;
}

.qcm-content > :first-child {
    margin-top: 0;
}

.qcm-content > :last-child {
    margin-bottom: 0;
}

.qcm-content p {
    margin-bottom: .7rem;
    line-height: 1.72;
}

.qcm-content h2,
.qcm-content h3,
.qcm-content h4 {
    color: var(--navy);
    line-height: 1.35;
}

.qcm-content h3.qcm-question,
.qcm-content h3 {
    margin: 1.5rem 0 .65rem;
    padding-top: 1.15rem;
    border-top: 1px solid var(--line);
    font-family: var(--font-sans);
    font-size: 1.02rem;
    font-weight: 750;
}

.qcm-content h3.qcm-question:first-of-type {
    margin-top: 0;
    padding-top: 0;
    border-top: 0;
}

.qcm-content h4 {
    margin: 1.1rem 0 .5rem;
    font-size: .95rem;
}

.qcm-content strong,
.qcm-content b {
    color: var(--navy);
}

.qcm-content .label {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 26px;
    height: 26px;
    margin-right: .45rem;
    border-radius: 7px;
    background: var(--blue-soft);
    color: var(--blue-dark);
    font-size: .74rem;
    font-weight: 800;
    line-height: 1;
    vertical-align: middle;
}

.qcm-content .collapseomatic {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    margin: .2rem 0 .85rem;
    min-height: 42px;
    padding: .5rem 1rem;
    border: 1px solid var(--teal);
    border-radius: 999px;
    background: var(--teal-soft);
    color: var(--teal-dark);
    font-family: inherit;
    font-size: .82rem;
    font-weight: 750;
    line-height: 1.2;
    cursor: pointer;
    transition: background .18s ease, transform .18s ease;
}

.qcm-content .collapseomatic:hover {
    background: #c9f1e6;
    transform: translateY(-1px);
}

.qcm-content .collapseomatic:focus-visible {
    outline: 3px solid rgba(15, 157, 122, .35);
    outline-offset: 2px;
}

.qcm-content .collapseomatic_content {
    display: none;
    margin: .1rem 0 1rem;
    padding: .8rem .95rem;
    border-left: 4px solid var(--teal);
    border-radius: 0 10px 10px 0;
    background: #f7fbfa;
}

.qcm-content .collapseomatic_content.is-open {
    display: block;
}

.qcm-content .alert-message {
    display: block;
    margin: 0 0 .5rem;
    padding: .55rem .7rem;
    border-radius: 8px;
    font-size: .86rem;
    line-height: 1.55;
}

.qcm-content .alert-message:last-child {
    margin-bottom: 0;
}

.qcm-content .alert-message.answer {
    background: var(--teal-soft);
    color: var(--teal-dark);
}

.qcm-content .alert-message.hint {
    background: var(--gold-soft);
    color: var(--gold-dark);
}

.qcm-content .alert-message b {
    color: inherit;
}

.qcm-content pre {
    margin: .65rem 0;
    padding: .8rem .95rem;
    overflow-x: auto;
    border-radius: 10px;
    background: #0f172a;
    color: #e2e8f0;
    font-size: .8rem;
    line-height: 1.55;
    tab-size: 4;
}

.qcm-content code {
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
}

.qcm-content :not(pre) > code {
    padding: .1rem .32rem;
    border-radius: 4px;
    background: var(--surface-2);
    color: var(--navy);
    font-size: .86em;
}

.qcm-content img {
    max-width: 100%;
    height: auto;
    margin: .7rem 0;
    border: 1px solid var(--line);
    border-radius: 10px;
}

.qcm-content a {
    color: var(--blue-dark);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.qcm-content ul,
.qcm-content ol {
    margin: .5rem 0 .85rem 1.25rem;
}

.qcm-content li {
    margin-bottom: .28rem;
    line-height: 1.65;
}

.qcm-content blockquote {
    margin: .8rem 0;
    padding: .65rem .95rem;
    border-left: 4px solid var(--blue);
    background: var(--blue-soft);
    color: var(--navy);
}

.qcm-content hr {
    margin: 1.2rem 0;
    border: 0;
    border-top: 1px solid var(--line);
}

.qcm-content table {
    width: 100%;
    margin: .8rem 0;
    border-collapse: collapse;
    font-size: .84rem;
}

.qcm-content th,
.qcm-content td {
    padding: .45rem .6rem;
    border: 1px solid var(--line);
    text-align: left;
    vertical-align: top;
}

.qcm-content th {
    background: var(--surface-2);
    color: var(--navy);
}

.qcm-content figure {
    margin: .8rem 0;
}

.qcm-content figcaption {
    margin-top: .3rem;
    color: var(--muted);
    font-size: .78rem;
    text-align: center;
}

.qcm-content:fullscreen {
    overflow: auto;
    padding: clamp(1rem, 4vw, 3rem);
    border: 0;
    border-radius: 0;
    background: #fff;
}

.qcm-error {
    padding: 1.2rem 1.3rem;
    border: 1px dashed #c9d5e5;
    border-radius: var(--radius);
    background: var(--surface);
}

.qcm-error p {
    margin-bottom: .6rem;
    color: var(--muted);
}

.qcm-error strong {
    color: var(--navy);
}

.qcm-help {
    padding: .9rem 1rem;
    border: 1px dashed #c9d5e5;
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, .7);
    color: var(--muted);
    font-size: .82rem;
}

.qcm-help p {
    margin-bottom: .45rem;
}

.qcm-help p:last-child {
    margin-bottom: 0;
}

.qcm-help strong {
    color: var(--navy);
}

@media (max-width: 980px) {
    .qcm-hero__inner {
        grid-template-columns: minmax(0, 1fr);
        gap: 1.25rem;
    }

    .qcm-hero__points {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .qcm-layout {
        grid-template-columns: minmax(0, 1fr);
    }

    .qcm-sidebar {
        position: static;
        padding: .85rem;
    }

    .qcm-cats {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        max-height: none;
        overflow: visible;
        padding-right: 0;
    }
}

@media (max-width: 720px) {
    .qcm-hero__points {
        grid-template-columns: minmax(0, 1fr);
    }

    .qcm-cats {
        grid-template-columns: minmax(0, 1fr);
    }

    .qcm-toolbar {
        align-items: stretch;
        flex-direction: column;
    }

    .qcm-toolbar__actions {
        justify-content: stretch;
    }

    .qcm-toolbar__actions .btn {
        flex: 1 1 auto;
    }

    .qcm-content {
        padding: .9rem;
    }

    .qcm-content h3.qcm-question,
    .qcm-content h3 {
        padding-top: .95rem;
    }

    .qcm-content:fullscreen {
        padding: .9rem;
    }
}

/* ------------------------------------------------------------
   18. Affiches de tutoriels informatiques
   ------------------------------------------------------------ */
.tuto-section {
    position: relative;
}

.tuto-count {
    flex: 0 0 auto;
    align-self: flex-end;
    padding: .45rem .8rem;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: #fff;
    color: var(--muted);
    font-size: .76rem;
    font-weight: 700;
    white-space: nowrap;
    box-shadow: var(--shadow-sm);
}

.tuto-breadcrumb {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: .4rem;
    margin-bottom: .7rem;
    color: var(--muted);
    font-size: .8rem;
}

.tuto-breadcrumb a {
    color: var(--blue-dark);
    text-decoration: none;
}

.tuto-breadcrumb a:hover {
    text-decoration: underline;
}

.tuto-toolbar {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: .7rem;
    margin-bottom: 1.2rem;
    padding: .7rem;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: #fff;
    box-shadow: var(--shadow-sm);
}

.tuto-toolbar__search {
    position: relative;
    display: flex;
    align-items: center;
    flex: 1 1 300px;
}

.tuto-toolbar__search svg {
    position: absolute;
    left: .95rem;
    color: var(--muted-2);
    pointer-events: none;
}

.tuto-toolbar__search input {
    width: 100%;
    padding: .68rem .9rem .68rem 2.6rem;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: var(--surface-2);
    color: var(--ink);
    font: inherit;
    font-size: .9rem;
    transition: border-color .2s ease, box-shadow .2s ease, background .2s ease;
}

.tuto-toolbar__search input:focus {
    outline: none;
    border-color: var(--blue);
    background: #fff;
    box-shadow: 0 0 0 3px rgba(31, 111, 235, .14);
}

.tuto-toolbar__select select {
    min-width: 240px;
    padding: .68rem .8rem;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: var(--surface-2);
    color: var(--ink);
    font: inherit;
    font-size: .88rem;
}

.tuto-toolbar__select select:focus {
    outline: none;
    border-color: var(--blue);
    background: #fff;
    box-shadow: 0 0 0 3px rgba(31, 111, 235, .14);
}

.tuto-toolbar__submit,
.tuto-toolbar__reset {
    flex: 0 0 auto;
    padding: .68rem 1rem;
}

.tuto-matiere-links {
    display: flex;
    gap: .45rem;
    margin-bottom: .9rem;
    padding: .15rem 0 .35rem;
    overflow-x: auto;
    scrollbar-width: thin;
}

.tuto-matiere-links a {
    flex: 0 0 auto;
    padding: .38rem .68rem;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: #fff;
    color: var(--muted);
    font-size: .72rem;
    font-weight: 700;
    line-height: 1;
    text-decoration: none;
    white-space: nowrap;
    transition: border-color .2s ease, color .2s ease, background .2s ease;
}

.tuto-matiere-links a:hover {
    border-color: #cfdaea;
    color: var(--blue-dark);
}

.tuto-matiere-links a.is-active {
    border-color: var(--navy);
    background: var(--navy);
    color: #fff;
}

.tuto-results-note {
    margin: -.2rem 0 1rem;
    color: var(--muted);
    font-size: .85rem;
}

.tuto-empty {
    padding: 3rem 1rem;
    border: 1px dashed var(--line);
    border-radius: 16px;
    background: #fff;
    text-align: center;
}

.tuto-empty p {
    margin-bottom: 1rem;
    color: var(--muted);
}

.tuto-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 1.05rem;
}

.tuto-card {
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: #fff;
    box-shadow: var(--shadow-sm);
    transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}

.tuto-card[hidden] {
    display: none;
}

.tuto-card:hover {
    transform: translateY(-4px);
    border-color: #cfdaea;
    box-shadow: var(--shadow);
}

.tuto-card__media {
    position: relative;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background: var(--navy);
}

.tuto-card__open {
    display: block;
    width: 100%;
    height: 100%;
    text-decoration: none;
}

.tuto-card__media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .35s ease;
}

.tuto-card:hover .tuto-card__media img {
    transform: scale(1.035);
}

.tuto-card__download {
    position: absolute;
    left: 50%;
    bottom: .65rem;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    gap: .35rem;
    padding: .45rem .72rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, .97);
    color: var(--navy);
    font-size: .72rem;
    font-weight: 750;
    line-height: 1;
    text-decoration: none;
    white-space: nowrap;
    box-shadow: 0 6px 18px rgba(11, 31, 58, .28);
    opacity: 0;
    transform: translate(-50%, 10px);
    pointer-events: none;
    transition: opacity .2s ease, transform .2s ease, background .2s ease;
}

.tuto-card:hover .tuto-card__download,
.tuto-card:focus-within .tuto-card__download {
    opacity: 1;
    transform: translate(-50%, 0);
    pointer-events: auto;
}

.tuto-card__download:hover {
    background: #fff;
}

.tuto-card__download svg {
    flex: 0 0 auto;
}

.tuto-card__body {
    display: flex;
    flex-direction: column;
    gap: .28rem;
    padding: .65rem .75rem .8rem;
}

.tuto-card__cat {
    display: inline-flex;
    align-items: center;
    gap: .3rem;
    color: var(--tuto-accent-dark, var(--blue-dark));
    font-size: .6rem;
    font-weight: 800;
    letter-spacing: .07em;
    text-transform: uppercase;
}

.tuto-card__glyph {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 18px;
    height: 18px;
    padding: 0 .25rem;
    border-radius: 6px;
    background: var(--tuto-accent-soft, var(--blue-soft));
    color: var(--tuto-accent-dark, var(--blue-dark));
    font-size: .58rem;
    font-weight: 800;
    letter-spacing: 0;
    line-height: 1;
}

.tuto-card__title {
    display: -webkit-box;
    margin: 0;
    overflow: hidden;
    color: var(--ink);
    font-size: .82rem;
    font-weight: 700;
    line-height: 1.35;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.tuto-sentinel {
    height: 1px;
}

.tuto-loader {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: .5rem;
    padding: 1.2rem 0 .4rem;
    color: var(--muted);
    font-size: .85rem;
}

.tuto-loader[hidden] {
    display: none;
}

.tuto-loader__spinner {
    width: 18px;
    height: 18px;
    border: 2px solid var(--line);
    border-top-color: var(--blue);
    border-radius: 50%;
    animation: tuto-spin .7s linear infinite;
}

@keyframes tuto-spin {
    to { transform: rotate(360deg); }
}

.tuto-actions {
    display: flex;
    justify-content: center;
    margin-top: 1.1rem;
}

.tuto-actions .btn[disabled] {
    opacity: .65;
    cursor: default;
    transform: none;
}

@media (hover: none) {
    .tuto-card__download {
        opacity: 1;
        transform: translate(-50%, 0);
        pointer-events: auto;
    }
}

@media (max-width: 1100px) {
    .tuto-grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

@media (max-width: 900px) {
    .tuto-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 680px) {
    .tuto-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: .8rem;
    }

    .tuto-count {
        align-self: flex-start;
    }

    .tuto-toolbar__search,
    .tuto-toolbar__select,
    .tuto-toolbar__select select {
        flex: 1 1 100%;
        width: 100%;
    }

    .tuto-toolbar__submit,
    .tuto-toolbar__reset {
        flex: 1 1 auto;
        justify-content: center;
    }
}

@media (max-width: 460px) {
    .tuto-grid {
        grid-template-columns: minmax(0, 1fr);
    }
}
