:root {
    color-scheme: light;
    --forest: #1e4634;
    --ink: #1c2822;
    --moss: #1e4634;
    --lichen: #b7c45a;
    --spore: #f3ecdf;
    --sage: #d7e3cf;
    --card: #fff8ee;
    --line: #e4d5c0;
    --bark: #6d4b2e;
    --muted: #3e5146;
    /* Couleurs qui changent avec le mode sombre (valeurs sombres en fin de fichier). */
    --on-forest: #f6f0e4;
    --forest-hover: #26573f;
    --danger: #9b3b2a;
    --danger-bg: #f6e1db;
    --added: #2f6b2f;
    --warn-ink: #8a3f17;
    --warn-bg: #fbefe0;
    --accent: #6d7428;
    --feature-bg: #e7f0e2;
    --paper: #fbf7ef;
    --field: #fff;
    --map-bg: #e6eef0;
}

body {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    margin: 0;
    font-family: system-ui, sans-serif;
    line-height: 1.55;
    background-color: var(--spore);
    background-image: radial-gradient(circle, var(--line) 1px, transparent 1.2px);
    background-size: 16px 16px;
    color: var(--ink);
}

h1, h2, h3 {
    font-family: Georgia, "Iowan Old Style", Palatino, "Palatino Linotype", serif;
    font-weight: 600;
    letter-spacing: -0.02em;
}

a { color: var(--forest); }
a:hover { color: var(--bark); }

.utility {
    border-bottom: 1px solid var(--line);
    font-size: 0.92rem;
}

.bar {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem 1.6rem;
    align-items: center;
    max-width: 72rem;
    margin: 0 auto;
    padding: 1rem 1.25rem;
}

.utility .bar { justify-content: space-between; }

.site-head { border-bottom: 1px solid var(--line); }

.brand {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    color: var(--ink);
    font-weight: 700;
    text-decoration: none;
}

.mark { width: 2rem; height: 2rem; color: var(--forest); }

nav { display: flex; flex-wrap: wrap; gap: 0.35rem 1.15rem; align-items: center; flex: 1; }
nav > a, .nav-item > a, nav summary, nav summary a {
    display: inline-flex;
    align-items: center;
    min-height: 2.5rem;
    color: var(--ink);
    text-decoration: none;
    font-weight: 600;
}
nav > a:hover, .nav-item > a:hover, nav summary a:hover { color: var(--forest); }
nav > a.is-current, .nav-item > a.is-current, nav summary a.is-current {
    background: var(--forest);
    color: var(--on-forest);
    border-radius: 999px;
    padding: 0.2rem 0.75rem;
}
nav > a.is-current:hover, .nav-item > a.is-current:hover, nav summary a.is-current:hover { color: var(--on-forest); }
.utility a.enter.is-current, .utility a.enter.is-current:hover { background: var(--forest); color: var(--on-forest); }

nav details { position: relative; display: inline-flex; align-items: center; }
nav summary { list-style: none; cursor: pointer; }
nav summary::-webkit-details-marker { display: none; }
.menu {
    position: absolute;
    z-index: 2;
    min-width: 11rem;
    margin-top: 0.35rem;
    padding: 0.35rem;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: 0.8rem;
}
.menu a { display: block; padding: 0.35rem 0.55rem; color: var(--ink); text-decoration: none; }
.menu a:hover { background: var(--sage); }

.account-links { display: inline-flex; flex-wrap: wrap; gap: 0.45rem; }
.lang-switch select, .utility a.enter {
    background: transparent;
    color: var(--ink);
    border: 1px solid var(--forest);
    border-radius: 999px;
    padding: 0.3rem 0.7rem;
    text-decoration: none;
}

main {
    flex: 1 0 auto;
    box-sizing: border-box;
    width: 100%;
    max-width: 72rem;
    margin: 0 auto;
    padding: 1.25rem 1.25rem 4rem;
}

.hero {
    padding: 1.5rem 0 0.25rem;
}

.hero-grid, .feature, .columns {
    display: grid;
    gap: 1.5rem;
    align-items: center;
}

.hero-grid { grid-template-columns: 1.15fr 0.85fr; }
.feature, .columns { grid-template-columns: 1fr 1fr; align-items: stretch; }

.eyebrow {
    margin: 0 0 0.4rem;
    color: var(--forest);
    font-size: 0.78rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

h1 { font-size: 3.2rem; line-height: 1.02; margin: 0 0 0.6rem; }
p { text-wrap: pretty; }
.lead { max-width: none; font-size: 1.15rem; text-wrap: pretty; }
.hero-grid .lead { max-width: 40rem; }

.principles { font-size: 1.35rem; font-weight: 700; }
.principles span { margin-right: 0.35rem; }
.principles .accent { color: var(--accent); }

.actions { display: flex; flex-wrap: wrap; gap: 0.6rem; margin: 1rem 0; }

.oval {
    border: 2px solid var(--forest);
    border-radius: 1.5rem;
    background: var(--card);
    overflow: hidden;
}
.oval svg, .feature-art svg { display: block; width: 100%; height: auto; }

.feature {
    margin: 1.5rem 0;
    background: var(--sage);
    border-radius: 1.75rem;
    overflow: hidden;
}
.feature-copy, .feature-art { padding: 1.4rem 1.5rem; }
.feature-art { background: var(--feature-bg); display: flex; align-items: center; }

.phases, .theme-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.55rem;
    margin: 1rem 0 1.5rem;
}
.theme-row.center { justify-content: center; }

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

.phase, .card {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: 1.25rem;
    padding: 1.35rem 1.5rem;
    margin: 0 0 1.15rem;
    box-shadow: 0 0.2rem 0.7rem rgba(109, 75, 46, 0.06);
}
.phases .phase { margin-bottom: 0; }
.card p:last-child, .phase p:last-child { margin-bottom: 0; }

.phase-index {
    display: block;
    color: var(--forest);
    font-weight: 700;
    letter-spacing: 0.08em;
}

.phase h2, .card h2 { margin: 0 0 0.7rem; }

.chip {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    border: 1px solid var(--forest);
    border-radius: 999px;
    padding: 0.35rem 0.8rem;
    color: var(--forest);
    text-decoration: none;
    background: var(--card);
}
.chip:hover, .chip.active { background: var(--sage); }
.chip.active { font-weight: 700; }

.photo {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.oval { aspect-ratio: 4 / 3; }
.feature-art { min-height: 14rem; margin: 0; padding: 0; flex-direction: column; align-items: stretch; }
.feature-art .photo {
    flex: 1 1 0;
    width: 100%;
    min-height: 14rem;
    object-fit: cover;
    border-radius: 0;
}
.phases .phase > a { display: inline-block; margin-top: 0.85rem; }

.donut {
    display: block;
    width: 100%;
    max-width: 36rem;
    height: auto;
    margin: 0.4rem auto;
    mix-blend-mode: multiply; /* le blanc du schéma prend la couleur de la carte */
}
.grid-cards {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.7rem;
    margin: 0.8rem 0 1.4rem;
    padding: 0;
    list-style: none;
}
.grid-cards li {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: 0.8rem;
    padding: 0.7rem 0.85rem;
}
.grid-cards li strong { display: block; margin-bottom: 0.28rem; }
.grid-cards li p { margin: 0; }
.method-block { margin: 0.4rem 0 1.5rem; }
.method-block h2 { margin: 0.2rem 0 0.75rem; }
.method-intro {
    display: grid;
    grid-template-columns: minmax(0, 16rem) minmax(0, 1fr);
    gap: 1rem 1.25rem;
    align-items: center;
}
.method-intro p { margin: 0; }
.method-art {
    margin: 0;
    border-radius: 1.25rem;
    overflow: hidden;
    background: var(--sage);
}
.method-art .photo { height: 12rem; object-fit: cover; }
.method-art .caption { margin: 0; padding: 0.45rem 0.8rem 0.7rem; }
.phase-rule {
    border: 0;
    border-top: 1px solid var(--line);
    margin: 1.15rem 0.35rem 0.85rem;
}
.phase-questions { margin: 0; padding-left: 1.15rem; }
.phase-questions li { margin: 0.35rem 0; }
.quote p:first-child { font-size: 1.15rem; }
.caption { margin: 0.35rem 0 0; font-size: 0.82rem; color: var(--muted); }
.feature-art .caption { margin: 0; padding: 0.45rem 0.8rem 0.7rem; }
.donut-wrap { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); gap: 1rem; align-items: center; }
.legend span { display: inline-block; width: 0.8rem; height: 0.8rem; margin-right: 0.4rem; border-radius: 50%; vertical-align: middle; }
.swatch-over { background: var(--bark); }
.swatch-safe { background: var(--forest); }
.swatch-short { background: #e4cfc0; }
.audit { font-size: 0.92rem; color: var(--muted); }

.site-foot { border-top: 1px solid var(--line); }
.foot { justify-content: space-between; padding-right: 4.75rem; }
.thot img {
    display: block;
    height: 85px;
    width: auto;
    mix-blend-mode: multiply;
}
.thot .logo-dark { display: none; }

label { display: block; margin-top: 0.5rem; }
input, textarea, select, button { font: inherit; padding: 0.4rem 0.5rem; }

form.card {
    display: grid;
    gap: 0.9rem;
    max-width: 32rem;
    /* Un formulaire plus étroit que la page est centré. */
    margin-inline: auto;
}
form.card.full-width { max-width: none; }
form.card label {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0.35rem;
    margin: 0;
}
form.card input,
form.card textarea,
form.card select {
    box-sizing: border-box;
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 0.7rem;
    background: var(--spore);
    color: var(--ink);
    padding: 0.55rem 0.7rem;
}
form.card textarea { min-height: 8rem; resize: vertical; }
form.card input[type="checkbox"],
form.card input[type="radio"] { width: auto; flex: none; }
form.card label:has(input[type="checkbox"]),
form.card label:has(input[type="radio"]) {
    flex-direction: row;
    align-items: center;
}
form.card button { width: auto; justify-self: start; }
td form, td label { display: inline-flex; flex-direction: row; align-items: center; gap: 0.35rem; margin: 0.15rem 0; }
td input, td select { width: auto; max-width: 9rem; }
button, .button {
    display: inline-block;
    background: var(--forest);
    color: var(--on-forest);
    border: 1px solid var(--forest);
    border-radius: 999px;
    padding: 0.5rem 0.95rem;
    text-decoration: none;
    cursor: pointer;
    transition: transform 0.18s ease, background 0.18s ease;
}
button:hover, .button:hover { transform: translateY(-1px); background: var(--forest-hover); }
.button.ghost:hover, button.ghost:hover { background: var(--sage); }
.button.ghost, button.ghost {
    background: transparent;
    color: var(--forest);
}
button:disabled {
    opacity: 0.45;
    filter: grayscale(1);
    cursor: not-allowed;
    transform: none;
}
button:disabled:hover {
    transform: none;
    background: var(--forest);
}
button.ghost:disabled,
button.ghost:disabled:hover {
    background: transparent;
    color: var(--forest);
}

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

table { width: 100%; border-collapse: collapse; background: var(--card); }
th, td { text-align: left; padding: 0.45rem 0.5rem; border-bottom: 1px solid var(--line); }

@media (max-width: 800px) {
    .hero-grid, .feature, .columns, .phases, .grid-cards, .donut-wrap, .method-intro { grid-template-columns: 1fr; }
    .collection.lignes > .card { grid-template-columns: 1fr; }
    .collection.lignes .summary, .collection.lignes .meta { white-space: normal; }
    h1 { font-size: 2.2rem; }
    .menu { position: static; }
}


.muted, .note { color: var(--muted); }
.note { margin: 0 0 1rem; }
.actions { display: flex; flex-wrap: wrap; gap: 0.6rem; align-items: center; }
form.card fieldset {
    margin: 0;
    padding: 0.7rem 0.85rem 0.85rem;
    border: 1px solid var(--line);
    border-radius: 0.7rem;
}
form.card legend { padding: 0 0.3rem; }

nav.pager {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    align-items: center;
    justify-content: center;
    margin: 0.4rem 0 1.5rem;
}
nav.pager .summary {
    flex-basis: 100%;
    color: var(--muted);
    text-align: center;
}
nav.pager .page {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    min-width: 2.6rem;
    height: 2.6rem;
    padding: 0 0.75rem;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--card);
    color: var(--ink);
    text-decoration: none;
}
nav.pager a.page:hover { background: var(--sage); }
nav.pager span.page { color: var(--muted); }
nav.pager span.page[aria-current="page"] {
    background: var(--forest);
    border-color: var(--forest);
    color: var(--spore);
    font-weight: 700;
}

.modal {
    box-sizing: border-box;
    border: 1px solid var(--line);
    border-radius: 1.25rem;
    background: var(--card);
    color: var(--ink);
    padding: 1.35rem 1.5rem;
    width: min(34rem, calc(100vw - 2rem));
    max-height: calc(100vh - 2rem);
    overflow: auto;
}
.modal::backdrop { background: rgba(28, 40, 34, 0.46); }
.modal h2 { margin: 0 0 0.8rem; }
.modal form.card {
    border: 0;
    padding: 0;
    margin: 0;
    background: transparent;
    max-width: none;
}
.card.companion { position: relative; }
button.companion-open {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: inherit;
    background: transparent;
    color: transparent;
}
.carousel img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: 0.8rem;
}

.view-switch {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.45rem;
    margin: 0 0 1rem;
}

details.filters,
details.filters[open] {
    box-sizing: border-box;
    width: 100%;
    max-width: none;
    margin: 0 0 1rem;
    border: 1px solid var(--line);
    border-radius: 1rem;
    background: var(--card);
    padding: 0.15rem 0.9rem 0.2rem;
}
details.filters > summary {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.45rem;
    cursor: pointer;
    font-weight: 650;
    padding: 0.55rem 0.2rem;
    list-style: none;
}
details.filters > summary::-webkit-details-marker { display: none; }
details.filters > summary::before {
    content: "";
    width: 0.4rem;
    height: 0.4rem;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: rotate(-45deg);
    margin-top: -0.15rem;
}
details.filters[open] > summary::before {
    transform: rotate(45deg);
    margin-top: 0.15rem;
}
details.filters form {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: end;
    gap: 0.7rem 0.9rem;
    padding: 0.1rem 0 0.7rem;
}
details.filters label {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    margin: 0;
    flex: 1 1 10rem;
    min-width: 0;
    max-width: none;
    font-size: 0.92rem;
}
details.filters input,
details.filters select {
    box-sizing: border-box;
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 0.7rem;
    background: var(--spore);
    color: var(--ink);
    padding: 0.45rem 0.65rem;
}
details.filters button { align-self: end; margin-inline-start: 0.6rem; }

.legal {
    max-width: 40rem;
    margin-inline: auto;
}
.legal h2 { margin: 1.6rem 0 0.35rem; }
.legal p { margin: 0.35rem 0 0; }
.legal ul { padding-left: 1.15rem; }
.collection.cartes {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 16rem), 1fr));
    gap: 0.9rem;
    align-items: stretch;
    margin: 0 0 1.15rem;
}
.collection.cartes > .card {
    margin: 0;
    display: flex;
    flex-direction: column;
    padding: 1.05rem 1.1rem;
}
.collection.cartes > .card h2 { font-size: 1.25rem; }
.collection.cartes .summary {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    overflow: hidden;
}
.collection.cartes .theme-row { margin: 0.45rem 0 0; }
.collection.lignes {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin: 0 0 1.15rem;
}
.collection.lignes > .card {
    display: grid;
    grid-template-columns: minmax(11rem, 16rem) minmax(8rem, 13rem) minmax(0, 1.6fr);
    gap: 0.35rem 1rem;
    align-items: center;
    margin: 0;
    padding: 0.75rem 1rem;
    border-radius: 0.9rem;
}
.collection.lignes > .card h2 { margin: 0; font-size: 1.15rem; }
.collection.lignes > .card p { margin: 0; }
.collection.lignes .summary,
.collection.lignes .meta {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.collection.lignes .theme-row { margin: 0.25rem 0 0; }
.collection.lignes > .card form.card {
    grid-column: 1 / -1;
    max-width: none;
    margin: 0;
    padding: 0.7rem 0 0;
    border: 0;
    background: transparent;
}
.table-wrap { overflow-x: auto; margin: 0 0 1.15rem; }
.table-wrap table { margin: 0; }
.inline-ask {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    align-items: center;
    margin: 0;
}
.inline-ask input { width: auto; min-width: 8rem; }

.scroll-dock {
    position: fixed;
    right: 1.1rem;
    bottom: 1.1rem;
    z-index: 30;
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
}
.scroll-dock[hidden],
.scroll-jump[hidden] { display: none !important; }
.scroll-jump {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.75rem;
    height: 2.75rem;
    border-radius: 999px;
    background: var(--forest);
    color: var(--spore);
    border: 1px solid var(--forest);
    text-decoration: none;
    box-shadow: 0 0.35rem 1rem rgba(28, 40, 34, 0.16);
}
.scroll-jump svg {
    width: 1.15rem;
    height: 1.15rem;
    display: block;
}
.scroll-jump:hover { background: var(--moss); }

.wiki-search {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    align-items: end;
    width: 100%;
    margin: 0 0 1.4rem;
}
.wiki-search label { flex: 1 1 16rem; margin: 0; }
.wiki-search input {
    box-sizing: border-box;
    width: 100%;
    margin-top: 0.3rem;
    border: 1px solid var(--line);
    border-radius: 0.7rem;
    background: var(--card);
    padding: 0.55rem 0.7rem;
}
.wiki-index {
    columns: 3 16rem;
    column-gap: 2rem;
    margin: 1.2rem 0 2rem;
}
.wiki-index section { break-inside: avoid; margin: 0 0 1.1rem; }
.wiki-index h2 {
    margin: 0 0 0.35rem;
    padding-bottom: 0.2rem;
    border-bottom: 1px solid var(--line);
    font-size: 1.15rem;
}
.wiki-index ul { list-style: none; margin: 0; padding: 0; }
.wiki-index li { margin: 0.2rem 0; }
.wiki-index a { color: var(--forest); text-decoration: none; }
.wiki-index a:hover { text-decoration: underline; }
.entry, .see-also { max-width: 42rem; margin-inline: auto; }
.entry-body > p:first-of-type { font-size: 1.15rem; }
.entry-body h2 { margin: 1.8rem 0 0.45rem; font-size: 1.35rem; }
.entry-body h3 { margin: 1.3rem 0 0.35rem; }
.entry-body p { margin: 0.7rem 0; }
.entry-body ul, .entry-body ol { padding-left: 1.2rem; }
.entry-body blockquote {
    margin: 1rem 0;
    padding: 0.2rem 0 0.2rem 0.9rem;
    border-left: 3px solid var(--lichen);
}
.toc {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: 1rem;
    padding: 0.85rem 1.1rem;
    margin: 0.4rem 0 1.3rem;
}
.toc p { margin: 0; font-weight: 700; }
.toc ol { margin: 0.4rem 0 0; }
.see-also { margin-top: 2rem; }
.see-also ul { padding-left: 1.1rem; }
.entry-tools { margin: 0.8rem 0 1rem; }
.modal.wide { width: min(44rem, calc(100vw - 2rem)); }
.manage-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 0.5rem;
    align-items: center;
    margin: 0.45rem 0;
}
.manage-row form:first-child {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 0.45rem;
    align-items: center;
}
.manage-row input {
    box-sizing: border-box;
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 0.7rem;
    background: var(--spore);
    padding: 0.45rem 0.65rem;
}
.actions form { margin: 0; }

@media (max-width: 800px) {
    .manage-row { grid-template-columns: 1fr; }
}

.view-toggle { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 0 0 1rem; }
.view-toggle a {
    display: inline-flex;
    align-items: center;
    min-height: 2.4rem;
    padding: 0.35rem 0.9rem;
    border: 1px solid var(--forest);
    border-radius: 999px;
    color: var(--forest);
    text-decoration: none;
}
.view-toggle a[aria-current="page"] { background: var(--sage); }
.agora-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; margin: 0 0 1rem; }
.agora-bar .view-toggle { flex: 0 0 auto; margin: 0; }
.agora-bar .view-toggle a,
.agora-bar > .button {
    box-sizing: border-box;
    display: inline-flex;
    align-items: center;
    min-height: 2.6rem;
    padding: 0.35rem 1rem;
    line-height: 1.2;
    font: inherit;
}
.forum-shell { display: grid; grid-template-columns: 16rem minmax(0, 1fr); gap: 1.25rem; align-items: start; }
.forum-side { display: flex; flex-direction: column; gap: 0.2rem; }
.forum-side a {
    display: flex;
    justify-content: space-between;
    gap: 0.6rem;
    padding: 0.35rem 0.2rem;
    color: var(--forest);
    text-decoration: none;
    border-bottom: 1px solid var(--line);
}
.forum-side a.sub { padding-left: 1rem; }
.forum-side a[aria-current="page"] { font-weight: 700; }
.editor-bar { display: flex; flex-wrap: wrap; gap: 0.35rem; margin: 0 0 0.45rem; }
.editor-bar button, .editor-bar label.ghost {
    display: inline-flex;
    align-items: center;
    background: transparent;
    color: var(--forest);
    border: 1px solid var(--forest);
    border-radius: 999px;
    padding: 0.25rem 0.7rem;
    cursor: pointer;
}
.toasts {
    position: fixed;
    right: 1rem;
    bottom: 1rem;
    z-index: 40;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    width: min(22rem, calc(100vw - 2rem));
}
.toast {
    background: var(--card);
    color: var(--ink);
    border: 1px solid var(--forest);
    border-radius: 1rem;
    padding: 0.8rem 1rem;
    box-shadow: 0 0.35rem 1rem rgba(28, 40, 34, 0.16);
}
.toast.failed { border-color: var(--bark, #8a5a3a); }
.toast p { margin: 0 0 0.35rem; }
.toast a { color: var(--forest); }
.desk .page-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
    margin: 0 0 1rem;
}
.desk .page-bar h1, .desk .page-bar h2 { margin: 0; }
.desk details.filters, .desk details.filters[open] { width: 100%; max-width: none; margin: 0 0 1rem; }
.desk .row-actions { display: flex; flex-wrap: wrap; gap: 0.4rem; align-items: center; }
.desk .journal { margin-top: 1.5rem; }
.desk .journal .audit { margin: 0.6rem 0 0; }
.desk .audit li { display: flex; flex-wrap: wrap; gap: 0.35rem 0.9rem; }
.role {
    display: inline-block;
    border-radius: 999px;
    padding: 0.12rem 0.55rem;
    background: var(--sage);
    font-size: 0.85rem;
}
.role.admin { background: var(--lichen); }
.guest-write, .auth-links { margin: 0.35rem 0 1rem; }
.auth-links { display: flex; flex-wrap: wrap; gap: 0.5rem 1.25rem; }

@media (max-width: 800px) {
    .forum-shell { grid-template-columns: 1fr; }
}

@keyframes rise {
    from { opacity: 0; transform: translateY(0.45rem); }
    to { opacity: 1; transform: none; }
}
.hero, .feature, .toast { animation: rise 0.5s ease both; }
.phase { animation: rise 0.5s ease both; }
.phase:nth-child(2) { animation-delay: 0.06s; }
.phase:nth-child(3) { animation-delay: 0.12s; }
.phase, article.card { transition: transform 0.18s ease, box-shadow 0.18s ease; }
.phase:hover, article.card:hover {
    transform: translateY(-2px);
    box-shadow: 0 0.5rem 1.1rem rgba(109, 75, 46, 0.1);
}
@media (prefers-reduced-motion: reduce) {
    .hero, .feature, .phase, .toast { animation: none; }
    .phase, article.card, button, .button { transition: none; }
}


/* ---------- Évolutions octobre 2026 ---------- */
.skip-link {
    position: absolute;
    left: 0.75rem;
    top: -3rem;
    z-index: 50;
    background: var(--forest);
    color: var(--on-forest);
    padding: 0.55rem 0.9rem;
    border-radius: 999px;
    text-decoration: none;
}
.skip-link:focus { top: 0.75rem; }
main:focus { outline: none; }
:focus-visible { outline: 3px solid var(--forest); outline-offset: 2px; }

.nav-item { display: inline-flex; align-items: center; gap: 0.1rem; position: relative; }
nav details.sub { position: relative; display: inline-flex; }
nav details.sub > summary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 1.75rem;
    min-height: 2.5rem;
    border-radius: 999px;
    cursor: pointer;
}
nav details.sub > summary:hover { background: var(--sage); }
.chevron {
    width: 0.45rem;
    height: 0.45rem;
    border-right: 2px solid currentColor;
    border-bottom: 2px solid currentColor;
    transform: translateY(-2px) rotate(45deg);
}
nav details.sub[open] .chevron { transform: translateY(2px) rotate(-135deg); }
nav details.sub .menu { top: 100%; left: 50%; transform: translateX(-50%); }
nav a.nav-contribute:not(.is-current) {
    border: 1px solid var(--forest);
    border-radius: 999px;
    padding: 0.2rem 0.75rem;
    color: var(--forest);
}

.menu-toggle {
    margin-left: auto;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: transparent;
    color: var(--forest);
}
.menu-toggle[hidden] { display: none; }
.menu-icon, .menu-icon::before, .menu-icon::after {
    display: block;
    width: 1.1rem;
    height: 2px;
    background: currentColor;
    border-radius: 2px;
    position: relative;
}
.menu-icon::before, .menu-icon::after { content: ""; position: absolute; left: 0; }
.menu-icon::before { top: -6px; }
.menu-icon::after { top: 6px; }
.menu-toggle[aria-expanded="true"] .menu-icon { background: transparent; }
.menu-toggle[aria-expanded="true"] .menu-icon::before { top: 0; transform: rotate(45deg); }
.menu-toggle[aria-expanded="true"] .menu-icon::after { top: 0; transform: rotate(-45deg); }

.breadcrumb { font-size: 0.9rem; color: var(--muted); margin: 0.25rem 0 0.75rem; }
.breadcrumb a { color: var(--muted); }
.small { font-size: 0.88rem; }

.how { margin: 1.5rem 0; }
.how h2 { margin: 0 0 0.8rem; }
.steps {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.8rem;
    margin: 0;
    padding: 0;
    list-style: none;
    counter-reset: step;
}
.steps li {
    counter-increment: step;
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: 1.25rem;
    padding: 1.2rem 1.35rem;
}
.steps li::before {
    content: counter(step, decimal-leading-zero);
    display: block;
    color: var(--forest);
    font-weight: 700;
    letter-spacing: 0.08em;
}
.steps h3 { margin: 0.2rem 0 0.5rem; }
.steps p { margin: 0 0 0.6rem; }

.cta-band { background: var(--sage); border-color: transparent; }
.cta-band .actions { margin-bottom: 0; }
.why p { max-width: 52rem; }
.faq h3 { margin: 1rem 0 0.3rem; font-size: 1.05rem; }

.badges { display: flex; flex-wrap: wrap; gap: 0.4rem; margin: 0 0 0.8rem; }
.badge {
    display: inline-block;
    border-radius: 999px;
    padding: 0.2rem 0.65rem;
    background: var(--spore);
    border: 1px solid var(--line);
    font-size: 0.85rem;
}
.badge.ok { background: var(--sage); border-color: var(--forest); }
.badge.partner { background: var(--lichen); border-color: var(--lichen); color: #1c2822; }
.facts {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 15rem), 1fr));
    gap: 0.6rem 1.2rem;
    margin: 1rem 0;
}
.facts div { background: var(--card); border: 1px solid var(--line); border-radius: 0.9rem; padding: 0.65rem 0.85rem; }
.facts dt { font-size: 0.8rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.facts dd { margin: 0.2rem 0 0; }
.facts dd.theme-row { margin: 0.3rem 0 0; }

.donate-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 1rem; align-items: start; }
.donate-grid form.card { max-width: none; }
.amounts { display: flex; flex-wrap: wrap; gap: 0.5rem; border: 0; padding: 0; margin: 0; }
.amounts legend { font-weight: 700; margin-bottom: 0.45rem; }
form.card .amount-choice { flex-direction: row; }
.amount-choice input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.amount-choice span {
    display: inline-block;
    min-width: 4.2rem;
    text-align: center;
    border: 1px solid var(--forest);
    border-radius: 999px;
    padding: 0.5rem 0.9rem;
    cursor: pointer;
    font-weight: 700;
    color: var(--forest);
}
.amount-choice input:checked + span { background: var(--forest); color: var(--on-forest); }
.amount-choice input:focus-visible + span { outline: 3px solid var(--forest); outline-offset: 2px; }
.costs table { margin: 0.5rem 0 0.8rem; }
.costs th { font-weight: 400; }
.costs td { text-align: right; white-space: nowrap; }
.costs tr.total th, .costs tr.total td { font-weight: 700; border-bottom: 0; }
meter { width: 100%; height: 0.9rem; }
.meter-label { margin: 0 0 0.3rem; font-weight: 700; }
.ledger-figures {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 11rem), 1fr));
    gap: 0.6rem;
    margin: 0.4rem 0 0.8rem;
}
.ledger-figures div { background: var(--spore); border-radius: 0.9rem; padding: 0.6rem 0.8rem; }
.ledger-figures dt { font-size: 0.85rem; color: var(--muted); }
.ledger-figures dd { margin: 0.15rem 0 0; font-size: 1.25rem; font-weight: 700; }

.compare th[scope="row"] { font-weight: 600; }
.compare td { text-align: center; }
/* Positionnement : carte à deux axes (gratuit ↔ payant, entraide ↔ outils), Greencelium entre entraide et outils. */
.position-map { margin: 1rem 0 0; }
.pm-grid {
    display: grid;
    grid-template-columns: 1.6rem 1fr 1fr;
    grid-template-areas:
        ".       hfree  hpaid"
        "vpeople peers  paths"
        ".       us     us"
        "vtools  public pro";
    gap: 0.6rem;
}
.pm-h { margin: 0; text-align: center; font-size: 0.8rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); border-bottom: 2px solid var(--line); padding-bottom: 0.3rem; }
.pm-h-free { grid-area: hfree; }
.pm-h-paid { grid-area: hpaid; }
.pm-v { margin: 0; writing-mode: vertical-rl; transform: rotate(180deg); text-align: center; font-size: 0.8rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); border-left: 2px solid var(--line); }
.pm-v-people { grid-area: vpeople; }
.pm-v-tools { grid-area: vtools; }
.pm-q { background: var(--spore); border: 1px solid var(--line); border-radius: 1rem; padding: 0.8rem 1rem; }
.pm-q h3, .pm-us h3 { margin: 0.1rem 0 0.35rem; font-size: 1.05rem; }
.pm-q p, .pm-us p { margin: 0 0 0.4rem; }
.pm-tags { font-size: 0.75rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); }
.pm-ex { font-size: 0.85rem; color: var(--muted); }
.pm-peers { grid-area: peers; }
.pm-paths { grid-area: paths; }
.pm-public { grid-area: public; }
.pm-pro { grid-area: pro; }
.pm-us { grid-area: us; justify-self: center; width: min(100%, 26rem); margin: 2rem 0; text-align: center; background: var(--forest); color: var(--on-forest); border-radius: 1rem; padding: 0.8rem 1.2rem; }
.pm-q, .pm-us { position: relative; z-index: 1; }
.pm-threads { grid-area: 2 / 2 / 5 / 4; width: 100%; height: 100%; contain: size; align-self: stretch; z-index: 0; pointer-events: none; }
.pm-threads path { fill: none; stroke: var(--forest); stroke-width: 2; stroke-linecap: round; stroke-dasharray: 2 5; opacity: 0.75; vector-effect: non-scaling-stroke; }
.pm-us .pm-tags { color: inherit; opacity: 0.85; }
.pm-q .pm-tags { display: none; } /* les en-têtes des axes suffisent sur grand écran */
.position-map figcaption { margin-top: 0.7rem; }
@media (max-width: 720px) {
    .pm-grid { grid-template-columns: 1fr; grid-template-areas: "us" "peers" "public" "paths" "pro"; }
    .pm-h, .pm-v, .pm-threads { display: none; }
    .pm-us { margin: 0; }
    .pm-q .pm-tags { display: block; }
}
.principles-list { margin: 0; padding-left: 1.1rem; }
.principles-list li { margin: 0.45rem 0; }

.resource-group { margin: 1.5rem 0 0.5rem; }
.resource h3 { margin: 0 0 0.25rem; font-size: 1.1rem; }
.resource .meta { margin: 0 0 0.5rem; color: var(--muted); font-size: 0.88rem; }
.resource .summary-full { margin: 0 0 0.6rem; }
.chip.free { background: var(--sage); }

.quick-links { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 0 0 1.2rem; }
.roadmap-list { padding-left: 1.1rem; }
.roadmap-list li { margin: 0.35rem 0; }
.roadmap-list meter { max-width: 12rem; vertical-align: middle; margin-left: 0.4rem; }
.roadmap-new > summary, .org-new > summary { cursor: pointer; font-weight: 700; color: var(--forest); padding: 0.4rem 0; }
.wizard { display: grid; gap: 0.9rem; max-width: 46rem; margin-inline: auto; }
.wizard fieldset { border: 1px solid var(--line); border-radius: 1rem; padding: 0.8rem 1rem 1rem; margin: 0; }
.wizard legend { font-weight: 700; padding: 0 0.35rem; }
.wizard label { display: flex; flex-direction: column; gap: 0.3rem; }
.wizard input:not([type="checkbox"]), .wizard textarea {
    box-sizing: border-box;
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 0.7rem;
    background: var(--spore);
    color: var(--ink);
    padding: 0.55rem 0.7rem;
}
.wizard label.check, .check { flex-direction: row; align-items: center; gap: 0.45rem; }
.check-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 12rem), 1fr)); gap: 0.25rem 1rem; }
.org-new form { display: grid; gap: 0.7rem; max-width: 32rem; margin-inline: auto; }
.org-new label { display: flex; flex-direction: column; gap: 0.3rem; }
.org-new input, .org-new select { box-sizing: border-box; width: 100%; border: 1px solid var(--line); border-radius: 0.7rem; background: var(--spore); padding: 0.5rem 0.65rem; }
.progress-line meter { max-width: 16rem; vertical-align: middle; margin-left: 0.5rem; }
.roadmap-action { border-top: 1px solid var(--line); padding: 0.9rem 0 0.4rem; }
.roadmap-action:first-of-type { border-top: 0; }
.roadmap-action h3 { margin: 0 0 0.35rem; }
.roadmap-action.status-done h3::after { content: " ✓"; color: var(--forest); }
.inline-form { display: flex; flex-wrap: wrap; align-items: end; gap: 0.5rem; }
.inline-form label { display: flex; flex-direction: column; gap: 0.25rem; margin: 0; }

.filter-form {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 12rem), 1fr));
    gap: 0.6rem 0.9rem;
    align-items: end;
}
.filter-form label { margin: 0; display: flex; flex-direction: column; gap: 0.3rem; }
.filter-form input, .filter-form select { box-sizing: border-box; width: 100%; }
.filter-form button { justify-self: start; }

.foot { flex-direction: column; align-items: flex-start; gap: 0.6rem; }
.foot-map { display: flex; flex-wrap: wrap; gap: 0.4rem 1.1rem; }
.foot-map a { color: var(--ink); }
.foot-brands { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem; width: 100%; }
.ecoindex img, .eco-badge { display: block; height: 44px; width: auto; }
.eco-badge { font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; }
.eco-badge .eco-bg { fill: var(--field); stroke: var(--line); }
.eco-badge .eco-t1 { fill: var(--ink); }
.eco-badge .eco-t2 { fill: var(--muted); }

@media (max-width: 1024px) {
    .steps { grid-template-columns: 1fr; }
}

@media (max-width: 800px) {
    h1 { font-size: 2rem; line-height: 1.1; }
    .utility .bar { padding: 0.5rem 1rem; gap: 0.5rem; }
    .site-head .bar { padding: 0.6rem 1rem; }
    .lang-switch select, .utility a.enter { padding: 0.25rem 0.6rem; font-size: 0.9rem; }
    nav.is-collapsible { display: none; }
    nav.is-collapsible.is-open {
        display: flex;
        flex-direction: column;
        align-items: stretch;
        flex-basis: 100%;
        gap: 0.2rem;
        padding: 0.4rem 0 0.6rem;
    }
    nav.is-collapsible.is-open > a, nav.is-collapsible.is-open .nav-item { padding: 0.15rem 0; }
    nav.is-collapsible.is-open .nav-item { flex-wrap: wrap; }
    nav details.sub .menu { position: static; transform: none; margin-top: 0.2rem; }
    .donate-grid { grid-template-columns: 1fr; }
    .foot { padding-right: 1rem; }
    .thot img { height: 72px; }
    .foot { padding-bottom: 4.5rem; }
    .scroll-dock { bottom: 0.6rem; right: 0.6rem; }
}

/* Fonctions du plan d’octobre 2026 */
.flash.warn { border-color: var(--bark); background: var(--warn-bg); }
.flash p { margin: 0 0 0.3rem; }
details > summary.button { list-style: none; display: inline-block; }
details > summary.button::-webkit-details-marker { display: none; }
details[open] > summary.button { margin-bottom: 0.8rem; }
.pre-line { white-space: pre-line; }
.roadmap-tools { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; margin: 0 0 1rem; }
.roadmap-tools .view-toggle { margin: 0; }
.roadmap-tools form { margin: 0; }
.action-edit { margin: 0.4rem 0 0.8rem; }
.action-edit > summary { cursor: pointer; color: var(--forest); font-weight: 600; }
.action-edit form { margin-top: 0.6rem; }
.facts.compact { grid-template-columns: repeat(auto-fill, minmax(min(100%, 11rem), 1fr)); gap: 0.4rem 0.8rem; margin: 0.5rem 0; }
.facts.compact div { padding: 0.4rem 0.65rem; border-radius: 0.7rem; }
.kanban { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0.9rem; align-items: start; }
.kanban-col { background: var(--sage); border-radius: 1.1rem; padding: 0.8rem; }
.kanban-col h2 { margin: 0 0 0.6rem; font-size: 1.15rem; }
.kanban-card { margin: 0 0 0.6rem; padding: 0.75rem 0.85rem; }
.kanban-card h3 { margin: 0.1rem 0 0.4rem; font-size: 1rem; }
.kanban-card .eyebrow { margin: 0; }
.kanban-card .inline-form { display: flex; flex-wrap: wrap; gap: 0.3rem; }
.kanban-card button.small { padding: 0.25rem 0.6rem; font-size: 0.85rem; }
.actor-map { margin: 0 0 1.2rem; }
.actor-map svg { display: block; width: 100%; max-width: 46rem; height: auto; margin: 0 auto; background: var(--map-bg); border: 1px solid var(--line); border-radius: 1rem; }
.actor-map .land { fill: var(--card); stroke: var(--line); stroke-width: 1; }
.actor-map .dot { fill: var(--forest); stroke: var(--card); stroke-width: 1.5; }
.actor-map .dot-association_biodiversite { fill: #3f7d4e; }
.actor-map .dot-association_culturelle { fill: var(--bark); }
.actor-map .dot-acteur_social { fill: #8a5a9e; }
.actor-map .dot-conseil { fill: #2f6f8f; }
.actor-map a:hover .dot, .actor-map a:focus .dot { fill: var(--lichen); stroke: var(--ink); }
.actor-map figcaption { text-align: center; margin-top: 0.4rem; }
.glossary { margin: 1.2rem 0; }
.glossary > div { background: var(--card); border: 1px solid var(--line); border-radius: 1rem; padding: 0.9rem 1.1rem; margin: 0 0 0.7rem; scroll-margin-top: 5rem; }
.glossary dt { font-family: Georgia, "Iowan Old Style", Palatino, serif; font-weight: 600; font-size: 1.1rem; }
.glossary dd { margin: 0.3rem 0 0; }
.glossary dd p { margin: 0 0 0.3rem; }
.stats { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 11rem), 1fr)); gap: 0.6rem; margin: 0.8rem 0; }
.stats div { background: var(--card); border: 1px solid var(--line); border-radius: 1rem; padding: 0.8rem 1rem; }
.stats dt { font-size: 0.85rem; color: var(--muted); }
.stats dd { margin: 0.2rem 0 0; font-size: 1.6rem; font-weight: 700; color: var(--forest); }
.diag-form h2 { margin: 1.2rem 0 0.4rem; }
.diag-question { border: 1px solid var(--line); border-radius: 0.9rem; padding: 0.6rem 0.9rem 0.7rem; margin: 0 0 0.6rem; }
.diag-question legend { float: left; width: 100%; padding: 0; margin: 0 0 0.35rem; font-weight: 600; }
.diag-question legend + * { clear: left; }
.diag-question label.check { display: inline-flex; align-items: center; gap: 0.35rem; margin: 0.2rem 1rem 0 0; }
.diag-phases { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0.8rem; }
.diag-phases p { margin: 0 0 0.3rem; }
.diag-phases meter { width: 100%; }
.diag-priorities li { margin: 0 0 0.4rem; }
.gathering .actions { margin-top: 0.4rem; }
.gathering h3 { margin: 0.1rem 0 0.4rem; }
@media (max-width: 800px) {
    .kanban, .diag-phases { grid-template-columns: 1fr; }
}

@media print {
    .utility, .site-head, .site-foot, .scroll-dock, .skip-link, .inline-form button, .cta-band, .breadcrumb, .no-print, .action-edit { display: none !important; }
    body { background: #fff; color: #000; }
    .card, .phase { box-shadow: none; break-inside: avoid; }
    .roadmap-action { break-inside: avoid; }
}

/* Lot 3 : maturité, jalons, pièces, commentaires, versions */
.maturity-steps {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 0.4rem;
    margin: 0 0 1rem;
    padding: 0;
    list-style: none;
}
.maturity-steps li {
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
    padding: 0.5rem 0.6rem;
    border: 1px solid var(--line);
    border-radius: 0.5rem;
}
.maturity-steps li.reached { background: var(--sage); }
.maturity-steps li.current { outline: 2px solid var(--forest); outline-offset: 1px; }
.maturity-number { font-weight: 700; }
.maturity-name { font-family: Georgia, "Iowan Old Style", Palatino, serif; }
.checklist { margin: 0 0 1rem; padding: 0; list-style: none; }
.checklist li { display: flex; gap: 0.5rem; padding: 0.15rem 0; }
.checklist li.met { color: var(--muted); }
.milestones { margin: 0.5rem 0; padding: 0; list-style: none; }
.milestones li { padding: 0.2rem 0; }
.attachments ul, .comments { margin: 0.3rem 0 0.6rem; padding-left: 1.1rem; }
.attachments li { display: flex; flex-wrap: wrap; gap: 0.4rem; align-items: baseline; }
.comments li, .comment { margin-bottom: 0.6rem; }
.comment { border-top: 1px solid var(--line); padding-top: 0.5rem; }
.meta { margin: 0; font-size: 0.85rem; color: var(--muted); }
button.danger, .button.danger { border-color: var(--danger); color: var(--danger); background: transparent; }
button.danger:hover, .button.danger:hover { background: var(--danger-bg); }
tr.change-added td:first-child, .chip.change-added { color: var(--added); font-weight: 600; }
tr.change-removed td { color: var(--muted); text-decoration: line-through; }
tr.change-removed td:first-child { text-decoration: none; }
.vsme-section h2 .chip { font-family: system-ui, sans-serif; }
@media (max-width: 800px) {
    .maturity-steps { grid-template-columns: 1fr; }
    .maturity-sub { display: inline; }
}
@media print {
    .maturity-steps li.current { outline: 1px solid #000; }
}
.chip.verified { background: var(--sage); border-color: var(--forest); }
.chip.in-review { border-style: dashed; }
.card.solution { border-left: 4px solid var(--forest); }
.note.warn { border-left: 4px solid var(--bark); padding-left: 0.6rem; }
.live-status { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; margin: 0.75rem 0 0; padding: 0.5rem 0.8rem; border: 1px solid var(--line); border-radius: 0.75rem; background: var(--card); }
.live-status.live-ready { border-color: var(--forest); }
.live-dot { width: 0.6rem; height: 0.6rem; border-radius: 50%; background: var(--moss); animation: live-pulse 1.4s ease-in-out infinite; }
.live-ready .live-dot { animation: none; background: var(--forest); }
@keyframes live-pulse { 50% { opacity: 0.25; } }
@media (prefers-reduced-motion: reduce) { .live-dot { animation: none; } }
.toast.toast-again { animation: toast-again 0.9s ease-out 2; }
@keyframes toast-again { 50% { transform: translateY(-0.25rem); box-shadow: 0 0.5rem 1.4rem rgba(28, 40, 34, 0.28); } }
@media (prefers-reduced-motion: reduce) { .toast.toast-again { animation: none; } }
.savoirs-tabs { margin: 0 0 1rem; }
.licence { margin-top: 1.2rem; }
/* Sélecteur de langue en liens (details/summary, sans JavaScript) */
.lang-switch { position: relative; }
.lang-switch summary {
    list-style: none;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    min-height: 2rem;
    padding: 0.25rem 0.75rem;
    border: 1px solid var(--forest);
    border-radius: 999px;
}
.lang-switch summary::-webkit-details-marker { display: none; }
.lang-switch .menu { left: 0; list-style: none; margin: 0.35rem 0 0; padding: 0.35rem; }
.lang-switch .menu a { min-height: 2rem; display: flex; align-items: center; }
.lang-switch .menu a[aria-current] { font-weight: 700; }
/* Sous-titres d’aide sous les noms du menu */
#site-nav > a, #site-nav .nav-item > a { flex-direction: column; align-items: flex-start; justify-content: center; line-height: 1.15; }
#site-nav .nav-sub { font-size: 0.72rem; font-weight: 400; color: var(--muted); }
#site-nav a.is-current .nav-sub { color: inherit; opacity: 0.85; }
#site-nav .nav-mine .nav-sub { max-width: 8.5rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@media (max-width: 800px) {
    .lang-switch .lang-name { display: none; }
    #site-nav > a, #site-nav .nav-item > a { flex-direction: row; align-items: baseline; gap: 0.45rem; }
}
/* Cibles tactiles : au moins 24 px pour les liens isolés et les puces */
.chip, .breadcrumb a, .foot-map a, .theme-row a { min-height: 24px; display: inline-flex; align-items: center; }
.foot-map a { padding: 0.15rem 0; }
/* Annuaire sur mobile : présentation en lignes par défaut */
@media (max-width: 800px) {
    .collection.cartes.auto-view { display: flex; flex-direction: column; gap: 0.5rem; }
    .collection.cartes.auto-view > .card { padding: 0.7rem 0.85rem; }
    .collection.cartes.auto-view > .card h2 { font-size: 1.05rem; margin: 0; }
    .collection.cartes.auto-view .summary { -webkit-line-clamp: 2; line-clamp: 2; }
}
.site-search { display: inline-flex; align-items: center; gap: 0.25rem; margin-left: auto; }
.site-search input { width: 11rem; min-height: 2rem; padding: 0.2rem 0.6rem; border: 1px solid var(--line); border-radius: 999px; background: var(--card); color: var(--ink); }
.site-search button { min-height: 2rem; min-width: 2rem; padding: 0.2rem 0.45rem; border-radius: 999px; }
/* Bouton jour / nuit : on montre celui qui mène à l’autre apparence. */
.theme-switch { display: inline-flex; margin: 0; }
.theme-switch button { min-height: 2rem; min-width: 2rem; padding: 0.2rem 0.45rem; border-radius: 999px; display: inline-flex; align-items: center; justify-content: center; }
.theme-switch .theme-to-light { display: none; }
.search-results { list-style: none; padding: 0; }
.search-results li { padding: 0.45rem 0; border-bottom: 1px solid var(--line); }
@media (max-width: 800px) {
    .site-search { order: 3; flex-basis: 100%; }
    .site-search input { flex: 1; width: auto; }
}
/* Inscription : champs d’organisation seulement pour une entreprise ou un acteur du territoire */
@supports selector(:has(*)) {
    .register-form .org-fields { display: none; }
    .register-form:has(input[name="kind"][value="company"]:checked) .org-fields,
    .register-form:has(input[name="roles[]"][value="territory"]:checked) .org-fields { display: block; }
}
.admin-counters a { display: block; background: var(--card); border: 1px solid var(--line); border-radius: 1rem; padding: 0.7rem 1rem; text-decoration: none; color: var(--ink); }
.admin-counters strong { display: block; font-size: 1.5rem; color: var(--forest); }
.danger-zone { margin-top: 1rem; border-top: 1px solid var(--line); padding-top: 0.6rem; }
.danger-zone summary { color: var(--danger); cursor: pointer; }
@supports selector(:has(*)) {
    .contribute-form .company-fields { display: none; }
    .contribute-form:has(input[name="donor_type"][value="company"]:checked) .company-fields { display: block; }
}
.month-bars td meter { width: 100%; }
.entry-body table { display: block; max-width: 100%; overflow-x: auto; border-collapse: collapse; }
.entry-body th, .entry-body td { border: 1px solid var(--line); padding: 0.35rem 0.5rem; vertical-align: top; }
.entry-body li > input[type="checkbox"] { margin-right: 0.4rem; }
/* Débordements horizontaux sur mobile (recette du 8 octobre 2026) */
body { overflow-wrap: break-word; }
input[type="file"] { max-width: 100%; }
.inline-form { flex-wrap: wrap; max-width: 100%; }
.error-page { max-width: 40rem; margin: 4rem auto; padding: 0 1.25rem; }
/* Formulaires dans une carte (revue, commentaires, partage, VSME, pièces) : même mise en forme que form.card */
.card form:not(.inline-form) label:not(.check) { display: flex; flex-direction: column; gap: 0.35rem; }
.card form textarea, .card form input:not([type="checkbox"]):not([type="radio"]):not([type="file"]), .card form select {
    box-sizing: border-box; width: 100%; max-width: 40rem;
    border: 1px solid var(--line); border-radius: 0.7rem; background: var(--spore); color: var(--ink); padding: 0.5rem 0.7rem;
}
.card form textarea { min-height: 5rem; resize: vertical; }
.card form > button, .card details form > button { margin-top: 0.5rem; }
label.check { display: flex; flex-direction: row; align-items: center; gap: 0.45rem; }
.inline-form label { display: inline-flex; flex-direction: column; }
@media (max-width: 800px) {
    .roadmap-tools { display: flex; flex-direction: column; align-items: stretch; gap: 0.5rem; }
    .roadmap-tools .button, .roadmap-tools button { text-align: center; width: 100%; box-sizing: border-box; }
    .roadmap-tools .view-toggle { display: flex; gap: 0.5rem; }
}
.inline-form label.check { flex-direction: row; align-items: center; gap: 0.35rem; }
.nav-item:has(> .nav-contribute) details.sub .menu { left: auto; right: 0; transform: none; }

/* Éditeur riche : barre d’outils classique, zone éditable au rendu final. */
.editor.is-rich .editor-bar {
    gap: 0.15rem 0.35rem;
    align-items: center;
    padding: 0.3rem 0.4rem;
    margin: 0;
    background: var(--paper);
    border: 1px solid var(--line);
    border-bottom: 0;
    border-radius: 0.6rem 0.6rem 0 0;
    position: sticky;
    top: 0;
    z-index: 2;
}
.editor .tool-group { display: inline-flex; align-items: center; gap: 0.1rem; padding-right: 0.35rem; border-right: 1px solid var(--line); }
.editor .tool-group:last-child, .editor .tool-end { border-right: 0; }
.editor .tool-end { margin-left: auto; }
.editor.is-rich .editor-bar .tool {
    border: 1px solid transparent;
    border-radius: 0.35rem;
    padding: 0.2rem 0.35rem;
    min-width: 2rem;
    min-height: 2rem;
    justify-content: center;
    color: var(--ink, #1f2a22);
    background: transparent;
    font-size: 0.95rem;
    line-height: 1;
}
.editor.is-rich .editor-bar .tool.small { font-size: 0.8rem; min-width: 0; }
.editor.is-rich .editor-bar .tool:hover, .editor.is-rich .editor-bar .tool:focus-visible { background: var(--sage, #e3ead9); border-color: var(--line); }
.editor.is-rich .editor-bar select { padding: 0.2rem 0.4rem; font-size: 0.9rem; min-height: 2rem; width: auto; }
.editor.is-source .editor-bar .tool:not([data-mode]), .editor.is-source .editor-bar select { opacity: 0.4; pointer-events: none; }
.editor-label { margin: 0.6rem 0 0.25rem; font-weight: 600; }
.rich-area {
    min-height: 14rem;
    overflow: auto;
    padding: 0.8rem 1rem;
    background: var(--field);
    border: 1px solid var(--line);
    border-radius: 0 0 0.6rem 0.6rem;
    outline: none;
}
.rich-area { max-height: 60vh; }
.rich-area:focus { border-color: var(--forest); box-shadow: 0 0 0 2px rgba(31, 77, 52, 0.18); }
.rich-area table { border-collapse: collapse; width: 100%; }
.rich-area th, .rich-area td { border: 1px solid var(--line); padding: 0.3rem 0.5rem; min-width: 3rem; vertical-align: top; }
.rich-area img { max-width: 100%; height: auto; }
.modal .editor { max-width: 100%; }
.modal.editor-modal { width: min(64rem, calc(100vw - 2rem)); }
.modal form.card, .editor, .editor .rich-area { min-width: 0; max-width: 100%; }
.rich-area { overflow-wrap: anywhere; }
.rich-area table { display: block; overflow-x: auto; }
.editor.is-rich .editor-label { margin-top: 0.6rem; }
.js .js-hidden { display: none; }
.role-checks { display: flex; flex-wrap: wrap; gap: 0.2rem 0.8rem; }
input.narrow { width: 6rem; }

/* Espace de travail d’une feuille : liens, champs côte à côte, cadrage */
.workspace-links { display: flex; flex-wrap: wrap; gap: 0.25rem 1rem; margin: 0 0 1rem; font-size: 0.95rem; }
.field-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(10rem, 1fr)); gap: 0 1rem; }
.framing fieldset { margin: 0 0 1rem; }
.framing .help { margin: 0.1rem 0 0.4rem; }
.glossary dt { font-weight: 600; margin-top: 0.6rem; }
.glossary dd { margin: 0.1rem 0 0; }
td select { min-width: 8.5rem; }
.narrow-desk { max-width: 42rem; }

/* En-tête et onglets d’une feuille de route */
.roadmap-head { margin: 0 0 1.2rem; }
.roadmap-title { font-family: Georgia, "Iowan Old Style", Palatino, serif; font-size: 1.15rem; font-weight: 700; margin: 0.2rem 0 0.7rem; display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; }
.tabs { display: flex; flex-wrap: nowrap; gap: 0.25rem; overflow-x: auto; border-bottom: 1px solid var(--line); scrollbar-width: thin; }
.tabs a { flex: 0 0 auto; display: inline-flex; align-items: center; gap: 0.4rem; padding: 0.55rem 0.85rem; border: 1px solid transparent; border-bottom: 0; border-radius: 0.7rem 0.7rem 0 0; color: var(--ink); text-decoration: none; font-weight: 600; font-size: 0.95rem; }
.tabs a:hover { background: var(--card); }
.tabs a[aria-current="page"] { background: var(--card); border-color: var(--line); margin-bottom: -1px; }
.tabs .step { display: inline-grid; place-items: center; width: 1.35rem; height: 1.35rem; border-radius: 50%; background: var(--sage); color: var(--forest); font-size: 0.75rem; }
.chip.warn { border-color: #c98a64; color: var(--warn-ink); }
.chip.visibility-listed { background: var(--sage); }
.section-bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.6rem; margin: 0 0 1rem; }
.section-bar h1, .section-bar h2 { margin: 0; }
.danger-zone { border-top: 1px solid var(--line); margin-top: 1rem; padding-top: 0.8rem; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.5rem; }
.danger-zone p { margin: 0; }
.roadmap-action .section-bar { margin-bottom: 0.3rem; }
.roadmap-action .section-bar h3 { margin: 0; }
.grid.two { display: grid; grid-template-columns: repeat(auto-fit, minmax(16rem, 1fr)); gap: 1rem; margin: 0 0 1rem; }
.grid.two > .card { margin: 0; }
.theme-scores { list-style: none; padding: 0; margin: 0 0 1rem; display: grid; gap: 0.45rem; }
.theme-scores li { display: grid; grid-template-columns: minmax(9rem, 14rem) 1fr 6.5rem; align-items: center; gap: 0.7rem; }
.theme-scores meter { width: 100%; height: 0.9rem; }
.theme-value { font-variant-numeric: tabular-nums; text-align: right; }
.diag-level { display: flex; flex-wrap: wrap; align-items: center; gap: 0.6rem; font-size: 1.1rem; margin-bottom: 0.2rem; }
.chip.level-exemplary, .chip.level-structured { background: var(--sage); }
.history-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.5rem; border-bottom: 1px solid var(--line); padding: 0.4rem 0; }
.history-row p { margin: 0; }
.diag-theme { margin: 0 0 1.2rem; }
.diag-theme > summary { font-weight: 700; font-size: 1.05rem; cursor: pointer; padding: 0.4rem 0; }
.diag-scale { display: flex; flex-wrap: wrap; gap: 0.3rem 1rem; }
@media (max-width: 640px) {
    .theme-scores li { grid-template-columns: 1fr 4.5rem; }
    .theme-scores meter { grid-column: 1 / -1; grid-row: 2; }
}
.document { border-bottom: 1px solid var(--line); padding: 0.6rem 0; }
.document:last-child { border-bottom: 0; }
.document h3 { margin: 0; font-size: 1.05rem; }
.document .meta { margin: 0.2rem 0; }
.refs-list { padding-left: 1.1rem; }
.refs-list li { margin: 0.3rem 0; }
.choice-list { border: 0; padding: 0; margin: 0 0 0.8rem; display: grid; gap: 0.5rem; }
.choice { display: flex; gap: 0.6rem; align-items: flex-start; border: 1px solid var(--line); border-radius: 0.8rem; padding: 0.6rem 0.8rem; cursor: pointer; }
.choice:has(input:checked) { border-color: var(--forest); background: var(--sage); }
.choice input { margin-top: 0.3rem; }
textarea { width: 100%; box-sizing: border-box; }
.editor.compact .rich-area { min-height: 6.5rem; max-height: 40vh; }
.framing-group { margin: 0 0 0.9rem; }
.framing-group > summary { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 0.5rem; cursor: pointer; font-weight: 700; font-size: 1.1rem; padding: 0.2rem 0; }
.framing-group > summary .chip { font-weight: 600; font-size: 0.85rem; }
.framing-field { margin: 1rem 0 1.4rem; }
.framing-field .help { margin: 0.1rem 0 0.4rem; }
.framing-field .entry-body { background: var(--card); border: 1px solid var(--line); border-radius: 0.6rem; padding: 0.6rem 0.9rem; }
.save-bar { position: sticky; bottom: 0; z-index: 2; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.6rem; background: var(--spore); border-top: 1px solid var(--line); padding: 0.7rem 0; margin-top: 1rem; }
.indicators { width: 100%; border-collapse: collapse; }
.indicators th, .indicators td { text-align: left; vertical-align: top; padding: 0.45rem 0.4rem; border-bottom: 1px solid var(--line); }
.indicators input { width: 100%; box-sizing: border-box; }
@media (max-width: 760px) {
    .indicators thead { display: none; }
    .indicators tr { display: grid; gap: 0.3rem; padding: 0.5rem 0; border-bottom: 1px solid var(--line); }
    .indicators td { border: 0; padding: 0.1rem 0; }
}
.account-tabs { margin: 0 0 1.2rem; }
.journey { list-style: none; padding: 0; margin: 0.6rem 0 1rem; display: grid; grid-template-columns: repeat(auto-fit, minmax(12rem, 1fr)); gap: 0.6rem; }
.journey li { border: 1px solid var(--line); border-radius: 0.8rem; padding: 0.6rem 0.8rem; display: flex; flex-direction: column; gap: 0.2rem; background: var(--spore); }
.journey li.is-done { border-color: var(--forest); background: var(--sage); }
.journey li.is-done strong::after { content: " ✓"; }
.choice input { width: auto; flex: 0 0 auto; }
form.diag-form.full { max-width: none; }
.card form:not(.inline-form) label.choice, form.card label.choice, label.choice { display: flex; flex-direction: row; gap: 0.6rem; }

/* Actions sur une ligne ; détails en fenêtre */
.action-row { display: flex; align-items: center; gap: 0.5rem; border-top: 1px solid var(--line); padding: 0.35rem 0; }
.action-row:first-of-type { border-top: 0; }
.action-open { flex: 1 1 auto; min-width: 0; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.3rem 0.8rem; text-align: left; background: transparent; border: 0; border-radius: 0.6rem; padding: 0.45rem 0.6rem; color: var(--ink); font: inherit; cursor: pointer; }
.action-open:hover, .action-open:focus-visible { background: var(--spore); }
.action-title { font-weight: 600; }
.action-meta { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 0.25rem 0.7rem; font-size: 0.88rem; color: var(--muted); }
.action-row.status-done .action-title { text-decoration: line-through; text-decoration-color: var(--line); }
.action-view .actions { margin-top: 1rem; }
.print-only { display: none; }
@media print {
    .print-only { display: block; margin: 0.2rem 0 0.6rem; }
    .action-row { display: block; }
    .action-open { padding: 0; }
}
.member-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(17rem, 1fr)); gap: 1rem; margin: 0 0 1rem; }
.member-card { margin: 0; }
.member-card h2 { font-size: 1.2rem; margin: 0 0 0.2rem; }
.codev-invite summary { cursor: pointer; font-weight: 600; font-size: 0.92rem; }
.member-profile { border: 1px solid var(--line); border-radius: 0.8rem; padding: 0.6rem 0.9rem; margin: 0.8rem 0; }

/* Champs des fenêtres modales hors formulaire (recherche de citation, etc.) : même rendu que les formulaires */
.modal > label { display: flex; flex-direction: column; gap: 0.35rem; margin: 0 0 0.8rem; }
.modal > label input, .modal > label select {
    box-sizing: border-box; width: 100%; border: 1px solid var(--line); border-radius: 0.7rem;
    background: var(--spore); color: var(--ink); padding: 0.55rem 0.7rem;
}
.modal [data-cite-results] { list-style: none; padding: 0; margin: 0 0 0.8rem; max-height: 50vh; overflow: auto; }
.modal [data-cite-results] li { border-bottom: 1px solid var(--line); }
.modal [data-cite-results] button, .modal [data-cite-results] a { display: block; width: 100%; text-align: left; }
.diag-form .diag-question { margin: 0 0 0.9rem; }
/* Surplus et partenaires */
th.num, td.num { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.chip.small { font-size: 0.75rem; min-height: 0; padding: 0.05rem 0.45rem; }
.partner-table tr.is-partner td:first-child { border-left: 3px solid var(--forest); }
.partner-table .inline-form, .allocation-table .inline-form { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 0.4rem; }
.surplus-page .stats dd { font-size: 1.3rem; }
.partner-table button, .allocation-table button { white-space: nowrap; }
.toast[hidden], .toast [hidden] { display: none; }
.toast-count { font-weight: 700; color: var(--forest); }
.toast-more { display: flex; align-items: center; justify-content: space-between; gap: 0.6rem; padding-block: 0.4rem; }
.toast-more p { margin: 0; font-size: 0.85rem; }
/* Propositions de l’assistant */
.suggest-list { list-style: none; padding: 0; margin: 0.8rem 0; display: grid; gap: 0.6rem; }
.suggest-list > li { border: 1px solid var(--line); border-radius: 0.8rem; padding: 0.6rem 0.8rem; background: var(--spore, transparent); }
.suggest-list > li p { margin: 0.3rem 0 0; }
.suggest-list .prose { margin: 0.3rem 0 0 1.6rem; }
.suggestions .section-bar form { margin: 0; }
.field-row.three { grid-template-columns: repeat(auto-fit, minmax(8rem, 1fr)); }
.next-step { border-left: 4px solid var(--forest); }
/* Visites guidées : bouton « ? », menu, projecteur et bulle */
.tour-dock { position: fixed; left: 1rem; bottom: 1rem; z-index: 45; }
.tour-launch { width: 2.75rem; height: 2.75rem; min-height: 0; padding: 0; border-radius: 50%; font-size: 1.2rem; font-weight: 700; display: grid; place-items: center; box-shadow: 0 0.3rem 0.9rem rgba(28, 40, 34, 0.25); }
.tour-menu { position: fixed; inset: auto auto 4.3rem 1rem; margin: 0; padding: 0.8rem; width: min(18rem, calc(100vw - 2rem)); border: 1px solid var(--line); border-radius: 1rem; background: var(--card); color: var(--ink); box-shadow: 0 0.4rem 1.2rem rgba(28, 40, 34, 0.2); }
.tour-menu:popover-open { display: grid; gap: 0.45rem; }
.tour-menu-title { margin: 0 0 0.2rem; font-weight: 700; }
.tour-menu button { justify-self: stretch; text-align: left; }
.tour-backdrop { position: fixed; inset: 0; z-index: 60; background: rgba(20, 30, 25, 0.45); }
.tour-spot { position: absolute; z-index: 61; border-radius: 0.9rem; outline: 3px solid var(--lichen); box-shadow: 0 0 0 9999px rgba(20, 30, 25, 0.45); pointer-events: none; transition: top 0.25s, left 0.25s, width 0.25s, height 0.25s; }
.tour-card { position: absolute; z-index: 62; box-sizing: border-box; width: min(22rem, calc(100vw - 1rem)); padding: 1rem 1.1rem; border-radius: 1rem; background: var(--card); color: var(--ink); border: 1px solid var(--line); box-shadow: 0 0.6rem 1.6rem rgba(20, 30, 25, 0.3); }
.tour-card.centered { position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%); }
.tour-title { margin: 0 0 0.4rem; font-size: 1.15rem; }
.tour-text { margin: 0 0 0.9rem; }
.tour-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.5rem; }
.tour-count { font-size: 0.8rem; color: var(--muted); }
.tour-actions { display: flex; flex-wrap: wrap; gap: 0.4rem; }
@media (prefers-reduced-motion: reduce) { .tour-spot { transition: none; } }
@media print { .tour-dock, .tour-card, .tour-spot, .tour-backdrop { display: none !important; } }
/* Guides d’introduction */
.guide { display: grid; gap: 1rem; }
.guide-toc { display: block; }
.guide-toc ol { margin: 0.3rem 0 0; padding-left: 1.3rem; columns: 2 16rem; }
.guide-toc h2 { margin: 0; }
.guide-section h2 { margin-top: 0; }
.guide-section ul { margin: 0.4rem 0 0.6rem; padding-left: 1.2rem; }
.touring .toasts, .touring .scroll-dock { visibility: hidden; }
/* Double authentification */
.tfa-form { max-width: 26rem; }

/* Administration d’un compte : rattachements */
.admin-link-row { display: flex; flex-wrap: wrap; align-items: center; gap: 0.4rem 0.8rem; padding: 0.4rem 0; border-bottom: 1px solid var(--line); }
.admin-link-row > a, .admin-link-row > strong { font-weight: 600; margin-right: auto; }
.admin-link-add { margin-top: 0.8rem; }
.admin-link-row .inline-form { flex-wrap: nowrap; align-items: center; }
.admin-link-row select { width: auto; min-width: 9rem; }
.danger-zone-card { border-color: var(--danger); }

/* Doublons de structures : avertissement sur une demande de compte, liste dans l’administration */
.duplicate-warning { border-left: 4px solid var(--danger); padding: 0.4rem 0 0.4rem 0.75rem; margin: 0.6rem 0; }
.duplicate-warning ul, .duplicate-group ul { margin: 0.3rem 0 0; padding-left: 1.1rem; }
.duplicate-warning p { margin: 0; }
.danger-text { color: var(--danger); }
.duplicate-help { border-left: 4px solid var(--bark); padding-left: 0.6rem; }
.code-links { display: flex; flex-wrap: wrap; gap: 1rem; justify-content: center; align-items: center; margin-top: 1rem; }

/* Administration de l’annuaire : champs côte à côte, photos des compagnons. */
.field-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 11rem), 1fr)); gap: 0 1rem; }
.admin-photos { display: flex; flex-wrap: wrap; gap: 0.6rem 1.2rem; }
.admin-photos img { border-radius: 0.5rem; object-fit: cover; }
.admin-anchors { display: flex; flex-wrap: wrap; gap: 0.4rem 1rem; margin: 0 0 1rem; font-size: 0.95rem; }
.admin-link-row.suggestion { background: var(--feature-bg); border-radius: 0.6rem; padding: 0.45rem 0.7rem; border-bottom: 0; margin: 0.35rem 0; }
.admin-link-add.inline-form { flex-wrap: wrap; align-items: flex-end; gap: 0.5rem 0.8rem; }
.member-row { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: center; }
.member-row .who { display: flex; flex-direction: column; min-width: 0; overflow-wrap: anywhere; }
@media (max-width: 34rem) { .member-row { grid-template-columns: 1fr; } }
/* Onglets de page (tabs.js) et listes compactes en fenêtre */
.page-tabs { margin: 1.2rem 0 0; }
.tabs a[aria-selected="true"] { background: var(--card); border-color: var(--line); margin-bottom: -1px; }
.tabs a[aria-selected="false"] { color: var(--muted); }
.tab-count { display: inline-grid; place-items: center; min-width: 1.35rem; height: 1.35rem; padding: 0 0.3rem; border-radius: 0.7rem; background: var(--sage); color: var(--forest); font-size: 0.75rem; }
[role="tabpanel"] { margin-top: 0; }
[role="tabpanel"][hidden] { display: none !important; }
.card[role="tabpanel"], form[role="tabpanel"] { border-top-left-radius: 0; }
.tab-block[role="tabpanel"] { padding-top: 0.8rem; }
.tab-block[role="tabpanel"] > h2:first-child { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
table.compact th, table.compact td { padding: 0.3rem 0.45rem; font-size: 0.92rem; vertical-align: middle; }
table.compact td:last-child { text-align: right; white-space: nowrap; }
table.compact td form { margin: 0; }
.modal .table-wrap { margin: 0.6rem 0 1rem; max-height: 60vh; overflow: auto; }
.subsection { margin-top: 1.2rem; padding-top: 0.8rem; border-top: 1px solid var(--line); }
.subsection > h3 { margin: 0 0 0.4rem; font-size: 1rem; }

/* ===== Mode sombre =====
 * Deux entrées, mêmes règles : le choix « sombre » du bouton jour / nuit (cookie → data-theme sur <html>),
 * ou le réglage du système quand la personne n’a pas choisi « clair ».
 * Les couleurs passent par les variables ; les rares règles propres au sombre vont dans les DEUX blocs
 * (un test vérifie qu’ils restent identiques). :where() garde la spécificité des règles claires.
 */
:root[data-theme="light"] { color-scheme: light; }
:root[data-theme="dark"] { color-scheme: dark; --ink: #e7f0e4; --spore: #121814; --sage: #24332a; --card: #1b2420; --line: #314036; --muted: #b7c7b8; --lichen: #d6e27a; --forest: #d5e4d2; --moss: #d5e4d2; --bark: #d9a87a; --on-forest: #121814; --forest-hover: #bfd3bb; --danger: #e59a88; --danger-bg: #3a2420; --added: #a7d7a0; --warn-ink: #f0b48a; --warn-bg: #33281d; --accent: #d6e27a; --feature-bg: #1a2820; --paper: #202b26; --field: #141c18; --map-bg: #1a2629; }
:where(:root[data-theme="dark"]) .donut { filter: invert(1) hue-rotate(180deg); mix-blend-mode: screen; }
:where(:root[data-theme="dark"]) .thot img { mix-blend-mode: normal; }
:where(:root[data-theme="dark"]) .thot .logo-light { display: none; }
:where(:root[data-theme="dark"]) .thot .logo-dark { display: block; }
:where(:root[data-theme="dark"]) .theme-switch .theme-to-dark { display: none; }
:where(:root[data-theme="dark"]) .theme-switch .theme-to-light { display: inline-flex; }
:where(:root[data-theme="dark"]) .button.ghost, :where(:root[data-theme="dark"]) button.ghost { color: var(--ink); }
:where(:root[data-theme="dark"]) nav.pager [aria-current="page"] { color: var(--spore); }
@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) { color-scheme: dark; --ink: #e7f0e4; --spore: #121814; --sage: #24332a; --card: #1b2420; --line: #314036; --muted: #b7c7b8; --lichen: #d6e27a; --forest: #d5e4d2; --moss: #d5e4d2; --bark: #d9a87a; --on-forest: #121814; --forest-hover: #bfd3bb; --danger: #e59a88; --danger-bg: #3a2420; --added: #a7d7a0; --warn-ink: #f0b48a; --warn-bg: #33281d; --accent: #d6e27a; --feature-bg: #1a2820; --paper: #202b26; --field: #141c18; --map-bg: #1a2629; }
    :where(:root:not([data-theme="light"])) .donut { filter: invert(1) hue-rotate(180deg); mix-blend-mode: screen; }
    :where(:root:not([data-theme="light"])) .thot img { mix-blend-mode: normal; }
    :where(:root:not([data-theme="light"])) .thot .logo-light { display: none; }
    :where(:root:not([data-theme="light"])) .thot .logo-dark { display: block; }
    :where(:root:not([data-theme="light"])) .theme-switch .theme-to-dark { display: none; }
    :where(:root:not([data-theme="light"])) .theme-switch .theme-to-light { display: inline-flex; }
    :where(:root:not([data-theme="light"])) .button.ghost, :where(:root:not([data-theme="light"])) button.ghost { color: var(--ink); }
    :where(:root:not([data-theme="light"])) nav.pager [aria-current="page"] { color: var(--spore); }
}
