/* ContreAtthack — feuille de style principale
   Style sobre, sérieux, lisible. Palette « ardoise + accent cyan ». */

/* Polices auto-hébergées (Inter, IBM Plex Mono) — sous-ensembles latin et
   latin-ext uniquement. Rapatriées depuis Google Fonts pour ne dépendre
   d'aucun tiers et ne divulguer aucune adresse IP visiteur (cohérent avec
   l'objet du site et le RGPD/nLPD). Inter est une police variable : un seul
   fichier couvre les graisses 400 à 700. */
@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 400 700;
    font-display: swap;
    src: url('../fonts/inter-latin.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
    font-family: 'Inter';
    font-style: normal;
    font-weight: 400 700;
    font-display: swap;
    src: url('../fonts/inter-latinext.woff2') format('woff2');
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
    font-family: 'IBM Plex Mono';
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url('../fonts/ibm-plex-mono-400-latin.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
    font-family: 'IBM Plex Mono';
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url('../fonts/ibm-plex-mono-400-latinext.woff2') format('woff2');
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
    font-family: 'IBM Plex Mono';
    font-style: normal;
    font-weight: 500;
    font-display: swap;
    src: url('../fonts/ibm-plex-mono-500-latin.woff2') format('woff2');
    unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
    font-family: 'IBM Plex Mono';
    font-style: normal;
    font-weight: 500;
    font-display: swap;
    src: url('../fonts/ibm-plex-mono-500-latinext.woff2') format('woff2');
    unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
    /* Thème clair (par défaut) */
    --bg:        #ffffff;
    --bg-alt:    #f4f7fb;
    --surface:   #ffffff;
    --surface-2: #eef2f7;
    --border:    #e2e8f0;
    --text:      #0f172a;
    --text-soft: #475569;
    --text-mut:  #7b8798;
    --accent:    #0d9488;
    --accent-2:  #0284c7;
    --accent-ink:#ffffff;
    --danger:    #dc2626;
    --header-bg: rgba(255, 255, 255, 0.85);
    --accent-glow-1: rgba(13, 148, 136, 0.10);
    --accent-glow-2: rgba(2, 132, 199, 0.08);

    --radius:    12px;
    --radius-sm: 8px;
    --maxw:      1120px;
    --font:      'Inter', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
    --mono:      'IBM Plex Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
}

[data-theme="dark"] {
    --bg:        #0d1117;
    --bg-alt:    #111823;
    --surface:   #161d29;
    --surface-2: #1c2534;
    --border:    #263043;
    --text:      #e6edf3;
    --text-soft: #9aa7b8;
    --text-mut:  #6b7787;
    --accent:    #2dd4bf;
    --accent-2:  #38bdf8;
    --accent-ink:#05201c;
    --danger:    #f87171;
    --header-bg: rgba(13, 17, 23, 0.85);
    --accent-glow-1: rgba(45, 212, 191, 0.10);
    --accent-glow-2: rgba(56, 189, 248, 0.08);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
    margin: 0;
    font-family: var(--font);
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }

.container {
    width: 100%;
    max-width: var(--maxw);
    margin: 0 auto;
    padding: 0 24px;
}

/* ---------- Header ---------- */
.site-header {
    position: sticky;
    top: 0;
    z-index: 20;
    background: var(--header-bg);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border);
}
.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
}
.brand { display: flex; align-items: center; gap: 10px; font-size: 1.15rem; font-weight: 600; }
.brand-mark { color: var(--accent); font-size: 1.2rem; }
.brand-text { letter-spacing: -0.01em; }
.brand-hack { color: var(--accent); font-weight: 700; }
.site-nav { display: flex; align-items: center; gap: 26px; }
.site-nav a { color: var(--text-soft); font-size: 0.95rem; transition: color .15s; }
.site-nav a:hover { color: var(--text); }
/* Section actuellement à l'écran (scrollspy) */
.site-nav a.is-current { color: var(--text); font-weight: 700; }

.theme-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 999px;
    border: 1px solid var(--border);
    background: var(--surface-2);
    cursor: pointer;
    font-size: 1rem;
    line-height: 1;
    padding: 0;
    transition: border-color .15s, background .15s;
}
.theme-toggle:hover { border-color: var(--accent); }
.theme-icon { display: none; }
.theme-icon-dark { display: inline; }               /* thème clair : proposer le sombre */
[data-theme="dark"] .theme-icon-dark { display: none; }
[data-theme="dark"] .theme-icon-light { display: inline; }

/* ---------- Footer ---------- */
.footer-grid {
    display: grid;
    grid-template-columns: 1.6fr 1fr 1.2fr 1fr;
    gap: 40px;
}
.footer-col-title {
    font-size: 0.76rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-mut);
    font-weight: 700;
    margin: 0 0 14px;
}
.footer-links { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 9px; }
.footer-links li { color: var(--text-soft); font-size: 0.9rem; }
.footer-links a { color: var(--text-soft); transition: color .15s; }
.footer-links a:hover { color: var(--accent); }
.footer-note { color: var(--text-mut); font-size: 0.85rem; margin: 14px 0 0; }

.footer-social a { display: inline-flex; align-items: center; gap: 9px; }
.social-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border-radius: 6px;
    border: 1px solid var(--border);
    background: var(--surface);
    color: var(--accent);
    font-weight: 700;
    font-size: 0.75rem;
    flex-shrink: 0;
}
.footer-social a:hover .social-mark { border-color: var(--accent); }

.footer-bottom {
    margin-top: 36px;
    padding-top: 20px;
    border-top: 1px solid var(--border);
}
.footer-bottom p { margin: 0; color: var(--text-mut); font-size: 0.82rem; }

/* ---------- Hero ---------- */
.hero {
    padding: 96px 0 72px;
    background:
        radial-gradient(1000px 400px at 15% -10%, rgba(45, 212, 191, 0.10), transparent 60%),
        radial-gradient(800px 400px at 95% 0%, rgba(56, 189, 248, 0.08), transparent 55%);
    border-bottom: 1px solid var(--border);
}
.hero-brand {
    font-size: clamp(2.4rem, 6vw, 4rem);
    line-height: 1.05;
    margin: 0 0 10px;
    letter-spacing: -0.02em;
    font-weight: 700;
}
.hero-brand .brand-hack { color: var(--accent); }
.hero-subtitle {
    font-size: clamp(1.15rem, 2.4vw, 1.6rem);
    font-weight: 600;
    color: var(--text);
    margin: 0 0 26px;
    padding-left: 16px;
    border-left: 3px solid var(--accent);
    letter-spacing: -0.01em;
}
.hero-title {
    font-size: clamp(2rem, 5vw, 3.2rem);
    line-height: 1.1;
    margin: 0 0 22px;
    letter-spacing: -0.02em;
    font-weight: 700;
}
.hero-lead {
    max-width: 720px;
    color: var(--text-soft);
    font-size: 1.08rem;
    margin: 0 0 30px;
}
.hero-lead strong { color: var(--text); font-weight: 600; }
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 40px; }

.btn {
    display: inline-flex;
    align-items: center;
    padding: 12px 22px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 0.95rem;
    transition: transform .12s, background .15s, border-color .15s;
    border: 1px solid transparent;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--accent); color: var(--accent-ink); }
.btn-primary:hover { filter: brightness(1.08); }
.btn-ghost { border-color: var(--border); color: var(--text); }
.btn-ghost:hover { border-color: var(--accent); }

.hero-facts { display: flex; gap: 40px; flex-wrap: wrap; list-style: none; padding: 0; margin: 0; }
.hero-facts li { color: var(--text-mut); font-size: 0.92rem; }
.hero-facts strong { display: block; font-size: 1.7rem; color: var(--text); font-weight: 700; }

/* ---------- Sections ---------- */
.section { padding: 72px 0; }
.section-alt { background: var(--bg-alt); border-bottom: 1px solid var(--border); }
.section-title {
    font-size: 1.7rem;
    margin: 0 0 12px;
    letter-spacing: -0.01em;
}
.section-intro { color: var(--text-soft); max-width: 720px; margin: 0 0 36px; }

/* ---------- Piliers ---------- */
.pillars { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; margin-top: 34px; }
.pillar {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 26px;
}
.pillar-num { font-family: var(--mono); color: var(--accent); font-size: 0.9rem; }
.pillar h3 { margin: 12px 0 8px; font-size: 1.1rem; }
.pillar p { margin: 0; color: var(--text-soft); font-size: 0.95rem; }

/* ---------- Grille de chapitres ---------- */
.chapter-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.chapter-card {
    display: flex;
    flex-direction: column;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
    transition: transform .14s, border-color .14s, background .14s;
}
.chapter-card:hover {
    transform: translateY(-3px);
    border-color: var(--accent);
    background: var(--surface-2);
}
.chapter-icon { font-size: 1.8rem; }
.chapter-card-title { margin: 14px 0 8px; font-size: 1.16rem; }
.chapter-card-tagline { margin: 0 0 18px; color: var(--text-soft); font-size: 0.95rem; flex: 1; }
.chapter-card-meta { color: var(--accent); font-size: 0.85rem; font-weight: 600; }

/* ---------- Matrice risques ---------- */
.risk-table-wrap {
    margin-top: 34px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    background: var(--surface);
}
.risk-table { width: 100%; border-collapse: collapse; font-size: 0.94rem; }
.risk-table thead th {
    text-align: left;
    padding: 14px 18px;
    background: var(--surface-2);
    color: var(--text-mut);
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-weight: 600;
    border-bottom: 1px solid var(--border);
}
.risk-table tbody tr { border-bottom: 2px solid var(--border); transition: background .12s; }
.risk-table tbody tr:last-child { border-bottom: none; }
.risk-table tbody tr:hover { background: var(--surface-2); }
.risk-table td { padding: 22px 24px; vertical-align: top; }
.risk-cell { width: 19%; }
.risk-name {
    font-weight: 600;
    color: var(--text);
    display: inline-block;
}
.principle-cell { width: 30%; }
.principle-text { margin: 0 0 14px; color: var(--text-soft); font-size: 0.9rem; }
.impact-list { display: flex; flex-direction: column; gap: 7px; }
.impact-row { display: flex; align-items: center; gap: 10px; }
.impact-label {
    flex: 0 0 84px;
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--text-mut);
    font-weight: 600;
}
.impact-emoji { font-size: 0.95rem; letter-spacing: 1px; line-height: 1; }
.protection-cell { width: 24%; }
.protection-name { display: block; color: var(--text); font-weight: 500; margin-bottom: 10px; }
.protection-domains { display: flex; flex-direction: column; gap: 6px; }
.domain-link { color: var(--accent); font-size: 0.85rem; }
.domain-link:hover { text-decoration: underline; }
.solutions-cell { width: 27%; display: flex; flex-wrap: wrap; gap: 10px; align-content: flex-start; }
.solution-btn {
    display: inline-flex;
    align-items: center;
    padding: 9px 16px;
    border-radius: var(--radius-sm);
    border: 1px solid rgba(45, 212, 191, 0.4);
    background: rgba(45, 212, 191, 0.10);
    color: var(--text);
    font-size: 0.86rem;
    font-weight: 600;
    line-height: 1.2;
    transition: border-color .14s, background .14s, transform .12s;
}
.solution-btn:hover {
    border-color: var(--accent);
    background: rgba(45, 212, 191, 0.22);
    transform: translateY(-1px);
}

/* ---------- Chapter hero ---------- */
.chapter-hero {
    padding: 20px 0;
    background:
        radial-gradient(900px 300px at 10% -30%, var(--accent-glow-2), transparent 60%);
    border-bottom: 1px solid var(--border);
}
.breadcrumb { display: flex; gap: 10px; font-size: 0.85rem; color: var(--text-mut); margin-bottom: 26px; flex-wrap: wrap; }
.breadcrumb a:hover { color: var(--accent); }
.breadcrumb .current { color: var(--text-soft); }
.chapter-hero-heading { display: flex; align-items: center; gap: 16px; margin: 12px 0 10px; }
.chapter-hero-icon { font-size: 2.6rem; line-height: 1; }
.chapter-hero-title { font-size: clamp(1.8rem, 4vw, 2.6rem); margin: 0; letter-spacing: -0.02em; }
.chapter-hero-tagline { color: var(--text-soft); font-size: 1.1rem; margin: 0; max-width: 720px; }

/* Chapitre avec illustration photographique : superposition sombre pour la lisibilité,
   quel que soit le thème et la photo (fond clair ou foncé). */
.chapter-hero.has-illustration {
    position: relative;
    background-size: cover;
    background-position: center;
    border-bottom: none;
    isolation: isolate;
}
.chapter-hero.has-illustration::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(6, 10, 18, 0.72) 0%, rgba(6, 10, 18, 0.55) 55%, rgba(6, 10, 18, 0.82) 100%);
    z-index: -1;
}
.chapter-hero.has-illustration .breadcrumb { color: rgba(255, 255, 255, 0.7); }
.chapter-hero.has-illustration .breadcrumb a { color: rgba(255, 255, 255, 0.85); }
.chapter-hero.has-illustration .breadcrumb a:hover { color: #fff; }
.chapter-hero.has-illustration .breadcrumb .current { color: rgba(255, 255, 255, 0.7); }
.chapter-hero.has-illustration .chapter-hero-title { color: #fff; }
.chapter-hero.has-illustration .chapter-hero-tagline { color: rgba(255, 255, 255, 0.88); }
.illustration-credit {
    margin: 18px 0 0;
    padding: 0 24px;
    text-align: right;
    font-size: 0.72rem;
    color: rgba(255, 255, 255, 0.55);
}

/* ---------- Mentions légales ---------- */
.legal-content { max-width: 760px; }
.legal-content .block-text a { color: var(--accent); }
.legal-content .block-text a:hover { text-decoration: underline; }

/* ---------- Chapter layout ---------- */
.chapter-layout { display: grid; grid-template-columns: 1fr 280px; gap: 44px; align-items: start; }
.block { margin-bottom: 40px; }
.block-title { font-size: 1.35rem; margin: 0 0 16px; letter-spacing: -0.01em; }
.block-text { color: var(--text-soft); font-size: 1.02rem; margin: 0; }

.block-risks {
    background: var(--surface);
    border: 1px solid var(--border);
    border-left: 3px solid var(--danger);
    border-radius: var(--radius);
    padding: 24px 26px;
}
.risk-list { margin: 0; padding-left: 20px; }
.risk-list li { color: var(--text-soft); margin-bottom: 10px; }
.risk-list li::marker { color: var(--danger); }

/* ---------- Tool cards ---------- */
.tool-list { display: flex; flex-direction: column; gap: 18px; margin-top: 24px; }
.tool-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 22px 24px;
    transition: border-color .14s;
}
.tool-card:hover { border-color: var(--accent-2); }
.tool-head { display: flex; align-items: center; gap: 16px; margin-bottom: 14px; }
.tool-logo {
    width: 52px; height: 52px;
    border-radius: 10px;
    background: var(--surface-2);
    border: 1px solid var(--border);
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
    overflow: hidden;
}
.tool-logo img { width: 100%; height: 100%; object-fit: contain; padding: 8px; }
.tool-logo-fallback { font-family: var(--mono); font-weight: 600; color: var(--accent); font-size: 1.05rem; }
.tool-name { margin: 0 0 4px; font-size: 1.16rem; }
.tool-license { font-family: var(--mono); font-size: 0.76rem; color: var(--text-mut); }
.tool-summary { color: var(--text-soft); margin: 0 0 18px; font-size: 0.98rem; }

.tool-links { display: flex; gap: 10px; flex-wrap: wrap; }
.tool-name a { transition: color .14s; }
.tool-name a:hover { color: var(--accent); }
.tool-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    background: var(--surface-2);
    font-size: 0.86rem;
    font-weight: 500;
    color: var(--text-soft);
    transition: border-color .14s, color .14s, background .14s;
}
.tool-link:hover { border-color: var(--accent); color: var(--text); background: var(--surface); }
.tool-link-primary { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); font-weight: 600; }
.tool-link-primary:hover { filter: brightness(1.08); color: var(--accent-ink); }

/* ---------- Page solution ---------- */
.solution-hero {
    padding: 52px 0 44px;
    background:
        linear-gradient(135deg, rgba(45, 212, 191, 0.22), rgba(2, 132, 199, 0.12)),
        radial-gradient(700px 320px at 92% -30%, rgba(45, 212, 191, 0.18), transparent 60%);
    border-top: 3px solid var(--accent);
    border-bottom: 1px solid var(--border);
}
.solution-hero .breadcrumb { color: var(--text-soft); }
.solution-hero .badge-libre { background: var(--surface); }
.solution-head { display: flex; align-items: center; gap: 20px; margin: 24px 0 18px; }
.tool-logo-lg { width: 84px; height: 84px; border-radius: 16px; }
.tool-logo-lg .tool-logo-fallback { font-size: 1.6rem; }
.solution-title { font-size: clamp(1.8rem, 4vw, 2.6rem); margin: 0 0 10px; letter-spacing: -0.02em; }
.solution-badges { display: flex; gap: 10px; flex-wrap: wrap; }
.badge {
    font-family: var(--mono);
    font-size: 0.76rem;
    padding: 5px 11px;
    border-radius: 999px;
    border: 1px solid var(--border);
}
.badge-license { color: var(--text-soft); background: var(--surface); }
.badge-libre { color: var(--accent); border-color: rgba(45, 212, 191, 0.4); background: rgba(45, 212, 191, 0.08); }
.badge-referentiel { color: var(--accent-2); border-color: rgba(2, 132, 199, 0.45); background: rgba(2, 132, 199, 0.10); }

/* ---------- Inventaire des solutions ---------- */
.alpha-index { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 26px; }
.alpha-index a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 32px;
    height: 32px;
    padding: 0 6px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    background: var(--surface);
    color: var(--text-soft);
    font-weight: 700;
    font-size: 0.85rem;
    transition: border-color .14s, color .14s, background .14s;
}
.alpha-index a:hover { border-color: var(--accent); color: var(--accent); background: var(--surface-2); }

.alpha-group { margin-bottom: 36px; scroll-margin-top: 84px; }
.alpha-letter {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--accent);
    margin: 0 0 14px;
    padding-bottom: 8px;
    border-bottom: 2px solid var(--border);
    letter-spacing: 0.05em;
}
.inventory-list { display: flex; flex-direction: column; gap: 10px; }
.inventory-row {
    display: grid;
    grid-template-columns: 52px 1fr 260px;
    gap: 18px;
    align-items: center;
    padding: 14px 18px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface);
    transition: border-color .14s, transform .12s, background .14s;
}
.inventory-row:hover { border-color: var(--accent); transform: translateY(-1px); background: var(--surface-2); }
.inventory-main { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.inventory-name { font-weight: 600; color: var(--text); font-size: 1.02rem; }
.inventory-summary {
    color: var(--text-soft);
    font-size: 0.88rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.inventory-meta { display: flex; flex-direction: column; gap: 6px; align-items: flex-end; }
.inventory-license { font-family: var(--mono); font-size: 0.72rem; color: var(--text-mut); text-align: right; }
.inventory-chapters { display: flex; flex-wrap: wrap; gap: 5px; justify-content: flex-end; }
.inventory-chapter {
    font-size: 0.7rem;
    color: var(--text-soft);
    background: var(--bg-alt);
    border: 1px solid var(--border);
    border-radius: 999px;
    padding: 2px 8px;
    white-space: nowrap;
    max-width: 160px;
    overflow: hidden;
    text-overflow: ellipsis;
}
.solution-lead { color: var(--text-soft); font-size: 1.12rem; max-width: 760px; margin: 0; }

.resource-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-top: 22px; }
.resource-card {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 18px;
    border-radius: var(--radius);
    border: 1px solid var(--border);
    background: var(--surface);
    transition: border-color .14s, transform .12s;
}
.resource-card:hover { border-color: var(--accent); transform: translateY(-2px); }
.resource-label { font-weight: 600; color: var(--text); }
.resource-label::after { content: ' ↗'; color: var(--accent); }
.resource-url { font-family: var(--mono); font-size: 0.8rem; color: var(--text-mut); word-break: break-all; }

.chip-list { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 18px; }
.chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 14px;
    border-radius: 999px;
    border: 1px solid var(--border);
    background: var(--surface);
    color: var(--text-soft);
    font-size: 0.9rem;
    transition: border-color .14s, color .14s;
}
.chip:hover { border-color: var(--accent); color: var(--text); }
.chip-tool { border-color: rgba(13, 148, 136, 0.35); color: var(--text); font-weight: 500; }
.chip-tool::before { content: '🔗'; font-size: 0.85rem; }
.chip-tool:hover { border-color: var(--accent); background: var(--surface-2); }

/* Logo de l'outil en guise de titre de la présentation */
.solution-logo-title {
    display: flex;
    align-items: center;
    min-height: 64px;
    margin-bottom: 18px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--border);
}
.solution-logo-title img {
    max-height: 56px;
    max-width: 260px;
    width: auto;
    object-fit: contain;
}

/* Sous-titres de section */
.sub-title {
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.09em;
    color: var(--text-mut);
    font-weight: 700;
    margin: 26px 0 12px;
}

/* Risques couverts */
.protect-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.protect-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 12px 14px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    background: var(--bg-alt);
    flex-wrap: wrap;
}
.protect-risk { color: var(--text); font-weight: 500; font-size: 0.95rem; }
.protect-level {
    flex-shrink: 0;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 4px 10px;
    border-radius: 999px;
    white-space: nowrap;
}
.protect-level.is-suffit { color: var(--accent-ink); background: var(--accent); }
.protect-level.is-participe { color: var(--text-soft); background: var(--surface-2); border: 1px dashed var(--border); }

/* Valeur ajoutée & KPI */
.kpi-box {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-top: 16px;
    padding: 14px 18px;
    background: var(--surface-2);
    border-radius: var(--radius-sm);
    border: 1px dashed var(--border);
}
.kpi-label { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.1em; color: var(--accent); font-weight: 700; }
.kpi-value { color: var(--text); font-weight: 500; }

/* Auto-hébergement */
.selfhost-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-top: 6px; }
.selfhost-item {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 16px 18px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface);
}
.selfhost-key { font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--text-mut); font-weight: 600; }
.selfhost-val { font-weight: 700; font-size: 1.05rem; display: inline-flex; align-items: center; gap: 7px; }
.selfhost-val::before { content: ''; width: 9px; height: 9px; border-radius: 999px; display: inline-block; }
.selfhost-val.is-yes { color: var(--accent); }
.selfhost-val.is-yes::before { background: var(--accent); }
.selfhost-val.is-no { color: var(--text-mut); }
.selfhost-val.is-no::before { background: var(--text-mut); }
.selfhost-link {
    font-size: 0.72rem;
    font-weight: 600;
    color: var(--text-mut);
    text-decoration: underline;
    text-underline-offset: 2px;
}
.selfhost-link:hover { color: var(--accent); }

/* Ressources : lecture verticale — libellé en italique à gauche, volume à droite */
.resource-rows {
    margin-top: 16px;
    border-radius: var(--radius);
    overflow: hidden;
}
.resource-row {
    display: grid;
    grid-template-columns: 190px 1fr;
    gap: 16px;
    align-items: baseline;
    padding: 11px 18px;
}
.resource-row:nth-child(odd) { background: var(--bg-alt); }
.resource-row-label {
    font-style: italic;
    color: var(--text-mut);
    font-size: 0.9rem;
}
.resource-row-value {
    color: var(--text);
    font-weight: 500;
    font-size: 0.95rem;
}

/* Interactions avec l'infrastructure : tableau Source / → / Destination / Pourquoi */
.infra-table {
    margin-top: 16px;
    border-radius: var(--radius);
    overflow: hidden;
}
.infra-row {
    display: grid;
    grid-template-columns: 1fr 24px 1fr 2fr;
    gap: 12px;
    align-items: baseline;
    padding: 11px 18px;
}
.infra-row:nth-child(even) { background: var(--bg-alt); }
.infra-row-head {
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-weight: 700;
    color: var(--text-mut);
    background: none !important;
}
.infra-col-source, .infra-col-dest { color: var(--text); font-weight: 500; font-size: 0.95rem; }
.infra-col-arrow { color: var(--accent); text-align: center; }
.infra-col-reason { color: var(--text-soft); font-size: 0.9rem; }

/* Intégration */
.recipe-intro { color: var(--text-soft); font-size: 0.95rem; margin: 0 0 6px; }
.recipe-intro a { color: var(--accent); text-decoration: underline; text-underline-offset: 2px; }

.recipe-steps {
    list-style: none;
    counter-reset: recipe;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 18px;
}
.recipe-step {
    counter-increment: recipe;
    position: relative;
    padding: 16px 18px 16px 54px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--bg-alt);
}
.recipe-step::before {
    content: counter(recipe);
    position: absolute;
    left: 16px;
    top: 16px;
    width: 26px;
    height: 26px;
    border-radius: 999px;
    background: var(--accent);
    color: var(--accent-ink);
    font-weight: 700;
    font-size: 0.82rem;
    display: flex;
    align-items: center;
    justify-content: center;
}
.recipe-step-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 14px;
    flex-wrap: wrap;
    margin-bottom: 10px;
}
.recipe-step-title { color: var(--text); font-weight: 600; }
.recipe-time {
    flex-shrink: 0;
    font-family: var(--mono);
    font-size: 0.75rem;
    color: var(--text-mut);
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: 999px;
    padding: 3px 10px;
    white-space: nowrap;
}
.recipe-cmd {
    margin: 0 0 10px;
    padding: 12px 14px;
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    overflow-x: auto;
}
.recipe-cmd code {
    font-family: var(--mono);
    font-size: 0.82rem;
    color: var(--text);
    white-space: pre;
}
.recipe-result { margin: 0; color: var(--text-soft); font-size: 0.9rem; }
.recipe-result-label {
    font-size: 0.68rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-weight: 700;
    color: var(--accent);
    margin-right: 8px;
}
.recipe-link { margin: 8px 0 0; font-size: 0.85rem; }
.recipe-link a { color: var(--accent); text-decoration: underline; text-underline-offset: 2px; }

/* ---------- Aside ---------- */
.chapter-aside { position: sticky; top: 88px; }
.aside-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 20px;
}
.aside-title { margin: 0 0 14px; font-size: 0.82rem; text-transform: uppercase; letter-spacing: 0.1em; color: var(--text-mut); }
.aside-nav { list-style: none; margin: 0; padding: 0; }
.aside-nav li a {
    display: flex; align-items: center; gap: 10px;
    padding: 8px 10px;
    border-radius: var(--radius-sm);
    color: var(--text-soft);
    font-size: 0.92rem;
    transition: background .12s, color .12s;
}
.aside-nav li a:hover { background: var(--surface-2); color: var(--text); }
.aside-nav li.is-active a { background: var(--surface-2); color: var(--accent); font-weight: 600; }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--border); background: var(--bg-alt); padding: 52px 0 32px; margin-top: 40px; }
.footer-title { font-weight: 700; margin: 0 0 8px; font-size: 1.1rem; }
.footer-title::before { content: '\25B3'; color: var(--accent); margin-right: 8px; }
.footer-sub { color: var(--text-soft); margin: 0; font-size: 0.92rem; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
    .pillars, .chapter-grid { grid-template-columns: 1fr; }
    .chapter-layout { grid-template-columns: 1fr; }
    .chapter-aside { position: static; }
    .footer-grid { grid-template-columns: 1fr 1fr; gap: 30px; }
    .resource-grid { grid-template-columns: 1fr; }
    .selfhost-grid { grid-template-columns: 1fr; }
    .solution-head { flex-direction: column; align-items: flex-start; }
    .resource-row { grid-template-columns: 1fr; gap: 2px; }
    .infra-row { grid-template-columns: 1fr; gap: 2px; }
    .infra-row-head { display: none; }
    .infra-col-arrow { display: none; }
    .recipe-step { padding: 14px 14px 14px 46px; }
    .inventory-row { grid-template-columns: 44px 1fr; }
    .inventory-meta { grid-column: 1 / -1; align-items: flex-start; }
    .inventory-license, .inventory-chapters { text-align: left; justify-content: flex-start; }
    .risk-table-wrap { overflow-x: auto; }
    .risk-table { min-width: 860px; }
}
