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

.logo-mitarys-apropos {
    display: flex;
    justify-content: center;
    padding: 72px 0 24px;
}

.mitarys-wordmark {
    font-family: 'Space Grotesk', 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    font-size: clamp(22px, 6vw, 40px);
    font-weight: 300;
    letter-spacing: 0.25em;
    margin-right: -0.25em;
    color: var(--text-primary);
    line-height: 1;
    white-space:nowrap;
}

.apropos-layout {
    max-width: 1080px;
    margin: 0 auto;
    padding: 32px 40px 120px;
    display: grid;
    grid-template-columns: 220px minmax(0, 700px);
    gap: 64px;
    align-items: start;
}


/* ---- Sidebar / sommaire ---- */

.apropos-sidebar {
    position: sticky;
    top: 96px;
}

.apropos-toc-label {
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-secondary);
    margin: 0 0 14px 0;
}

.apropos-toc {
    display: flex;
    flex-direction: column;
    gap: 2px;
    border-left: 1px solid var(--border);
}

.apropos-toc-link {
    display: block;
    padding: 7px 0 7px 16px;
    margin-left: -1px;
    border-left: 2px solid transparent;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-secondary);
    text-decoration: none;
    transition: color 0.15s ease, border-color 0.15s ease;
}

.apropos-toc-link:hover {
    color: #5e39c2;
}

.apropos-toc-link.is-active {
    color: #5e39c2;
    border-left-color: #5e39c2;
    font-weight: 600;
}

/* ---- Contenu ---- */

.apropos-section {
    scroll-margin-top: 100px;
    padding-bottom: 56px;
    margin-bottom: 56px;
    border-bottom: 1px solid var(--border);
}

.apropos-section:last-of-type {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.apropos-section h2 {
    font-size: 26px;
    font-weight: 700;
    letter-spacing: -0.01em;
    color: var(--text-primary);
    margin: 0 0 24px 0;
}

.apropos-section p {
    font-size: 16px;
    line-height: 1.75;
    color: var(--text-primary);
    margin: 0 0 20px 0;
}

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

.apropos-principles {
    list-style: none;
    margin: 24px 0 0 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.apropos-principles li {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.apropos-principles strong {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-primary);
}

.apropos-principles span {
    font-size: 15px;
    line-height: 1.7;
    color: var(--text-secondary);
}

/* ---- Bouton flottant "sommaire" (mobile uniquement) ---- */

.apropos-toc-fab {
    display: none;
}

.apropos-toc-overlay {
    display: none;
}

/* ---- Mobile : sidebar remplacée par un bouton flottant + panneau ---- */

@media (max-width: 900px) {
    .logo-mitarys-apropos {
        padding: 40px 0 8px;
    }

    .mitarys-wordmark {
        font-size: clamp(20px, 7vw, 34px);
        /* espacement un peu réduit sur mobile pour éviter tout débordement */
        letter-spacing: 0.18em;
        margin-right: -0.18em;
    }

    .apropos-layout {
        grid-template-columns: 1fr;
        padding: 24px 20px 80px;
        gap: 0;
    }

    .apropos-sidebar {
        display: none;
    }

    .apropos-section {
        scroll-margin-top: 88px;
        padding-bottom: 40px;
        margin-bottom: 40px;
    }

    .apropos-section h2 {
        font-size: 22px;
    }

    .apropos-section p {
        font-size: 15px;
    }

    /* Bouton flottant, façon Wikipédia mobile */
    .apropos-toc-fab {
        display: flex;
        align-items: center;
        justify-content: center;
        position: fixed;
        right: 20px;
        bottom: 24px;
        width: 52px;
        height: 52px;
        border-radius: 14px;
        background: var(--text-primary);
        color: white;
        border: none;
        box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
        z-index: 90;
        cursor: pointer;
    }

    .apropos-toc-fab .icon-lucide {
        width: 22px;
        height: 22px;
    }

    /* Overlay + panneau (bottom sheet) */
    .apropos-toc-overlay {
        display: block;
        position: fixed;
        inset: 0;
        background: rgba(0, 0, 0, 0.4);
        opacity: 0;
        visibility: hidden;
        transition: opacity 0.25s ease;
        z-index: 150;
    }

    .apropos-toc-overlay.is-open {
        opacity: 1;
        visibility: visible;
    }

    .apropos-toc-panel {
        position: absolute;
        left: 0;
        right: 0;
        bottom: 0;
        max-height: 70vh;
        overflow-y: auto;
        background: var(--surface);
        border-radius: 20px 20px 0 0;
        padding: 20px 24px calc(20px + env(safe-area-inset-bottom, 0px));
        transform: translateY(100%);
        transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    }

    .apropos-toc-overlay.is-open .apropos-toc-panel {
        transform: translateY(0);
    }

    .apropos-toc-panel-header {
        display: flex;
        align-items: center;
        justify-content: space-between;
        margin-bottom: 12px;
    }

    .apropos-toc-panel-header .apropos-toc-label {
        margin: 0;
    }

    .apropos-toc-close {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 32px;
        height: 32px;
        border-radius: 50%;
        border: none;
        background: var(--background);
        color: var(--text-primary);
        cursor: pointer;
    }

    .apropos-toc-close .icon-lucide {
        width: 16px;
        height: 16px;
    }

    .apropos-toc-panel .apropos-toc-link {
        padding: 12px 0;
        border-left: none;
        margin-left: 0;
        border-bottom: 1px solid var(--border);
        font-size: 15px;
    }

    .apropos-toc-panel .apropos-toc-link:last-child {
        border-bottom: none;
    }

    .apropos-toc-panel .apropos-toc-link.is-active {
        color: #5e39c2;
    }
}
