/* ══════════════════════════════════════════════════════════════
   Navigation avec un Body Graph - styles
   ══════════════════════════════════════════════════════════════ */

/* ═══════════════════════════════════════════════════════════
   Bandeau par page CPT (single-*.php) - style marqué web 2.0
   ═══════════════════════════════════════════════════════════ */
.hd-nav-banner {
    display: flex;
    align-items: center;
    gap: 1.1rem;
    margin: 0 0 1.75rem;
    padding: 1.1rem 1.3rem;
    background:
        linear-gradient(135deg, #1a2340 0%, #0f1a38 100%);
    border: 1px solid rgba(201,168,76,0.4);
    border-left: 4px solid var(--gold);
    border-radius: 12px;
    color: #f4e9c8;
    font-size: 0.93rem;
    line-height: 1.5;
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.08),
        0 6px 20px rgba(0,0,0,0.25),
        0 0 0 1px rgba(201,168,76,0.1);
    position: relative;
    overflow: hidden;
}
.hd-nav-banner::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(201,168,76,0.6), transparent);
    pointer-events: none;
}

.hd-nav-banner--active {
    background: linear-gradient(135deg, #1b3a20 0%, #0f2814 100%);
    border-color: rgba(102,187,106,0.55);
    border-left-color: #66bb6a;
    color: #e8f5e9;
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.1),
        0 6px 22px rgba(46,125,50,0.25),
        0 0 0 1px rgba(102,187,106,0.15);
}
.hd-nav-banner--active::before {
    background: linear-gradient(90deg, transparent, rgba(102,187,106,0.7), transparent);
}

.hd-nav-banner--inactive {
    background: linear-gradient(135deg, #141b30 0%, #0b1428 100%);
    border-color: rgba(120,135,180,0.35);
    border-left-color: rgba(201,168,76,0.6);
    color: #c5cae9;
}

.hd-nav-banner--neutral {
    background: linear-gradient(135deg, #2a2416 0%, #1a1510 100%);
    border-color: rgba(201,168,76,0.5);
    border-left-color: var(--gold);
    color: #f4e9c8;
}

.hd-nav-banner__icon {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    font-size: 1.3rem;
    font-weight: 600;
    color: #050c1c;
    background: linear-gradient(135deg, #e0bd5e 0%, var(--gold) 100%);
    border: 1px solid rgba(255,255,255,0.2);
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.3),
        0 2px 8px rgba(201,168,76,0.35);
}
.hd-nav-banner--active .hd-nav-banner__icon {
    color: #fff;
    background: linear-gradient(135deg, #81c784 0%, #388e3c 100%);
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.3),
        0 2px 8px rgba(46,125,50,0.45);
}

.hd-nav-banner__body {
    flex: 1;
    min-width: 0;
}

.hd-nav-banner__title {
    margin: 0 0 0.25rem;
    font-size: 0.98rem;
    font-weight: 500;
    color: #fff;
    letter-spacing: 0.01em;
}
.hd-nav-banner__title strong {
    color: var(--gold);
    font-weight: 700;
}
.hd-nav-banner--active .hd-nav-banner__title {
    color: #f1f8e9;
}
.hd-nav-banner--active .hd-nav-banner__title strong {
    color: #aed581;
}

.hd-nav-banner__detail {
    margin: 0;
    font-size: 0.85rem;
    color: rgba(255,255,255,0.82);
}
.hd-nav-banner__detail strong {
    color: var(--gold);
    font-weight: 600;
}
.hd-nav-banner--active .hd-nav-banner__detail strong {
    color: #aed581;
}
.hd-nav-banner__detail em {
    color: rgba(255,255,255,0.88);
    font-style: italic;
}

/* ═══════════════════════════════════════════════════════════
   Archives CPT - bandeau + marquage des cards matchantes
   ═══════════════════════════════════════════════════════════ */

.hd-nav-archive {
    margin: 1.75rem 0 2.25rem;
    padding: 1.75rem 1.75rem 1.5rem;
    background:
        radial-gradient(ellipse at top left, rgba(139,195,74,0.18), transparent 65%),
        linear-gradient(135deg, #1b3a20 0%, #0f2814 100%);
    border: 1px solid rgba(102,187,106,0.55);
    border-radius: 16px;
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.1),
        0 8px 30px rgba(46,125,50,0.25),
        0 0 0 1px rgba(102,187,106,0.15);
    position: relative;
    overflow: hidden;
}
.hd-nav-archive::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, #8bc34a, transparent);
}

.hd-nav-archive__header {
    margin-bottom: 1rem;
    position: relative;
    padding-right: 2.5rem;
}

.hd-nav-archive__close,
.hd-nav-banner__close {
    position: absolute;
    top: 0;
    right: 0;
    width: 28px;
    height: 28px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: 1px solid rgba(255,255,255,0.12);
    color: rgba(255,255,255,0.55);
    font-size: 1.3rem;
    line-height: 1;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.2s;
    flex-shrink: 0;
}
.hd-nav-archive__close:hover,
.hd-nav-banner__close:hover {
    background: rgba(239,83,80,0.15);
    border-color: rgba(239,83,80,0.5);
    color: #ef5350;
}

.hd-nav-banner {
    position: relative;
    padding-right: 3rem;
}
.hd-nav-banner__close {
    top: 50%;
    right: 0.8rem;
    transform: translateY(-50%);
}

body.light-mode .hd-nav-archive__close,
body.light-mode .hd-nav-banner__close {
    border-color: rgba(0,0,0,0.12);
    color: rgba(0,0,0,0.55);
}
body.light-mode .hd-nav-archive__close:hover,
body.light-mode .hd-nav-banner__close:hover {
    background: rgba(198,40,40,0.12);
    border-color: rgba(198,40,40,0.5);
    color: #c62828;
}

.hd-nav-archive__pill {
    display: inline-block;
    font-size: 0.7rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: #fff;
    background: linear-gradient(135deg, #81c784 0%, #388e3c 100%);
    border: 1px solid rgba(255,255,255,0.2);
    padding: 0.3rem 0.85rem;
    border-radius: 14px;
    margin-bottom: 1rem;
    font-weight: 700;
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.35),
        0 2px 6px rgba(56,142,60,0.45);
}

.hd-nav-archive__title {
    margin: 0 0 0.5rem;
    font-size: 1.35rem;
    font-weight: 500;
    color: #fff;
    letter-spacing: 0.01em;
}

.hd-nav-archive__summary {
    margin: 0;
    font-size: 0.92rem;
    color: rgba(255,255,255,0.85);
    line-height: 1.55;
}

.hd-nav-archive__pills {
    list-style: none;
    padding: 0;
    margin: 1rem 0 0;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.hd-nav-archive__pill-item {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
}

.hd-nav-archive__pill-link,
.hd-nav-archive__pill-item > .hd-nav-archive__pill-label {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.35rem 0.75rem;
    background: rgba(255,255,255,0.035);
    border: 1px solid rgba(201,168,76,0.3);
    border-radius: 16px;
    font-size: 0.82rem;
    color: var(--gold);
    text-decoration: none;
    transition: all 0.2s;
}
.hd-nav-archive__pill-link:hover {
    background: rgba(201,168,76,0.12);
    border-color: var(--gold);
    text-decoration: none;
    transform: translateY(-1px);
}

.hd-nav-archive__pill-item--both .hd-nav-archive__pill-link {
    border-color: #66bb6a;
    color: #aed581;
}
.hd-nav-archive__pill-item--perso .hd-nav-archive__pill-link {
    border-color: rgba(201,168,76,0.5);
}
.hd-nav-archive__pill-item--design .hd-nav-archive__pill-link {
    border-color: rgba(220,50,47,0.5);
    color: #e85a68;
}

.hd-nav-archive__pill-label {
    font-weight: 500;
}
.hd-nav-archive__pill-meta {
    font-size: 0.68rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    padding: 0.15rem 0.45rem;
    background: rgba(201,168,76,0.15);
    border-radius: 8px;
    color: var(--gold);
}
.hd-nav-archive__pill-item--both .hd-nav-archive__pill-meta {
    background: rgba(76,175,80,0.2);
    color: #aed581;
}
.hd-nav-archive__pill-item--design .hd-nav-archive__pill-meta {
    background: rgba(220,50,47,0.2);
    color: #e85a68;
}

/* Groupes (centres définis / ouverts) */
.hd-nav-archive__group {
    margin-bottom: 0.75rem;
}
.hd-nav-archive__group:last-child {
    margin-bottom: 0;
}
.hd-nav-archive__group-title {
    font-size: 0.78rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin: 0 0 0.5rem;
    padding: 0;
}
.hd-nav-archive__group--defined .hd-nav-archive__group-title {
    color: #aed581;
}
.hd-nav-archive__group--open .hd-nav-archive__group-title {
    color: #90caf9;
}
/* Centres ouverts : teinte bleue, bordure pointillée */
.hd-nav-archive__pill-item--open .hd-nav-archive__pill-link,
.hd-nav-archive__pill-item--open > .hd-nav-archive__pill-label {
    background: rgba(100,150,220,0.08);
    border: 1px dashed rgba(120,160,230,0.4);
    color: rgba(180,210,255,0.85);
}
.hd-nav-archive__pill-item--open .hd-nav-archive__pill-link:hover {
    background: rgba(100,150,220,0.16);
    border-color: rgba(120,160,230,0.65);
    color: #fff;
}
.hd-nav-archive__pill-item--open .hd-nav-archive__pill-meta {
    background: rgba(100,150,220,0.15);
    color: #90caf9;
}
/* Centres définis : accentuation verte subtile */
.hd-nav-archive__pill-item--defined .hd-nav-archive__pill-link {
    border-color: rgba(76,175,80,0.35);
    background: rgba(76,175,80,0.08);
}
.hd-nav-archive__pill-item--defined .hd-nav-archive__pill-link:hover {
    border-color: rgba(76,175,80,0.6);
    background: rgba(76,175,80,0.15);
}
.hd-nav-archive__pill-item--defined .hd-nav-archive__pill-meta {
    background: rgba(76,175,80,0.2);
    color: #aed581;
}
/* Light mode */
body.light-mode .hd-nav-archive__group--defined .hd-nav-archive__group-title {
    color: #388e3c;
}
body.light-mode .hd-nav-archive__group--open .hd-nav-archive__group-title {
    color: #1565c0;
}
body.light-mode .hd-nav-archive__pill-item--open .hd-nav-archive__pill-link,
body.light-mode .hd-nav-archive__pill-item--open > .hd-nav-archive__pill-label {
    background: rgba(21,101,192,0.05);
    border-color: rgba(21,101,192,0.25);
    color: #1565c0;
}
body.light-mode .hd-nav-archive__pill-item--open .hd-nav-archive__pill-link:hover {
    background: rgba(21,101,192,0.1);
    color: #0d47a1;
}
body.light-mode .hd-nav-archive__pill-item--defined .hd-nav-archive__pill-link {
    border-color: rgba(56,142,60,0.3);
    background: rgba(56,142,60,0.06);
}
body.light-mode .hd-nav-archive__pill-item--defined .hd-nav-archive__pill-link:hover {
    border-color: rgba(56,142,60,0.5);
    background: rgba(56,142,60,0.12);
}
body.light-mode .hd-nav-archive__pill-item--defined .hd-nav-archive__pill-meta {
    background: rgba(56,142,60,0.15);
    color: #2e7d32;
}

@media (max-width: 640px) {
    .hd-nav-archive {
        padding: 1.25rem 1rem;
    }
    .hd-nav-archive__title {
        font-size: 1.05rem;
    }
}

/* ─── Marquage des cards matchantes dans les grilles d'archive ─── */
.porte-grid-card.hd-nav-match {
    position: relative;
    border-color: var(--gold) !important;
    box-shadow: 0 0 0 1px rgba(201,168,76,0.3), 0 4px 18px rgba(201,168,76,0.12);
    background: linear-gradient(135deg, rgba(201,168,76,0.06), rgba(201,168,76,0.02));
}
.porte-grid-card.hd-nav-match::before {
    content: '●';
    position: absolute;
    top: 0.5rem;
    right: 0.6rem;
    font-size: 0.75rem;
    color: var(--gold);
    z-index: 2;
}
.porte-grid-card.hd-nav-match--both::before      { color: #66bb6a; content: '●'; }
.porte-grid-card.hd-nav-match--perso::before     { color: var(--gold); content: '●'; }
.porte-grid-card.hd-nav-match--design::before    { color: #e85a68; content: '◐'; }
.porte-grid-card.hd-nav-match--active::before    { color: #66bb6a; content: '═'; }
.porte-grid-card.hd-nav-match--defined::before   { color: #66bb6a; content: '◉'; }
.porte-grid-card.hd-nav-match--own::before       { color: var(--gold); content: '★'; }

.porte-grid-card.hd-nav-match--both {
    border-color: #66bb6a !important;
    box-shadow: 0 0 0 1px rgba(76,175,80,0.3), 0 4px 18px rgba(76,175,80,0.15);
    background: linear-gradient(135deg, rgba(76,175,80,0.08), rgba(76,175,80,0.02));
}
.porte-grid-card.hd-nav-match--design {
    border-color: #e85a68 !important;
    box-shadow: 0 0 0 1px rgba(220,50,47,0.3), 0 4px 18px rgba(220,50,47,0.12);
    background: linear-gradient(135deg, rgba(220,50,47,0.06), rgba(220,50,47,0.02));
}
.porte-grid-card.hd-nav-match--active,
.porte-grid-card.hd-nav-match--defined {
    border-color: #66bb6a !important;
    box-shadow: 0 0 0 1px rgba(76,175,80,0.3), 0 4px 18px rgba(76,175,80,0.15);
    background: linear-gradient(135deg, rgba(76,175,80,0.08), rgba(76,175,80,0.02));
}
.porte-grid-card.hd-nav-match--own {
    border-color: var(--gold) !important;
    box-shadow: 0 0 0 2px var(--gold), 0 6px 24px rgba(201,168,76,0.25);
}

/* Cards inactives atténuées quand la nav BG décore l'archive */
.porte-grid:has(.hd-nav-match) .porte-grid-card:not(.hd-nav-match) {
    opacity: 0.4;
    filter: grayscale(0.3);
    border-color: rgba(255,255,255,0.03) !important;
    transition: opacity 0.3s, filter 0.3s;
}
.porte-grid:has(.hd-nav-match) .porte-grid-card:not(.hd-nav-match):hover {
    opacity: 0.8;
    filter: none;
}
body.light-mode .porte-grid:has(.hd-nav-match) .porte-grid-card:not(.hd-nav-match) {
    opacity: 0.45;
    border-color: rgba(0,0,0,0.04) !important;
}
body.light-mode .porte-grid:has(.hd-nav-match) .porte-grid-card:not(.hd-nav-match):hover {
    opacity: 0.85;
}

/* Mode jour - archive bandeau */
body.light-mode .hd-nav-archive {
    background:
        radial-gradient(ellipse at top left, rgba(76,175,80,0.2), transparent 65%),
        linear-gradient(135deg, #f1f8e9 0%, #dcedc8 100%);
    border: 1px solid rgba(46,125,50,0.5);
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.6),
        0 6px 24px rgba(46,125,50,0.2);
}
body.light-mode .hd-nav-archive::before {
    background: linear-gradient(90deg, transparent, #2e7d32, transparent);
}
body.light-mode .hd-nav-archive__pill {
    color: #fff;
    background: linear-gradient(135deg, #66bb6a 0%, #2e7d32 100%);
    border-color: rgba(255,255,255,0.4);
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.4),
        0 2px 6px rgba(46,125,50,0.4);
}
body.light-mode .hd-nav-archive__title {
    color: #1b2e0f;
}
body.light-mode .hd-nav-archive__summary {
    color: #2e4a1c;
}
body.light-mode .hd-nav-archive__pill-link {
    background: rgba(46,125,50,0.05);
    color: #2e7d32;
    border-color: rgba(46,125,50,0.3);
}
body.light-mode .hd-nav-archive__pill-link:hover {
    background: rgba(76,175,80,0.12);
    border-color: #2e7d32;
}
body.light-mode .hd-nav-archive__pill-meta {
    background: rgba(76,175,80,0.18);
    color: #2e7d32;
}
body.light-mode .porte-grid-card.hd-nav-match {
    background: linear-gradient(135deg, rgba(201,168,76,0.12), rgba(201,168,76,0.03));
}

/* ═══════════════════════════════════════════════════════════
   Schéma d'archive CPT - BG silhouette avec annotations cliquables
   ═══════════════════════════════════════════════════════════ */

.archive-schema {
    margin: 2rem 0 2.5rem;
    padding: 2rem 1.5rem;
    background:
        radial-gradient(ellipse at top, rgba(201,168,76,0.06), transparent 60%),
        linear-gradient(135deg, #1a2340 0%, #0b1428 100%);
    border: 1px solid rgba(201,168,76,0.35);
    border-radius: 16px;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.08), 0 8px 30px rgba(0,0,0,0.3);
    position: relative;
    overflow: hidden;
}
.archive-schema::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--gold), transparent);
}
.archive-schema__header {
    text-align: center;
    margin-bottom: 1.5rem;
}
.archive-schema__title {
    margin: 0 0 0.4rem;
    font-size: 1.3rem;
    font-weight: 500;
    color: #fff;
}
.archive-schema__sub {
    margin: 0;
    font-size: 0.88rem;
    color: rgba(255,255,255,0.7);
    font-style: italic;
}
.archive-schema__svg {
    margin: 0 auto;
    display: block;
}
/* Dimensions par type : ratio viewBox + max-width adapté au contenu */
.archive-schema--centre_hd .archive-schema__svg {
    max-width: 760px;
    aspect-ratio: 600 / 400;
}
.archive-schema--porte .archive-schema__svg,
.archive-schema--gene_key .archive-schema__svg {
    max-width: 880px;
    aspect-ratio: 290 / 405;
}
/* Canaux : layout 2 colonnes, la cellule SVG gère son propre ratio */
.archive-schema--canal .archive-schema__svg {
    max-width: 900px;
}
.archive-schema-svg {
    display: block;
    width: 100%;
    height: 100%;
}
.archive-schema--canal .archive-schema-svg {
    height: auto;
    max-height: 560px;
}
.archive-schema-channel {
    fill: none;
    stroke: rgba(255,255,255,0.2);
    stroke-width: 1.3;
    stroke-linecap: round;
}
.archive-schema-center {
    fill: none;
    stroke: rgba(255,255,255,0.5);
    stroke-width: 1.1;
    transition: fill 0.2s, stroke 0.2s;
}
/* Nav BG actif : coloration selon l'état du centre sur le BG courant */
.archive-schema-center--defined {
    fill: rgba(56, 132, 255, 0.55);     /* bleu - centre défini */
    stroke: rgba(56, 132, 255, 0.95);
    stroke-width: 1.4;
}
.archive-schema-center--open {
    fill: rgba(231, 76, 94, 0.35);      /* rouge - centre ouvert */
    stroke: rgba(231, 76, 94, 0.85);
    stroke-width: 1.4;
}
body.light-mode .archive-schema-center--defined {
    fill: rgba(56, 132, 255, 0.35);
    stroke: rgba(40, 100, 210, 1);
}
body.light-mode .archive-schema-center--open {
    fill: rgba(231, 76, 94, 0.25);
    stroke: rgba(190, 40, 60, 1);
}
.archive-schema-connector {
    stroke: rgba(201,168,76,0.5);
    stroke-width: 0.9;
    stroke-dasharray: 2 2;
    fill: none;
}
.archive-schema-dot { fill: var(--gold); }
.archive-schema-end { fill: rgba(201,168,76,0.7); }
.archive-schema-label { cursor: pointer; }
.archive-schema-label:hover .archive-schema-label-title {
    fill: #fff;
    font-weight: 600;
}
.archive-schema-label:hover .archive-schema-label-cat {
    fill: rgba(255,255,255,0.7);
}
.archive-schema-label-title {
    font-family: 'Lora', Georgia, serif;
    font-size: 13px;
    font-weight: 600;
    fill: var(--gold);
    letter-spacing: 0.01em;
}
.archive-schema-label-cat {
    font-family: 'Lora', Georgia, serif;
    font-size: 9px;
    font-weight: 400;
    fill: rgba(255,255,255,0.5);
    font-style: italic;
}
.archive-schema-canal {
    fill: none;
    stroke: var(--gold);
    stroke-width: 2.2;
    stroke-linecap: round;
    opacity: 0.7;
    transition: all 0.2s;
    cursor: pointer;
}
.archive-schema-canal-group:hover .archive-schema-canal {
    stroke: #ffd970;
    stroke-width: 3;
    opacity: 1;
    filter: drop-shadow(0 0 3px rgba(201,168,76,0.6));
}
.archive-schema-gate {
    fill: #0b1428;
    stroke: var(--gold);
    stroke-width: 1;
    transition: all 0.2s;
}
.archive-schema-gate-num {
    font-family: 'Lora', Georgia, serif;
    font-size: 5px;
    font-weight: 600;
    fill: var(--gold);
    pointer-events: none;
}
.archive-schema-gate-link { cursor: pointer; }
.archive-schema-gate-link:hover .archive-schema-gate {
    fill: var(--gold);
    stroke: #ffd970;
    stroke-width: 1.4;
    filter: drop-shadow(0 0 4px rgba(201,168,76,0.8));
}
.archive-schema-gate-link:hover .archive-schema-gate-num {
    fill: #050c1c;
    font-weight: 700;
}
/* Canaux : layout 2 colonnes BG + légende */
.archive-schema-canal-wrap {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
    gap: 2rem;
    align-items: start;
}
.archive-schema-canal-legend {
    max-height: 560px;
    overflow-y: auto;
    padding-right: 0.5rem;
}
.archive-schema-canal-legend__title {
    margin: 0 0 0.75rem;
    font-size: 0.82rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: rgba(255,255,255,0.6);
    font-weight: 600;
}
.archive-schema-canal-legend ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}
.archive-schema-canal-legend__btn {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.5rem 0.7rem;
    background: rgba(255,255,255,0.025);
    border: 1px solid rgba(201,168,76,0.2);
    border-radius: 8px;
    color: inherit;
    cursor: pointer;
    text-align: left;
    font: inherit;
    transition: all 0.15s;
}
.archive-schema-canal-legend__btn:hover {
    background: rgba(201,168,76,0.12);
    border-color: var(--gold);
    transform: translateX(2px);
}
.archive-schema-canal-legend__key {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    padding: 0.15rem 0.4rem;
    background: rgba(201,168,76,0.15);
    color: var(--gold);
    border-radius: 6px;
    font-family: 'Lora', Georgia, serif;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.03em;
}
.archive-schema-canal-legend__title-inline {
    flex: 1;
    font-size: 0.82rem;
    color: rgba(255,255,255,0.85);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Badges numériques sur les canaux */
.archive-schema-canal-badge {
    fill: #050c1c;
    stroke: var(--gold);
    stroke-width: 1;
    transition: all 0.15s;
}
.archive-schema-canal-num {
    font-family: 'Lora', Georgia, serif;
    font-size: 7px;
    font-weight: 700;
    fill: var(--gold);
    pointer-events: none;
}
.archive-schema-canal-group:hover .archive-schema-canal-badge {
    fill: var(--gold);
    stroke: #ffd970;
}
.archive-schema-canal-group:hover .archive-schema-canal-num {
    fill: #050c1c;
}

/* ─── Popup modale ─── */
.archive-schema-popup__overlay {
    position: fixed;
    inset: 0;
    z-index: var(--z-toast);
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(0,0,0,0.7);
    backdrop-filter: blur(4px);
    padding: 1rem;
}
.archive-schema-popup__overlay.is-open { display: flex; }
.archive-schema-popup {
    position: relative;
    max-width: 480px;
    width: 100%;
    padding: 2rem 1.75rem 1.75rem;
    background: linear-gradient(135deg, #1a2340 0%, #0b1428 100%);
    border: 1px solid rgba(201,168,76,0.45);
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.6), inset 0 1px 0 rgba(255,255,255,0.08);
    color: #fff;
    animation: popupFadeIn 0.2s ease;
}
@keyframes popupFadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to   { opacity: 1; transform: translateY(0); }
}
.archive-schema-popup__close {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    width: 32px;
    height: 32px;
    border: 1px solid rgba(255,255,255,0.15);
    background: transparent;
    color: rgba(255,255,255,0.6);
    font-size: 1.5rem;
    line-height: 1;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.2s;
}
.archive-schema-popup__close:hover {
    background: rgba(239,83,80,0.15);
    border-color: rgba(239,83,80,0.5);
    color: #ef5350;
}
.archive-schema-popup__title {
    margin: 0 2.5rem 0.75rem 0;
    font-family: 'Lora', Georgia, serif;
    font-size: 1.35rem;
    font-weight: 500;
    color: var(--gold);
}
.archive-schema-popup__excerpt {
    margin: 0 0 1.5rem;
    font-size: 0.92rem;
    line-height: 1.6;
    color: rgba(255,255,255,0.85);
}
.archive-schema-popup__cta {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.6rem 1.4rem;
    background: linear-gradient(135deg, #e0bd5e, var(--gold));
    color: #fff; text-shadow: 0 1px 2px rgba(0,0,0,0.25);
    text-decoration: none;
    border-radius: 22px;
    font-weight: 600;
    font-size: 0.88rem;
    transition: all 0.2s;
}
.archive-schema-popup__cta:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 18px rgba(201,168,76,0.35);
}

@media (max-width: 720px) {
    .archive-schema { padding: 1.5rem 0.75rem; }
    .archive-schema__title { font-size: 1.1rem; }
    .archive-schema-label-title { font-size: 16px; }
    .archive-schema-canal-wrap {
        grid-template-columns: 1fr;
    }
    .archive-schema-canal-legend { max-height: 340px; }
}

/* Mode jour */
body.light-mode .archive-schema {
    background:
        radial-gradient(ellipse at top, rgba(201,168,76,0.12), transparent 60%),
        linear-gradient(135deg, #fdf7e8 0%, #f5edd1 100%);
    border-color: rgba(139,105,20,0.4);
}
body.light-mode .archive-schema__title { color: #1a1a2e; }
body.light-mode .archive-schema__sub   { color: rgba(0,0,0,0.65); }
body.light-mode .archive-schema-channel { stroke: rgba(0,0,0,0.22); }
body.light-mode .archive-schema-center  { stroke: rgba(0,0,0,0.55); }
body.light-mode .archive-schema-connector { stroke: rgba(139,105,20,0.6); }
body.light-mode .archive-schema-dot,
body.light-mode .archive-schema-end { fill: #8b6914; }
body.light-mode .archive-schema-label-title { fill: #8b6914; }
body.light-mode .archive-schema-label-cat { fill: rgba(0,0,0,0.45); }
body.light-mode .archive-schema-label:hover .archive-schema-label-title { fill: #1a1a2e; }
body.light-mode .archive-schema-label:hover .archive-schema-label-cat { fill: rgba(0,0,0,0.65); }
body.light-mode .archive-schema-canal { stroke: #8b6914; }
body.light-mode .archive-schema-gate  { fill: #fafaf7; stroke: #8b6914; }
body.light-mode .archive-schema-gate-num { fill: #8b6914; }

/* Popup + canal légende - mode jour */
body.light-mode .archive-schema-popup {
    background: linear-gradient(135deg, #fdf7e8 0%, #f5edd1 100%);
    border-color: rgba(139,105,20,0.45);
    color: #1a1a2e;
}
body.light-mode .archive-schema-popup__close {
    border-color: rgba(0,0,0,0.15);
    color: rgba(0,0,0,0.55);
}
body.light-mode .archive-schema-popup__title { color: #8b6914; }
body.light-mode .archive-schema-popup__excerpt { color: #2a2a3e; }
body.light-mode .archive-schema-canal-legend__title { color: rgba(0,0,0,0.6); }
body.light-mode .archive-schema-canal-legend__btn {
    background: rgba(0,0,0,0.025);
    border-color: rgba(139,105,20,0.25);
}
body.light-mode .archive-schema-canal-legend__btn:hover {
    background: rgba(201,168,76,0.12);
    border-color: #8b6914;
}
body.light-mode .archive-schema-canal-legend__key {
    background: rgba(201,168,76,0.2);
    color: #8b6914;
}
body.light-mode .archive-schema-canal-legend__title-inline { color: #2a2a3e; }
body.light-mode .archive-schema-canal-badge {
    fill: #fafaf7;
    stroke: #8b6914;
}
body.light-mode .archive-schema-canal-num { fill: #8b6914; }

/* Lien inline (wrap autour d'un <strong>) : souligne subtil + hover */
.hd-nav-inline-link {
    color: var(--gold);
    text-decoration: none;
    border-bottom: 1px dashed rgba(201,168,76,0.5);
    transition: all 0.15s;
}
.hd-nav-inline-link:hover {
    color: #e0bd5e;
    border-bottom-color: var(--gold);
    border-bottom-style: solid;
    text-decoration: none;
}
.hd-nav-inline-link strong { color: inherit; }
body.light-mode .hd-nav-inline-link {
    color: #8b6914;
    border-bottom-color: rgba(139,105,20,0.5);
}
body.light-mode .hd-nav-inline-link:hover {
    color: #6d5210;
    border-bottom-color: #8b6914;
}

.hd-nav-banner__link {
    flex-shrink: 0;
    font-size: 0.75rem;
    color: var(--text-muted, rgba(255,255,255,0.55));
    text-decoration: none;
    padding: 0.3rem 0.75rem;
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 16px;
    transition: all 0.2s;
}
.hd-nav-banner__link:hover {
    color: var(--gold);
    border-color: var(--gold);
}

@media (max-width: 640px) {
    .hd-nav-banner {
        flex-wrap: wrap;
    }
    .hd-nav-banner__link {
        margin-left: auto;
    }
}

/* ─── Bandeau float global (bas-droit) ─── */
.hd-nav-float {
    position: fixed;
    right: 1.25rem;
    bottom: 1.25rem;
    z-index: var(--z-modal);
    background: #050c1c;
    border: 1px solid rgba(201,168,76,0.35);
    border-radius: 14px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.5), 0 0 20px rgba(201,168,76,0.15);
    max-width: 300px;
    overflow: hidden;
    transition: max-width 0.3s ease, max-height 0.3s ease, border-radius 0.3s ease;
}

/* Bouton pastille (visible uniquement en mode réduit) */
.hd-nav-float__toggle {
    display: none;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    width: 100%;
    height: 100%;
    padding: 0;
    background: transparent;
    border: none;
    color: var(--gold);
    cursor: pointer;
    font-size: 0;
}
.hd-nav-float__toggle .hd-nav-float__icon {
    font-size: 1.5rem;
    line-height: 1;
}
.hd-nav-float__toggle .hd-nav-float__label-short {
    display: none;
}

/* Bouton chevron « réduire » dans le header */
.hd-nav-float__actions {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}
.hd-nav-float__collapse {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    padding: 0;
    background: transparent;
    border: none;
    color: rgba(255,255,255,0.78);
    cursor: pointer;
    border-radius: 50%;
    transition: all 0.2s;
}
.hd-nav-float__collapse:hover {
    background: rgba(255,255,255,0.08);
    color: var(--gold);
}
.hd-nav-float__collapse svg {
    display: block;
}
body.light-mode .hd-nav-float__collapse {
    color: var(--gold-dark, #a07c2a);
}
body.light-mode .hd-nav-float__collapse:hover,
body.light-mode .hd-nav-float__collapse:focus-visible {
    background: rgba(160,124,42,0.1);
    color: var(--gold-dark, #a07c2a);
}

/* ─── Mode réduit : pastille compacte cliquable ─── */
.hd-nav-float--collapsed {
    max-width: 56px;
    max-height: 56px;
    border-radius: 50%;
    cursor: pointer;
}
.hd-nav-float--collapsed .hd-nav-float__panel {
    display: none;
}
.hd-nav-float--collapsed .hd-nav-float__toggle {
    display: inline-flex;
    width: 56px;
    height: 56px;
}

.hd-nav-float__panel {
    padding: 0.9rem 1rem 1rem;
}

.hd-nav-float__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.6rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid rgba(201,168,76,0.15);
}
.hd-nav-float__mode {
    font-size: 0.72rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--gold);
    font-weight: 600;
}
.hd-nav-float__close {
    appearance: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    padding: 0;
    background: rgba(239,83,80,0.08);
    border: 1px solid rgba(239,83,80,0.35);
    color: rgba(239,83,80,0.9);
    border-radius: 50%;
    cursor: pointer;
    transition: color 0.18s, border-color 0.18s, background 0.18s, transform 0.18s;
}
.hd-nav-float__close:hover,
.hd-nav-float__close:focus-visible {
    background: rgba(239,83,80,0.2);
    border-color: rgba(239,83,80,0.65);
    color: #ef5350;
    transform: scale(1.08);
    outline: none;
}
.hd-nav-float__close svg {
    display: block;
    flex-shrink: 0;
}
body.light-mode .hd-nav-float__close {
    background: rgba(211,47,47,0.08);
    border-color: rgba(211,47,47,0.35);
    color: rgba(211,47,47,0.85);
}
body.light-mode .hd-nav-float__close:hover,
body.light-mode .hd-nav-float__close:focus-visible {
    background: rgba(211,47,47,0.16);
    border-color: rgba(211,47,47,0.6);
    color: #d32f2f;
}

.hd-nav-float__chart {
    margin-bottom: 0.75rem;
}
.hd-nav-float__name {
    font-family: 'Lora', Georgia, serif;
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--gold);
    margin-bottom: 0.2rem;
}
.hd-nav-float__meta {
    display: flex;
    gap: 0.4rem;
    font-size: 0.75rem;
    color: rgba(255,255,255,0.6);
}
.hd-nav-float__meta--main { font-weight: 500; }
.hd-nav-float__meta-val { color: rgba(255,255,255,0.85); }
.hd-nav-float__meta-sep { opacity: 0.55; }

/* Détails autorité + définition (sous le type/profil) */
.hd-nav-float__details {
    margin: 0.5rem 0 0;
    padding: 0.5rem 0 0;
    border-top: 1px solid rgba(255,255,255,0.08);
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 0.18rem 0.6rem;
    font-size: 0.72rem;
}
.hd-nav-float__detail-row {
    display: contents;
}
.hd-nav-float__detail-label {
    color: rgba(255,255,255,0.78);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-size: 0.65rem;
    align-self: center;
}
.hd-nav-float__detail-val {
    margin: 0;
    color: rgba(255,255,255,0.92);
    font-weight: 500;
}
.hd-nav-float__detail-sub {
    display: inline-block;
    margin-left: 0.35rem;
    font-size: 0.92em;
    opacity: 0.7;
    font-style: italic;
    font-weight: 400;
}

body.light-mode .hd-nav-float__details {
    border-top-color: rgba(0,0,0,0.08);
}
body.light-mode .hd-nav-float__detail-label { color: rgba(0,0,0,0.5); }
body.light-mode .hd-nav-float__detail-val   { color: rgba(0,0,0,0.85); }
body.light-mode .hd-nav-float__meta-val     { color: rgba(0,0,0,0.85); }

.hd-nav-float__selector {
    margin-bottom: 0.6rem;
}
.hd-nav-float__selector-label {
    display: block;
    font-size: 0.68rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: rgba(255,255,255,0.45);
    margin-bottom: 0.3rem;
}
.hd-nav-float__select {
    width: 100%;
    padding: 0.4rem 0.6rem;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.15);
    color: #fff;
    border-radius: 6px;
    font-size: 0.82rem;
    cursor: pointer;
}
.hd-nav-float__select:focus {
    outline: none;
    border-color: var(--gold);
}

.hd-nav-float__view {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
    width: 100%;
    padding: 0.55rem 0.75rem;
    margin-top: 0.4rem;
    background: linear-gradient(135deg, rgba(201,168,76,0.18), rgba(201,168,76,0.08));
    border: 1px solid rgba(201,168,76,0.4);
    border-radius: 7px;
    color: var(--gold);
    font-family: 'Lora', Georgia, serif;
    font-size: 0.82rem;
    font-weight: 600;
    text-decoration: none;
    letter-spacing: 0.02em;
    cursor: pointer;
    transition: background 0.2s ease, border-color 0.2s ease, transform 0.15s ease;
}
.hd-nav-float__view:hover {
    background: linear-gradient(135deg, rgba(201,168,76,0.28), rgba(201,168,76,0.14));
    border-color: rgba(201,168,76,0.6);
    transform: translateY(-1px);
}
.hd-nav-float__view svg {
    flex-shrink: 0;
}

.hd-nav-float__hint {
    margin: 0.6rem 0 0;
    font-size: 0.72rem;
    color: rgba(255,255,255,0.45);
    line-height: 1.4;
    font-style: italic;
}

@media (max-width: 640px) {
    /* Sur mobile : pastille compacte par défaut, pleine largeur quand ouverte */
    .hd-nav-float {
        right: 1rem;
        bottom: 1rem;
        max-width: calc(100vw - 2rem);
    }
    .hd-nav-float__panel {
        padding: 0.75rem 0.85rem 0.85rem;
    }
    .hd-nav-float--collapsed {
        max-width: 52px;
        max-height: 52px;
    }
    .hd-nav-float--collapsed .hd-nav-float__toggle {
        width: 52px;
        height: 52px;
    }
    .hd-nav-float--collapsed .hd-nav-float__toggle .hd-nav-float__icon {
        font-size: 1.35rem;
    }
}

/* ─── Carte dashboard Mon Compte ─── */
.hd-nav-card {
    margin: 2rem 0 1.5rem;
    padding: 1.75rem 1.5rem;
    background: linear-gradient(135deg, rgba(201,168,76,0.05), rgba(201,168,76,0.02));
    border: 1px solid rgba(201,168,76,0.25);
    border-radius: 14px;
    position: relative;
    overflow: hidden;
}
.hd-nav-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at top right, rgba(201,168,76,0.08), transparent 60%);
    pointer-events: none;
}

.hd-nav-card__header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
    position: relative;
}
.hd-nav-card__icon {
    font-size: 1.8rem;
    width: 48px;
    height: 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(201,168,76,0.12);
    border: 1px solid rgba(201,168,76,0.35);
    border-radius: 50%;
    flex-shrink: 0;
}
.hd-nav-card__title {
    margin: 0 0 0.2rem;
    font-size: 1.2rem;
    font-weight: 500;
    color: var(--text, #fff);
}
.hd-nav-card__subtitle {
    margin: 0;
    font-size: 0.82rem;
    color: rgba(255,255,255,0.6);
}

.hd-nav-card__desc {
    margin: 0 0 1.25rem;
    font-size: 0.87rem;
    line-height: 1.55;
    color: rgba(255,255,255,0.7);
    position: relative;
}

.hd-nav-card__form {
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
    position: relative;
}

.hd-nav-card__row {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}
.hd-nav-card__row--actions {
    flex-direction: row;
    align-items: center;
    gap: 0.75rem;
    margin-top: 0.25rem;
}

.hd-nav-card__toggle {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    cursor: pointer;
    user-select: none;
}
.hd-nav-card__toggle input {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: var(--gold);
}
.hd-nav-card__toggle-text {
    font-size: 0.92rem;
    color: var(--text, #fff);
    font-weight: 500;
}

.hd-nav-card__label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: rgba(255,255,255,0.55);
}

.hd-nav-card__select {
    padding: 0.55rem 0.8rem;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.15);
    color: #fff;
    border-radius: 8px;
    font-size: 0.9rem;
    cursor: pointer;
}
.hd-nav-card__select:focus {
    outline: none;
    border-color: var(--gold);
}

.hd-nav-card__submit {
    padding: 0.55rem 1.4rem;
    background: var(--gold);
    color: #050c1c;
    border: none;
    border-radius: 20px;
    font-size: 0.87rem;
    font-weight: 600;
    letter-spacing: 0.03em;
    cursor: pointer;
    transition: all 0.2s;
}
.hd-nav-card__submit:hover:not(:disabled) {
    background: #e0bd5e;
    transform: translateY(-1px);
}
.hd-nav-card__submit:disabled {
    opacity: 0.6;
    cursor: wait;
}

.hd-nav-card__status {
    font-size: 0.82rem;
    color: rgba(255,255,255,0.65);
    font-style: italic;
}

.hd-nav-card__empty {
    padding: 1rem;
    background: rgba(255,255,255,0.03);
    border: 1px dashed rgba(255,255,255,0.15);
    border-radius: 8px;
    color: rgba(255,255,255,0.65);
    font-size: 0.88rem;
    text-align: center;
}
.hd-nav-card__empty a {
    color: var(--gold);
    font-weight: 500;
}

/* ─── Badges tier ─── */
.hd-nav-card__tier {
    display: inline-block;
    margin-left: 0.4rem;
    padding: 0.1rem 0.5rem;
    font-size: 0.65rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    border-radius: 10px;
    vertical-align: middle;
    font-weight: 600;
}
.hd-nav-card__tier--pro {
    background: linear-gradient(135deg, var(--gold), #8b6914);
    color: #050c1c;
}
.hd-nav-card__tier--premium {
    background: rgba(201,168,76,0.2);
    border: 1px solid rgba(201,168,76,0.5);
    color: var(--gold);
}

.hd-nav-card__subtitle strong {
    color: var(--gold);
}

.hd-nav-card__hint {
    margin: 0.5rem 0 0;
    font-size: 0.78rem;
    color: rgba(255,255,255,0.55);
    font-style: italic;
}
.hd-nav-card__hint a {
    color: var(--gold);
    font-weight: 500;
    text-decoration: underline;
}

/* ─── Gate (Free ou Premium sans Mon BG) ─── */
.hd-nav-card__gate {
    padding: 1.25rem 1.1rem;
    background: rgba(0,0,0,0.15);
    border: 1px solid rgba(201,168,76,0.2);
    border-radius: 10px;
    text-align: center;
}
.hd-nav-card__gate-title {
    margin: 0 0 0.5rem;
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--gold);
}
.hd-nav-card__gate-text {
    margin: 0 0 1rem;
    font-size: 0.85rem;
    line-height: 1.55;
    color: rgba(255,255,255,0.7);
}
.hd-nav-card__gate-text strong {
    color: var(--gold);
}
.hd-nav-card__gate-btn {
    display: inline-block;
    padding: 0.55rem 1.4rem;
    background: var(--gold);
    color: #fff; text-shadow: 0 1px 2px rgba(0,0,0,0.25);
    border-radius: 20px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.87rem;
    letter-spacing: 0.03em;
    transition: all 0.2s;
}
.hd-nav-card__gate-btn:hover {
    background: #e0bd5e;
    transform: translateY(-1px);
    text-decoration: none;
}
.hd-nav-card__gate-hint {
    margin: 1rem 0 0;
    font-size: 0.78rem;
    color: rgba(255,255,255,0.78);
    font-style: italic;
}
.hd-nav-card__gate-hint a {
    color: var(--gold);
    font-weight: 500;
}

/* Mode free : card en version « preview » (légèrement désaturée) */
.hd-nav-card--free .hd-nav-card__desc {
    opacity: 0.6;
}

/* ─── Light mode (mode jour) overrides ─── */
body.light-mode .hd-nav-card {
    background: linear-gradient(135deg, rgba(139,105,20,0.06), rgba(139,105,20,0.02));
    border-color: rgba(139,105,20,0.32);
}
body.light-mode .hd-nav-card::before {
    background: radial-gradient(ellipse at top right, rgba(139,105,20,0.08), transparent 60%);
}
body.light-mode .hd-nav-card__icon {
    background: rgba(139,105,20,0.1);
    border-color: rgba(139,105,20,0.35);
    color: #8b6914;
}
body.light-mode .hd-nav-card__title { color: #1a1a1a; }
body.light-mode .hd-nav-card__subtitle { color: rgba(0,0,0,0.6); }
body.light-mode .hd-nav-card__subtitle strong { color: #8b6914; }
body.light-mode .hd-nav-card__desc { color: rgba(0,0,0,0.72); }
body.light-mode .hd-nav-card__toggle-text { color: #1a1a1a; }
body.light-mode .hd-nav-card__toggle input { accent-color: #8b6914; }
body.light-mode .hd-nav-card__label { color: rgba(0,0,0,0.55); }
body.light-mode .hd-nav-card__select {
    background: #fff;
    border-color: rgba(0,0,0,0.18);
    color: #1a1a1a;
}
body.light-mode .hd-nav-card__select:focus { border-color: #8b6914; }
body.light-mode .hd-nav-card__submit {
    background: #8b6914;
    color: #fff;
}
body.light-mode .hd-nav-card__submit:hover:not(:disabled) { background: #a37e1c; }
body.light-mode .hd-nav-card__status { color: rgba(0,0,0,0.65); }
body.light-mode .hd-nav-card__empty {
    background: rgba(0,0,0,0.03);
    border-color: rgba(0,0,0,0.18);
    color: rgba(0,0,0,0.65);
}
body.light-mode .hd-nav-card__empty a { color: #8b6914; }
body.light-mode .hd-nav-card__hint { color: rgba(0,0,0,0.55); }
body.light-mode .hd-nav-card__hint a { color: #8b6914; }
body.light-mode .hd-nav-card__tier--premium {
    background: rgba(139,105,20,0.12);
    border-color: rgba(139,105,20,0.5);
    color: #8b6914;
}
body.light-mode .hd-nav-card__gate {
    background: rgba(0,0,0,0.04);
    border-color: rgba(139,105,20,0.25);
}
body.light-mode .hd-nav-card__gate-title { color: #8b6914; }
body.light-mode .hd-nav-card__gate-text { color: rgba(0,0,0,0.72); }
body.light-mode .hd-nav-card__gate-text strong { color: #8b6914; }
body.light-mode .hd-nav-card__gate-btn {
    background: #8b6914;
    color: #fff;
}
body.light-mode .hd-nav-card__gate-btn:hover { background: #a37e1c; }
body.light-mode .hd-nav-card__gate-hint { color: rgba(0,0,0,0.55); }
body.light-mode .hd-nav-card__gate-hint a { color: #8b6914; }

/* ═══════════════════════════════════════════════════════════
   Section « Pour vous » - contenu riche d'interprétation
   (affichée sous le banner sur porte/canal/centre)
   ═══════════════════════════════════════════════════════════ */

.hd-nav-deep {
    margin: 1.75rem 0 2.25rem;
    padding: 2rem 1.75rem;
    background:
        radial-gradient(ellipse at top left, rgba(201,168,76,0.15), transparent 65%),
        linear-gradient(135deg, #1a2340 0%, #0b1428 100%);
    border: 1px solid rgba(201,168,76,0.45);
    border-radius: 16px;
    position: relative;
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.08),
        0 8px 30px rgba(0,0,0,0.3),
        0 0 0 1px rgba(201,168,76,0.1);
    overflow: hidden;
}
/* Variante « merged » (banner fusionné) : padding plus compact car le
   header doit pouvoir rester visible seul sans paraître énorme. */
.hd-nav-deep--merged {
    padding: 1.4rem 1.5rem;
    margin: 1.25rem 0 1.75rem;
}
.hd-nav-deep::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--gold), transparent);
}

.hd-nav-deep--defined {
    background:
        radial-gradient(ellipse at top left, rgba(139,195,74,0.18), transparent 65%),
        linear-gradient(135deg, #1b3a20 0%, #0f2814 100%);
    border-color: rgba(102,187,106,0.55);
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.1),
        0 8px 30px rgba(46,125,50,0.25),
        0 0 0 1px rgba(102,187,106,0.15);
}
.hd-nav-deep--defined::before {
    background: linear-gradient(90deg, transparent, #8bc34a, transparent);
}
[class*="hd-nav-archive--"]::before { display: none; }

.hd-nav-deep--open,
.hd-nav-deep--inactive {
    background:
        radial-gradient(ellipse at top left, rgba(120,144,220,0.1), transparent 65%),
        linear-gradient(135deg, #141b30 0%, #0b1428 100%);
    border-color: rgba(120,144,220,0.35);
}

.hd-nav-deep--half {
    background:
        radial-gradient(ellipse at top left, rgba(255,183,77,0.18), transparent 65%),
        linear-gradient(135deg, #2e2418 0%, #1a140e 100%);
    border-color: rgba(255,183,77,0.55);
}
.hd-nav-deep--half::before {
    background: linear-gradient(90deg, transparent, #ffb74d, transparent);
}

.hd-nav-deep__header {
    margin-bottom: 1.25rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid rgba(255,255,255,0.08);
    cursor: pointer;
    user-select: none;
    transition: border-color 0.2s;
}
.hd-nav-deep__header:hover {
    border-bottom-color: rgba(201,168,76,0.35);
}

/* ── Header fusionné (banner + "Pour vous") : icône + titre + détail + actions ── */
.hd-nav-deep__header--merged {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 1rem;
    align-items: center;
    padding-right: 0;
}
.hd-nav-deep__icon {
    font-size: 1.6rem;
    line-height: 1;
    flex-shrink: 0;
    color: var(--gold, #c9a84c);
    width: 42px;
    height: 42px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(201,168,76,0.1);
    border: 1px solid rgba(201,168,76,0.3);
}
.hd-nav-deep--defined .hd-nav-deep__icon {
    color: #81c784;
    background: rgba(129,199,132,0.12);
    border-color: rgba(129,199,132,0.4);
}
.hd-nav-deep--inactive .hd-nav-deep__icon {
    color: rgba(255,255,255,0.78);
    background: rgba(255,255,255,0.04);
    border-color: rgba(255,255,255,0.12);
}
.hd-nav-deep__headline {
    min-width: 0;
}
.hd-nav-deep__source-note {
    margin: 0 0 0.4rem;
    font-size: 0.72rem;
    line-height: 1.35;
    color: #aed581;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-weight: 500;
}
.hd-nav-deep__source-note span {
    display: inline-block;
    margin-right: 0.25rem;
    opacity: 0.9;
}
.hd-nav-deep__source-note strong {
    color: #fff;
    font-weight: 700;
    letter-spacing: 0.06em;
}
.hd-nav-deep__source-note em {
    color: #fff;
    font-style: normal;
    font-weight: 600;
    text-transform: none;
    letter-spacing: 0;
}
body.light-mode .hd-nav-deep__source-note {
    color: #2e7d32;
}
body.light-mode .hd-nav-deep__source-note strong,
body.light-mode .hd-nav-deep__source-note em {
    color: #1b2e0f;
}
.hd-nav-deep__header--merged .hd-nav-deep__title {
    margin: 0;
    font-size: 1.05rem;
    font-weight: 500;
    line-height: 1.35;
    color: #fff;
    letter-spacing: 0;
}
.hd-nav-deep__header--merged .hd-nav-deep__title strong {
    color: var(--gold, #c9a84c);
    font-weight: 700;
}
.hd-nav-deep--defined .hd-nav-deep__header--merged .hd-nav-deep__title strong {
    color: #a5d6a7;
}
.hd-nav-deep__detail {
    margin: 0.25rem 0 0;
    font-size: 0.85rem;
    line-height: 1.5;
    color: rgba(255,255,255,0.65);
}
.hd-nav-deep__detail strong {
    color: rgba(255,255,255,0.9);
    font-weight: 600;
}
.hd-nav-deep__detail em {
    color: var(--gold, #c9a84c);
    font-style: normal;
}

/* ═══════════════════════════════════════════════════════════════════
 * Synthèse du BG sélectionné - chips cliquables vers les CPT
 * Style "web3 like" : glassmorphism, gradient subtil, hover halo.
 * Chaque chip lie vers son CPT (type_hd, profil, definition_hd,
 * autorite, croix) via HD_Nav_BG::*_url() helpers.
 * ═══════════════════════════════════════════════════════════════════ */
.hd-nav-deep__bg-info {
    list-style: none;
    margin: 0.85rem 0 0.35rem;
    padding: 0.7rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    align-items: stretch;
    background:
        radial-gradient(ellipse at top left,  rgba(174,213,129,0.08), transparent 60%),
        radial-gradient(ellipse at bottom right, rgba(201,168,76,0.06), transparent 60%),
        rgba(255,255,255,0.02);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 14px;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.04);
    position: relative;
    overflow: hidden;
}
.hd-nav-deep__bg-info::before {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: linear-gradient(135deg, rgba(129,199,132,0.06) 0%, transparent 40%, rgba(201,168,76,0.04) 100%);
    opacity: 0.7;
}

.hd-nav-deep__bg-info-item {
    position: relative;
    display: flex;
    align-items: center;
    font-size: 0.8rem;
    line-height: 1.3;
    min-height: 38px;
}

/* Chip cliquable - lien vers CPT */
.hd-nav-deep__bg-info-link {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.42rem 0.75rem;
    border-radius: 999px;
    background: linear-gradient(135deg, rgba(129,199,132,0.1), rgba(201,168,76,0.08));
    border: 1px solid rgba(174,213,129,0.22);
    color: inherit;
    text-decoration: none;
    transition: border-color 0.2s ease, background 0.2s ease, transform 0.18s ease, box-shadow 0.22s ease;
    white-space: nowrap;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
}
.hd-nav-deep__bg-info-link::after {
    content: "";
    position: absolute;
    inset: -1px;
    border-radius: inherit;
    pointer-events: none;
    background: linear-gradient(120deg, transparent 0%, rgba(174,213,129,0.35) 50%, transparent 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
    mix-blend-mode: overlay;
}
.hd-nav-deep__bg-info-link:hover,
.hd-nav-deep__bg-info-link:focus-visible {
    border-color: rgba(174,213,129,0.6);
    background: linear-gradient(135deg, rgba(129,199,132,0.22), rgba(201,168,76,0.15));
    transform: translateY(-1px);
    box-shadow:
        0 6px 16px rgba(46,125,50,0.2),
        0 0 0 1px rgba(174,213,129,0.4),
        inset 0 1px 0 rgba(255,255,255,0.08);
    outline: none;
    text-decoration: none;
}
.hd-nav-deep__bg-info-link:hover::after,
.hd-nav-deep__bg-info-link:focus-visible::after {
    opacity: 1;
}
.hd-nav-deep__bg-info-link:hover .hd-nav-deep__bg-info-icon,
.hd-nav-deep__bg-info-link:focus-visible .hd-nav-deep__bg-info-icon {
    transform: translate(2px, -2px);
    opacity: 1;
}

/* Chip non-cliquable (pas de CPT résolu) */
.hd-nav-deep__bg-info-item.is-static {
    padding: 0.42rem 0.75rem;
    border-radius: 999px;
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.06);
    gap: 0.5rem;
}

.hd-nav-deep__bg-info-label {
    font-size: 0.62rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: rgba(174,213,129,0.75);
    font-weight: 600;
    flex-shrink: 0;
}
.hd-nav-deep__bg-info-value {
    font-family: var(--font-heading, 'Cormorant Garamond', serif);
    font-size: 0.98rem;
    color: #fff;
    font-weight: 500;
    letter-spacing: 0.01em;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    min-width: 0;
}
.hd-nav-deep__bg-info-icon {
    flex-shrink: 0;
    color: rgba(174,213,129,0.55);
    opacity: 0.75;
    transition: transform 0.18s ease, opacity 0.18s ease;
}

/* Croix : chip occupant toute la largeur (sur sa propre ligne) */
.hd-nav-deep__bg-info-item--cross {
    flex: 1 1 100%;
}
.hd-nav-deep__bg-info-item--cross .hd-nav-deep__bg-info-link,
.hd-nav-deep__bg-info-item--cross.is-static {
    width: 100%;
    justify-content: flex-start;
}
.hd-nav-deep__bg-info-item--cross .hd-nav-deep__bg-info-value {
    font-style: italic;
    font-size: 1.02rem;
}

/* Light mode */
body.light-mode .hd-nav-deep__bg-info {
    background:
        radial-gradient(ellipse at top left, rgba(76,175,80,0.08), transparent 60%),
        radial-gradient(ellipse at bottom right, rgba(201,168,76,0.05), transparent 60%),
        rgba(255,255,255,0.6);
    border-color: rgba(46,125,50,0.18);
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.4), 0 1px 2px rgba(46,125,50,0.05);
}
body.light-mode .hd-nav-deep__bg-info::before {
    background: linear-gradient(135deg, rgba(76,175,80,0.06) 0%, transparent 40%, rgba(139,105,20,0.04) 100%);
}
body.light-mode .hd-nav-deep__bg-info-link {
    background: linear-gradient(135deg, rgba(76,175,80,0.1), rgba(139,105,20,0.06));
    border-color: rgba(46,125,50,0.25);
    color: #1b2e0f;
}
body.light-mode .hd-nav-deep__bg-info-link:hover,
body.light-mode .hd-nav-deep__bg-info-link:focus-visible {
    border-color: rgba(46,125,50,0.5);
    background: linear-gradient(135deg, rgba(76,175,80,0.18), rgba(139,105,20,0.1));
    box-shadow:
        0 6px 16px rgba(46,125,50,0.12),
        0 0 0 1px rgba(46,125,50,0.3),
        inset 0 1px 0 rgba(255,255,255,0.5);
}
body.light-mode .hd-nav-deep__bg-info-item.is-static {
    background: rgba(0,0,0,0.03);
    border-color: rgba(0,0,0,0.06);
}
body.light-mode .hd-nav-deep__bg-info-label { color: rgba(46,125,50,0.85); }
body.light-mode .hd-nav-deep__bg-info-value { color: #1b2e0f; }
body.light-mode .hd-nav-deep__bg-info-icon { color: rgba(46,125,50,0.55); }

/* Responsive : repli en stack vertical sur mobile */
@media (max-width: 640px) {
    .hd-nav-deep__bg-info {
        padding: 0.55rem;
        gap: 0.4rem;
        border-radius: 12px;
    }
    .hd-nav-deep__bg-info-item { width: 100%; }
    .hd-nav-deep__bg-info-link,
    .hd-nav-deep__bg-info-item.is-static {
        width: 100%;
        padding: 0.5rem 0.75rem;
        border-radius: 10px;
        justify-content: space-between;
    }
    .hd-nav-deep__bg-info-value { font-size: 0.92rem; }
    .hd-nav-deep__bg-info-item--cross .hd-nav-deep__bg-info-value { font-size: 0.95rem; }
}

@media (prefers-reduced-motion: reduce) {
    .hd-nav-deep__bg-info-link,
    .hd-nav-deep__bg-info-link::after,
    .hd-nav-deep__bg-info-icon {
        transition: none;
    }
    .hd-nav-deep__bg-info-link:hover,
    .hd-nav-deep__bg-info-link:focus-visible {
        transform: none;
    }
}

.hd-nav-deep__actions {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    flex-shrink: 0;
}
.hd-nav-deep__manage {
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: rgba(255,255,255,0.55);
    text-decoration: none;
    padding: 0.32rem 0.7rem;
    border: 1px solid rgba(255,255,255,0.14);
    border-radius: 999px;
    transition: color 0.18s, border-color 0.18s, background 0.18s;
    white-space: nowrap;
}
.hd-nav-deep__manage:hover {
    color: var(--gold, #c9a84c);
    border-color: rgba(201,168,76,0.55);
    background: rgba(201,168,76,0.08);
}
.hd-nav-deep__close {
    width: 30px;
    height: 30px;
    padding: 0;
    background: transparent;
    border: 1px solid rgba(255,255,255,0.14);
    border-radius: 50%;
    color: rgba(255,255,255,0.78);
    font-size: 1.15rem;
    line-height: 1;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.18s, border-color 0.18s, background 0.18s;
    flex-shrink: 0;
}
.hd-nav-deep__close:hover {
    color: #f0a0a0;
    border-color: rgba(240,160,160,0.5);
    background: rgba(240,160,160,0.08);
}

@media (max-width: 640px) {
    .hd-nav-deep__header--merged {
        grid-template-columns: auto 1fr;
        grid-template-areas:
            "icon headline"
            "actions actions";
    }
    .hd-nav-deep__header--merged .hd-nav-deep__icon { grid-area: icon; }
    .hd-nav-deep__header--merged .hd-nav-deep__headline { grid-area: headline; }
    .hd-nav-deep__header--merged .hd-nav-deep__actions {
        grid-area: actions;
        justify-content: flex-end;
        padding-top: 0.5rem;
        border-top: 1px solid rgba(255,255,255,0.06);
        margin-top: 0.25rem;
    }
}

/* Light mode */
body.light-mode .hd-nav-deep__header--merged .hd-nav-deep__title {
    color: #101a2e;
}
body.light-mode .hd-nav-deep__detail {
    color: rgba(0,0,0,0.6);
}
body.light-mode .hd-nav-deep__manage {
    color: rgba(0,0,0,0.6);
    border-color: rgba(0,0,0,0.2);
}
body.light-mode .hd-nav-deep__close {
    color: rgba(0,0,0,0.5);
    border-color: rgba(0,0,0,0.2);
}
.hd-nav-deep__header:hover {
    border-bottom-color: rgba(201,168,76,0.35);
}

/* Bouton toggle (chevron) injecté par JS - en flow dans la rangée d'actions */
.hd-nav-deep__toggle {
    width: 30px;
    height: 30px;
    padding: 0;
    background: rgba(201,168,76,0.12);
    border: 1px solid rgba(201,168,76,0.35);
    border-radius: 50%;
    color: var(--gold, #c9a84c);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, border-color 0.2s;
    flex-shrink: 0;
}
.hd-nav-deep__toggle:hover {
    background: rgba(201,168,76,0.22);
    border-color: rgba(201,168,76,0.6);
}
.hd-nav-deep__toggle svg {
    width: 14px;
    height: 14px;
    transition: transform 0.3s ease;
}
.hd-nav-deep.is-collapsed .hd-nav-deep__toggle svg {
    transform: rotate(-90deg);
}

/* État replié : masque uniquement le body (le header reste visible) */
.hd-nav-deep.is-collapsed {
    padding-top: 1.25rem;
    padding-bottom: 1.25rem;
}
.hd-nav-deep.is-collapsed .hd-nav-deep__header {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom-color: transparent;
}
.hd-nav-deep.is-collapsed .hd-nav-deep__body {
    display: none;
}

/* Variante verte (état "defined") : chevron vert */
.hd-nav-deep--defined .hd-nav-deep__toggle {
    background: rgba(129,199,132,0.15);
    border-color: rgba(129,199,132,0.4);
    color: #81c784;
}
.hd-nav-deep--defined .hd-nav-deep__toggle:hover {
    background: rgba(129,199,132,0.28);
    border-color: rgba(129,199,132,0.7);
}

.hd-nav-deep__pill {
    display: inline-block;
    font-size: 0.7rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: #050c1c;
    background: linear-gradient(135deg, #e0bd5e 0%, var(--gold) 100%);
    border: 1px solid rgba(255,255,255,0.25);
    padding: 0.3rem 0.85rem;
    border-radius: 14px;
    margin-bottom: 1rem;
    font-weight: 700;
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.3),
        0 2px 6px rgba(201,168,76,0.35);
}
.hd-nav-deep--defined .hd-nav-deep__pill {
    color: #fff;
    background: linear-gradient(135deg, #81c784 0%, #388e3c 100%);
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.3),
        0 2px 6px rgba(46,125,50,0.45);
}

.hd-nav-deep__title {
    margin: 0;
    font-size: 1.35rem;
    font-weight: 500;
    line-height: 1.4;
    color: #fff;
    letter-spacing: 0.01em;
}
.hd-nav-deep--defined .hd-nav-deep__title {
    color: #f1f8e9;
}

.hd-nav-deep__body {
    font-size: 0.95rem;
    line-height: 1.7;
    color: rgba(255,255,255,0.92);
}
.hd-nav-deep--defined .hd-nav-deep__body {
    color: rgba(241,248,233,0.95);
}

.hd-nav-deep__section {
    margin-bottom: 1.25rem;
}
.hd-nav-deep__section:last-child {
    margin-bottom: 0;
}

.hd-nav-deep__subtitle {
    margin: 0 0 0.4rem;
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--gold);
    letter-spacing: 0.02em;
}
.hd-nav-deep--defined .hd-nav-deep__subtitle {
    color: #9ccc65;
}

.hd-nav-deep__p {
    margin: 0 0 0.7rem;
}
.hd-nav-deep__p:last-child {
    margin-bottom: 0;
}
.hd-nav-deep__p strong {
    color: var(--gold);
    font-weight: 600;
}
.hd-nav-deep--defined .hd-nav-deep__p strong {
    color: #aed581;
}
.hd-nav-deep__p em {
    color: rgba(255,255,255,0.9);
    font-style: italic;
}

/* Signature de la variante - paragraphe spécifique à CETTE
   croix parmi les 192, rendu comme citation stylisée */
.hd-nav-deep__signature {
    margin: 0.9rem 0 1rem;
    padding: 0.85rem 1.1rem;
    border-left: 3px solid var(--gold);
    background: rgba(201,168,76,0.08);
    border-radius: 0 8px 8px 0;
    font-size: 0.95rem;
    line-height: 1.7;
    font-style: italic;
    color: rgba(255,255,255,0.95);
}
.hd-nav-deep--defined .hd-nav-deep__signature {
    border-left-color: #aed581;
    background: rgba(129,199,132,0.1);
}

.hd-nav-deep__body ul:not(.hd-nav-deep__nav-list) {
    margin: 0.5rem 0 0.8rem;
    padding-left: 1.4rem;
    list-style: none;
}
.hd-nav-deep__body ul:not(.hd-nav-deep__nav-list) li {
    position: relative;
    margin-bottom: 0.55rem;
    padding-left: 0.25rem;
}
.hd-nav-deep__body ul:not(.hd-nav-deep__nav-list) li::before {
    display: none;
}
.hd-nav-deep--defined .hd-nav-deep__body ul:not(.hd-nav-deep__nav-list) li::before {
    display: none;
}
.hd-nav-deep__body ul:not(.hd-nav-deep__nav-list) li strong {
    color: var(--gold);
}
.hd-nav-deep--defined .hd-nav-deep__body ul:not(.hd-nav-deep__nav-list) li strong {
    color: #aed581;
}

/* ─── Bloc « Naviguer » avec liens internes ─── */
.hd-nav-deep__nav {
    margin-top: 1.5rem;
    padding: 1rem 1.1rem;
    background: rgba(0,0,0,0.2);
    border: 1px solid rgba(201,168,76,0.18);
    border-radius: 10px;
}
.hd-nav-deep--defined .hd-nav-deep__nav {
    background: rgba(0,0,0,0.2);
    border-color: rgba(102,187,106,0.25);
}

.hd-nav-deep__nav-title {
    margin: 0 0 0.75rem;
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: rgba(255,255,255,0.6);
}

.hd-nav-deep__nav-subtitle {
    margin: 1rem 0 0.5rem;
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}
.hd-nav-deep__nav-subtitle:first-child { margin-top: 0; }
.hd-nav-deep__nav-subtitle--defined { color: #aed581; }
.hd-nav-deep__nav-subtitle--open { color: #90caf9; }
body.light-mode .hd-nav-deep__nav-subtitle--defined { color: #388e3c; }
body.light-mode .hd-nav-deep__nav-subtitle--open { color: #1565c0; }

.hd-nav-deep__nav-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 0.5rem;
}

.hd-nav-deep__nav-item {
    margin: 0;
    padding: 0;
}

.hd-nav-deep__nav-link {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.55rem 0.75rem;
    background: rgba(255,255,255,0.025);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 8px;
    text-decoration: none;
    transition: all 0.2s;
    min-height: 48px;
}
.hd-nav-deep__nav-link:hover {
    background: rgba(201,168,76,0.08);
    border-color: rgba(201,168,76,0.4);
    transform: translateX(2px);
    text-decoration: none;
}

.hd-nav-deep__nav-icon {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    font-size: 0.85rem;
    color: var(--gold);
    background: rgba(201,168,76,0.12);
    border-radius: 50%;
    font-weight: 600;
}
.hd-nav-deep--defined .hd-nav-deep__nav-icon {
    color: #8bc34a;
    background: rgba(76,175,80,0.15);
}

.hd-nav-deep__nav-label {
    flex: 1;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--gold);
    line-height: 1.3;
}
.hd-nav-deep--defined .hd-nav-deep__nav-label {
    color: #aed581;
}

.hd-nav-deep__nav-meta {
    flex-shrink: 0;
    font-size: 0.7rem;
    color: rgba(255,255,255,0.78);
    font-style: italic;
    text-align: right;
    max-width: 140px;
}

@media (max-width: 640px) {
    .hd-nav-deep {
        padding: 1.25rem 1rem;
    }
    .hd-nav-deep__title {
        font-size: 1.1rem;
    }
    .hd-nav-deep__body {
        font-size: 0.88rem;
    }
    .hd-nav-deep__nav-list {
        grid-template-columns: 1fr;
    }
    .hd-nav-deep__nav-meta {
        max-width: 100px;
    }
}

body.light-mode .hd-nav-deep__nav {
    background: rgba(0,0,0,0.025);
    border-color: rgba(139,105,20,0.2);
}
body.light-mode .hd-nav-deep--defined .hd-nav-deep__nav {
    background: rgba(0,0,0,0.025);
    border-color: rgba(76,175,80,0.3);
}
body.light-mode .hd-nav-deep__nav-title {
    color: rgba(0,0,0,0.55);
}
body.light-mode .hd-nav-deep__nav-link {
    background: rgba(0,0,0,0.02);
    border-color: rgba(0,0,0,0.08);
}
body.light-mode .hd-nav-deep__nav-link:hover {
    background: rgba(201,168,76,0.08);
    border-color: rgba(139,105,20,0.4);
}
body.light-mode .hd-nav-deep__nav-icon {
    color: #8b6914;
    background: rgba(201,168,76,0.18);
}
body.light-mode .hd-nav-deep--defined .hd-nav-deep__nav-icon {
    color: #2e7d32;
    background: rgba(76,175,80,0.18);
}
body.light-mode .hd-nav-deep__nav-label {
    color: #8b6914;
}
body.light-mode .hd-nav-deep--defined .hd-nav-deep__nav-label {
    color: #2e7d32;
}
body.light-mode .hd-nav-deep__nav-meta {
    color: rgba(0,0,0,0.5);
}

/* ─── Mode jour ─── */
body.light-mode .hd-nav-deep {
    background:
        radial-gradient(ellipse at top left, rgba(201,168,76,0.18), transparent 65%),
        linear-gradient(135deg, #fdf7e8 0%, #f5edd1 100%);
    border: 1px solid rgba(139,105,20,0.45);
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.6),
        0 8px 28px rgba(139,105,20,0.18);
}
body.light-mode .hd-nav-deep::before {
    background: linear-gradient(90deg, transparent, #8b6914, transparent);
}
body.light-mode .hd-nav-deep--defined {
    background:
        radial-gradient(ellipse at top left, rgba(76,175,80,0.2), transparent 65%),
        linear-gradient(135deg, #f1f8e9 0%, #dcedc8 100%);
    border-color: rgba(46,125,50,0.5);
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.6),
        0 8px 28px rgba(46,125,50,0.2);
}
body.light-mode .hd-nav-deep--defined::before {
    background: linear-gradient(90deg, transparent, #2e7d32, transparent);
}
body.light-mode .hd-nav-deep--open,
body.light-mode .hd-nav-deep--inactive {
    background: linear-gradient(135deg, #f5f7fa 0%, #e8edf3 100%);
    border-color: rgba(60,80,140,0.35);
}
body.light-mode .hd-nav-deep--half {
    background:
        radial-gradient(ellipse at top left, rgba(255,152,0,0.18), transparent 65%),
        linear-gradient(135deg, #fff8e1 0%, #ffe0b2 100%);
    border-color: rgba(230,130,0,0.55);
}
body.light-mode .hd-nav-deep--half::before {
    background: linear-gradient(90deg, transparent, #e68200, transparent);
}
body.light-mode .hd-nav-deep__header {
    border-bottom-color: rgba(0,0,0,0.15);
}
body.light-mode .hd-nav-deep__pill {
    color: #fff;
    background: linear-gradient(135deg, var(--gold) 0%, #8b6914 100%);
    border-color: rgba(255,255,255,0.4);
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.4),
        0 2px 6px rgba(139,105,20,0.4);
}
body.light-mode .hd-nav-deep--defined .hd-nav-deep__pill {
    color: #fff;
    background: linear-gradient(135deg, #66bb6a 0%, #2e7d32 100%);
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.4),
        0 2px 6px rgba(46,125,50,0.4);
}
body.light-mode .hd-nav-deep__title {
    color: #1a1a2e;
}
body.light-mode .hd-nav-deep--defined .hd-nav-deep__title {
    color: #1b2e0f;
}
body.light-mode .hd-nav-deep__body {
    color: #2a2a3e;
}
body.light-mode .hd-nav-deep--defined .hd-nav-deep__body {
    color: #1b2e0f;
}
body.light-mode .hd-nav-deep__subtitle {
    color: #8b6914;
}
body.light-mode .hd-nav-deep--defined .hd-nav-deep__subtitle {
    color: #2e7d32;
}
body.light-mode .hd-nav-deep__p strong {
    color: #8b6914;
}
body.light-mode .hd-nav-deep--defined .hd-nav-deep__p strong {
    color: #2e7d32;
}
body.light-mode .hd-nav-deep__p em {
    color: rgba(0,0,0,0.85);
}
body.light-mode .hd-nav-deep__signature {
    color: #2a2a3e;
    background: rgba(201,168,76,0.12);
    border-left-color: #8b6914;
}
body.light-mode .hd-nav-deep--defined .hd-nav-deep__signature {
    background: rgba(129,199,132,0.15);
    border-left-color: #2e7d32;
    color: #1b2e0f;
}
body.light-mode .hd-nav-deep__body ul:not(.hd-nav-deep__nav-list) li::before {
    display: none;
}
body.light-mode .hd-nav-deep--defined .hd-nav-deep__body ul:not(.hd-nav-deep__nav-list) li::before {
    display: none;
}
body.light-mode .hd-nav-deep__body ul:not(.hd-nav-deep__nav-list) li strong {
    color: #8b6914;
}
body.light-mode .hd-nav-deep--defined .hd-nav-deep__body ul:not(.hd-nav-deep__nav-list) li strong {
    color: #2e7d32;
}

/* ═══════════════ Mode jour ═══════════════ */
body.light-mode .hd-nav-banner {
    background: linear-gradient(135deg, #fdf7e8 0%, #f5edd1 100%);
    border: 1px solid rgba(139,105,20,0.4);
    border-left: 4px solid #8b6914;
    color: #3d2b0d;
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.6),
        0 4px 16px rgba(139,105,20,0.15);
}
body.light-mode .hd-nav-banner::before {
    background: linear-gradient(90deg, transparent, #8b6914, transparent);
}
body.light-mode .hd-nav-banner--active {
    background: linear-gradient(135deg, #f1f8e9 0%, #dcedc8 100%);
    border-color: rgba(46,125,50,0.5);
    border-left-color: #2e7d32;
    color: #1b2e0f;
}
body.light-mode .hd-nav-banner__icon {
    color: #fff;
    background: linear-gradient(135deg, #e0bd5e 0%, #8b6914 100%);
    border-color: rgba(255,255,255,0.78);
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.5),
        0 2px 8px rgba(139,105,20,0.4);
}
body.light-mode .hd-nav-banner--active .hd-nav-banner__icon {
    background: linear-gradient(135deg, #66bb6a 0%, #2e7d32 100%);
}
body.light-mode .hd-nav-banner__title {
    color: #1a1a2e;
}
body.light-mode .hd-nav-banner__title strong {
    color: #8b6914;
}
body.light-mode .hd-nav-banner--active .hd-nav-banner__title strong {
    color: #2e7d32;
}
body.light-mode .hd-nav-banner__detail {
    color: #4a3517;
}
body.light-mode .hd-nav-banner__detail strong {
    color: #8b6914;
}
body.light-mode .hd-nav-banner--active .hd-nav-banner__detail strong {
    color: #2e7d32;
}
body.light-mode .hd-nav-banner__link {
    color: #4a3517;
    border-color: rgba(139,105,20,0.35);
    background: rgba(255,255,255,0.5);
}
body.light-mode .hd-nav-banner__link:hover {
    color: #8b6914;
    border-color: #8b6914;
    background: rgba(201,168,76,0.12);
}

body.light-mode .hd-nav-float {
    background: #fafaf7;
    border-color: rgba(139,105,20,0.35);
    box-shadow: 0 8px 32px rgba(0,0,0,0.15), 0 0 20px rgba(201,168,76,0.2);
}
body.light-mode .hd-nav-float__mode {
    color: #8b6914;
}
body.light-mode .hd-nav-float__name {
    color: #8b6914;
}
body.light-mode .hd-nav-float__meta,
body.light-mode .hd-nav-float__hint {
    color: rgba(0,0,0,0.6);
}
body.light-mode .hd-nav-float__selector-label {
    color: rgba(0,0,0,0.5);
}
body.light-mode .hd-nav-float__select {
    background: rgba(0,0,0,0.03);
    border-color: rgba(0,0,0,0.15);
    color: #222;
}
body.light-mode .hd-nav-float__close {
    background: rgba(198,40,40,0.08);
    border-color: rgba(198,40,40,0.35);
    color: #c62828;
}
body.light-mode .hd-nav-float__close:hover {
    background: rgba(198,40,40,0.18);
    border-color: rgba(198,40,40,0.6);
    color: #a61f1f;
}
body.light-mode .hd-nav-float__view {
    background: linear-gradient(135deg, rgba(139,105,20,0.14), rgba(139,105,20,0.06));
    border-color: rgba(139,105,20,0.4);
    color: #8b6914;
}
body.light-mode .hd-nav-float__view:hover {
    background: linear-gradient(135deg, rgba(139,105,20,0.22), rgba(139,105,20,0.1));
    border-color: rgba(139,105,20,0.6);
}

/* ══════════════════════════════════════════════════════════════
   Bloc Nav BG sur /celebrites/ - grille de cards avec photos
   Variante .hd-nav-deep--celebrite : réutilise le fond vert du bandeau
   et ajoute une liste de cards célébrités matchantes.
   ══════════════════════════════════════════════════════════════ */
.hd-nav-deep--celebrite {
    max-width: 1240px;
    margin-left: auto;
    margin-right: auto;
}
.hd-nav-deep__celeb-list {
    list-style: none;
    padding: 0;
    margin: 1rem 0 0;
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 0.85rem;
}
.hd-nav-deep__celeb-item { margin: 0; }

.hd-nav-deep__celeb-card {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    padding: 0.6rem;
    border-radius: 10px;
    background: rgba(76,175,80,0.08);
    border: 1px solid rgba(76,175,80,0.35);
    color: #fff;
    text-decoration: none;
    transition: transform 0.18s ease, background 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
    min-height: 100%;
}
.hd-nav-deep__celeb-card:hover,
.hd-nav-deep__celeb-card:focus-visible {
    transform: translateY(-2px);
    background: rgba(76,175,80,0.15);
    border-color: rgba(76,175,80,0.6);
    box-shadow: 0 8px 22px rgba(46,125,50,0.3);
    outline: 2px solid rgba(174,213,129,0.5);
    outline-offset: 2px;
    text-decoration: none;
}
.hd-nav-deep__celeb-photo {
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    border-radius: 6px;
    border: 1px solid rgba(255,255,255,0.08);
    display: block;
}
.hd-nav-deep__celeb-body {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    min-width: 0;
    text-align: center;
    align-items: center;
}
.hd-nav-deep__celeb-name {
    font-weight: 600;
    font-size: 0.88rem;
    line-height: 1.25;
    color: #fff;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.hd-nav-deep__celeb-meta {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.25rem 0.5rem;
    font-size: 0.7rem;
    color: #aed581;
    line-height: 1.3;
}
.hd-nav-deep__celeb-cross {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: baseline;
    justify-content: center;
    gap: 0.3rem;
    margin-top: 0.2rem;
    font-size: 0.68rem;
    line-height: 1.3;
    color: rgba(255,255,255,0.78);
    font-style: italic;
}
.hd-nav-deep__celeb-cross-label {
    font-size: 0.58rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: rgba(174,213,129,0.75);
    font-style: normal;
    font-weight: 600;
}
.hd-nav-deep__more {
    margin: 0.75rem 0 0;
    font-size: 0.78rem;
    color: rgba(255,255,255,0.6);
    font-style: italic;
    text-align: center;
}

/* Light mode */
body.light-mode .hd-nav-deep__celeb-card {
    background: rgba(46,125,50,0.05);
    border-color: rgba(46,125,50,0.3);
    color: #1b2e0f;
}
body.light-mode .hd-nav-deep__celeb-card:hover,
body.light-mode .hd-nav-deep__celeb-card:focus-visible {
    background: rgba(76,175,80,0.12);
    border-color: #2e7d32;
    box-shadow: 0 8px 20px rgba(46,125,50,0.18);
    outline-color: rgba(46,125,50,0.4);
}
body.light-mode .hd-nav-deep__celeb-photo {
    border-color: rgba(0,0,0,0.08);
}
body.light-mode .hd-nav-deep__celeb-name {
    color: #1b2e0f;
}
body.light-mode .hd-nav-deep__celeb-meta {
    color: #2e7d32;
}
body.light-mode .hd-nav-deep__celeb-cross {
    color: rgba(27,46,15,0.78);
}
body.light-mode .hd-nav-deep__celeb-cross-label {
    color: rgba(46,125,50,0.85);
}
body.light-mode .hd-nav-deep__more {
    color: rgba(30,50,20,0.6);
}

/* Responsive (liste grid legacy, non utilisée en mode slider) */
@media (max-width: 900px) {
    .hd-nav-deep__celeb-list:not(.hd-nav-deep__celeb-list--slider) {
        grid-template-columns: repeat(3, 1fr);
    }
}
@media (max-width: 600px) {
    .hd-nav-deep__celeb-list:not(.hd-nav-deep__celeb-list--slider) {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ══════════════════════════════════════════════════════════════
   Slider horizontal - toutes les célébrités matchantes Nav BG
   ══════════════════════════════════════════════════════════════ */
.hd-nav-deep__slider {
    position: relative;
    margin: 1rem -0.25rem 0;
    padding: 0 3rem;
}
.hd-nav-deep__celeb-list--slider {
    display: flex;
    grid-template-columns: none;
    flex-wrap: nowrap;
    overflow-x: auto;
    overflow-y: visible;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    gap: 0.85rem;
    padding: 0.4rem 0.25rem 1rem;
    margin: 0;
    scrollbar-width: thin;
    scrollbar-color: rgba(76, 175, 80, 0.45) transparent;
    -webkit-overflow-scrolling: touch;
}
.hd-nav-deep__celeb-list--slider::-webkit-scrollbar { height: 6px; }
.hd-nav-deep__celeb-list--slider::-webkit-scrollbar-thumb {
    background: rgba(76, 175, 80, 0.4);
    border-radius: 999px;
}
.hd-nav-deep__celeb-list--slider .hd-nav-deep__celeb-item {
    flex: 0 0 calc((100% - 4 * 0.85rem) / 5);
    min-width: 150px;
    max-width: 220px;
    scroll-snap-align: start;
}
.hd-nav-deep__celeb-item.is-same-cross .hd-nav-deep__celeb-card {
    box-shadow:
        inset 0 0 0 1px rgba(174, 213, 129, 0.6),
        0 4px 14px rgba(46, 125, 50, 0.25);
}
.hd-nav-deep__celeb-cross.is-match {
    color: #aed581;
    font-style: normal;
    font-weight: 600;
}

.hd-nav-deep__slider > .hd-nav-deep__nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 40px;
    border-radius: 999px;
    border: 1px solid rgba(76, 175, 80, 0.45);
    background: rgba(10, 25, 12, 0.78);
    color: #aed581;
    font-size: 1.6rem;
    line-height: 1;
    font-family: inherit;
    cursor: pointer;
    z-index: 3;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 0 2px;
    transition: background 0.18s ease, border-color 0.18s ease, transform 0.18s ease, opacity 0.18s ease;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.32);
}
.hd-nav-deep__slider > .hd-nav-deep__nav:hover:not(:disabled),
.hd-nav-deep__slider > .hd-nav-deep__nav:focus-visible:not(:disabled) {
    background: rgba(76, 175, 80, 0.22);
    border-color: rgba(76, 175, 80, 0.75);
    transform: translateY(-50%) scale(1.05);
    outline: 2px solid rgba(174, 213, 129, 0.45);
    outline-offset: 2px;
}
.hd-nav-deep__slider > .hd-nav-deep__nav:disabled { opacity: 0.35; cursor: default; }
.hd-nav-deep__slider > .hd-nav-deep__nav--prev { left: 0; }
.hd-nav-deep__slider > .hd-nav-deep__nav--next { right: 0; }
.hd-nav-deep__slider.is-static { padding: 0 0.25rem; }
.hd-nav-deep__slider.is-static > .hd-nav-deep__nav { display: none; }

body.light-mode .hd-nav-deep__celeb-list--slider {
    scrollbar-color: rgba(46, 125, 50, 0.5) transparent;
}
body.light-mode .hd-nav-deep__celeb-list--slider::-webkit-scrollbar-thumb {
    background: rgba(46, 125, 50, 0.5);
}
body.light-mode .hd-nav-deep__slider > .hd-nav-deep__nav {
    background: rgba(241, 248, 233, 0.92);
    border-color: rgba(46, 125, 50, 0.5);
    color: #2e7d32;
    box-shadow: 0 4px 12px rgba(46, 125, 50, 0.18);
}
body.light-mode .hd-nav-deep__slider > .hd-nav-deep__nav:hover:not(:disabled),
body.light-mode .hd-nav-deep__slider > .hd-nav-deep__nav:focus-visible:not(:disabled) {
    background: rgba(76, 175, 80, 0.18);
    border-color: rgba(46, 125, 50, 0.75);
}
body.light-mode .hd-nav-deep__celeb-item.is-same-cross .hd-nav-deep__celeb-card {
    box-shadow:
        inset 0 0 0 1px rgba(46, 125, 50, 0.55),
        0 4px 14px rgba(46, 125, 50, 0.18);
}
body.light-mode .hd-nav-deep__celeb-cross.is-match {
    color: #2e7d32;
}

@media (max-width: 1100px) {
    .hd-nav-deep__celeb-list--slider .hd-nav-deep__celeb-item {
        flex-basis: calc((100% - 3 * 0.85rem) / 4);
    }
}
@media (max-width: 900px) {
    .hd-nav-deep__slider { padding: 0 2.4rem; }
    .hd-nav-deep__celeb-list--slider .hd-nav-deep__celeb-item {
        flex-basis: calc((100% - 2 * 0.85rem) / 3);
        min-width: 140px;
    }
    .hd-nav-deep__slider > .hd-nav-deep__nav { width: 36px; height: 36px; }
}
@media (max-width: 640px) {
    .hd-nav-deep__slider { padding: 0 2rem; }
    .hd-nav-deep__celeb-list--slider .hd-nav-deep__celeb-item {
        flex-basis: calc((100% - 0.85rem) / 2);
        min-width: 130px;
    }
    .hd-nav-deep__slider > .hd-nav-deep__nav { width: 32px; height: 32px; font-size: 1.3rem; }
}
@media (max-width: 420px) {
    .hd-nav-deep__slider { padding: 0 1.8rem; }
    .hd-nav-deep__celeb-list--slider .hd-nav-deep__celeb-item {
        flex-basis: 72%;
        min-width: 0;
        max-width: none;
    }
}

/* ══════════════════════════════════════════════════════════════
   Bouton « ? » info Navigation BG (dans panel float + banners)
   ══════════════════════════════════════════════════════════════ */
.hd-nav-float__info,
.hd-nav-deep__info {
    appearance: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    padding: 0;
    background: transparent;
    border: 1px solid rgba(255,255,255,0.18);
    border-radius: 50%;
    color: rgba(255,255,255,0.7);
    font-family: 'Lora', Georgia, serif;
    font-size: 0.82rem;
    font-weight: 700;
    line-height: 1;
    cursor: pointer;
    transition: color 0.18s, border-color 0.18s, background 0.18s, transform 0.18s;
}
.hd-nav-deep__info {
    width: 26px;
    height: 26px;
    font-size: 0.85rem;
}
.hd-nav-float__info:hover,
.hd-nav-float__info:focus-visible,
.hd-nav-deep__info:hover,
.hd-nav-deep__info:focus-visible {
    color: var(--gold, #c9a84c);
    border-color: rgba(201,168,76,0.55);
    background: rgba(201,168,76,0.1);
    transform: scale(1.08);
    outline: none;
}
body.light-mode .hd-nav-float__info,
body.light-mode .hd-nav-deep__info {
    color: rgba(0,0,0,0.55);
    border-color: rgba(0,0,0,0.2);
}
body.light-mode .hd-nav-float__info:hover,
body.light-mode .hd-nav-float__info:focus-visible,
body.light-mode .hd-nav-deep__info:hover,
body.light-mode .hd-nav-deep__info:focus-visible {
    color: var(--gold, #8b6914);
    border-color: rgba(139,105,20,0.5);
    background: rgba(139,105,20,0.08);
}

/* ══════════════════════════════════════════════════════════════
   Infobox « premier passage » en mode Navigation BG
   Positionnée au-dessus du bloc flottant (bas-droite) avec une
   petite flèche qui pointe vers la boussole.
   ══════════════════════════════════════════════════════════════ */
.hd-nav-tip {
    position: fixed;
    right: 1.25rem;
    bottom: calc(1.25rem + 72px); /* au-dessus du float réduit, décalé si panel ouvert */
    z-index: var(--z-loader);
    width: min(340px, calc(100vw - 2.5rem));
    padding: 1rem 1.1rem 0.85rem;
    background: #050c1c;
    color: #e7ecf5;
    border: 1px solid rgba(201,168,76,0.45);
    border-radius: 14px;
    box-shadow: 0 12px 40px rgba(0,0,0,0.55), 0 0 24px rgba(201,168,76,0.18);
    font-family: inherit;
    opacity: 0;
    transform: translateY(12px) scale(0.98);
    transition: opacity 0.24s ease, transform 0.28s cubic-bezier(.2,.9,.3,1.2);
    pointer-events: none;
}
.hd-nav-tip.is-visible {
    opacity: 1;
    transform: translateY(0) scale(1);
    pointer-events: auto;
}
.hd-nav-tip::after {
    content: "";
    position: absolute;
    right: 32px;
    bottom: -9px;
    width: 14px;
    height: 14px;
    background: #050c1c;
    border-right: 1px solid rgba(201,168,76,0.45);
    border-bottom: 1px solid rgba(201,168,76,0.45);
    transform: rotate(45deg);
    border-bottom-right-radius: 3px;
}
.hd-nav-tip__close {
    position: absolute;
    top: 0.45rem;
    right: 0.45rem;
    width: 26px;
    height: 26px;
    padding: 0;
    background: transparent;
    border: none;
    color: rgba(255,255,255,0.55);
    border-radius: 50%;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: color 0.18s, background 0.18s;
}
.hd-nav-tip__close:hover,
.hd-nav-tip__close:focus-visible {
    color: var(--gold, #c9a84c);
    background: rgba(201,168,76,0.1);
    outline: none;
}
.hd-nav-tip__header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0 0 0.5rem;
    padding-right: 1.5rem;
}
.hd-nav-tip__icon {
    font-size: 1.2rem;
    line-height: 1;
    filter: drop-shadow(0 0 4px rgba(201,168,76,0.35));
}
.hd-nav-tip__title {
    margin: 0;
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--gold-light, #e8d48b);
    letter-spacing: 0.01em;
}
.hd-nav-tip__body {
    margin: 0 0 0.7rem;
    font-size: 0.85rem;
    line-height: 1.5;
    color: rgba(255,255,255,0.82);
}
.hd-nav-tip__body strong {
    color: #fff;
    font-weight: 600;
}
.hd-nav-tip__never {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    font-size: 0.78rem;
    color: rgba(255,255,255,0.62);
    cursor: pointer;
    user-select: none;
    margin-bottom: 0.7rem;
}
.hd-nav-tip__never input[type="checkbox"] {
    width: 14px;
    height: 14px;
    accent-color: var(--gold, #c9a84c);
    cursor: pointer;
    margin: 0;
}
.hd-nav-tip__actions {
    display: flex;
    justify-content: flex-end;
}
.hd-nav-tip__ack {
    appearance: none;
    padding: 0.42rem 1rem;
    background: linear-gradient(135deg, #a07c2a, var(--gold, #c9a84c));
    border: none;
    color: #0a1120;
    border-radius: 999px;
    font-family: inherit;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    cursor: pointer;
    transition: transform 0.18s, box-shadow 0.18s;
}
.hd-nav-tip__ack:hover,
.hd-nav-tip__ack:focus-visible {
    transform: translateY(-1px);
    box-shadow: 0 4px 14px rgba(201,168,76,0.35);
    outline: none;
}

/* Light mode */
body.light-mode .hd-nav-tip {
    background: #fefcf6;
    color: #1d2742;
    border-color: rgba(139,105,20,0.4);
    box-shadow: 0 12px 40px rgba(0,0,0,0.18), 0 0 24px rgba(201,168,76,0.15);
}
body.light-mode .hd-nav-tip::after {
    background: #fefcf6;
    border-right-color: rgba(139,105,20,0.4);
    border-bottom-color: rgba(139,105,20,0.4);
}
body.light-mode .hd-nav-tip__close { color: rgba(0,0,0,0.45); }
body.light-mode .hd-nav-tip__close:hover,
body.light-mode .hd-nav-tip__close:focus-visible {
    color: #8b6914;
    background: rgba(139,105,20,0.08);
}
body.light-mode .hd-nav-tip__title { color: #8b6914; }
body.light-mode .hd-nav-tip__body { color: rgba(0,0,0,0.72); }
body.light-mode .hd-nav-tip__body strong { color: #1d2742; }
body.light-mode .hd-nav-tip__never { color: rgba(0,0,0,0.6); }
body.light-mode .hd-nav-tip__ack {
    background: linear-gradient(135deg, #8b6914, #c9a84c);
    color: #fff;
}

/* Mobile : plein bas, pas de flèche */
@media (max-width: 640px) {
    .hd-nav-tip {
        right: 0.75rem;
        left: 0.75rem;
        bottom: calc(1.25rem + 64px);
        width: auto;
    }
    .hd-nav-tip::after { right: 48px; }
}

/* ══════════════════════════════════════════════════════════════
   Bouton « Copier » (Pro) - presse-papier du bandeau Nav BG
   Positionné discrètement en bas-droite du bloc, petit carré
   transparent qui se révèle au hover/focus.
   ══════════════════════════════════════════════════════════════ */
.hd-nav-deep { position: relative; } /* ancrage pour le bouton absolu */
.hd-nav-deep__copy {
    position: absolute;
    right: 0.5rem;
    bottom: 0.5rem;
    z-index: 2;
    width: 26px;
    height: 26px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 6px;
    color: rgba(255,255,255,0.4);
    cursor: pointer;
    opacity: 0.55;
    transition: opacity 0.2s, color 0.2s, border-color 0.2s, background 0.2s;
}
.hd-nav-deep:hover .hd-nav-deep__copy,
.hd-nav-deep__copy:focus-visible {
    opacity: 1;
}
.hd-nav-deep__copy-icon {
    flex-shrink: 0;
}
.hd-nav-deep__copy-icon--done {
    display: none;
    color: #7dd587;
}
.hd-nav-deep__copy:hover,
.hd-nav-deep__copy:focus-visible {
    color: var(--gold, #c9a84c);
    border-color: rgba(201,168,76,0.45);
    background: rgba(201,168,76,0.08);
    outline: none;
}
.hd-nav-deep__copy.is-copied {
    opacity: 1;
    color: #7dd587;
    border-color: rgba(125,213,135,0.5);
    background: rgba(125,213,135,0.08);
}
.hd-nav-deep__copy.is-copied .hd-nav-deep__copy-icon:not(.hd-nav-deep__copy-icon--done) { display: none; }
.hd-nav-deep__copy.is-copied .hd-nav-deep__copy-icon--done { display: inline-block; }
.hd-nav-deep__copy.is-copy-error {
    opacity: 1;
    color: #f0a0a0;
    border-color: rgba(240,160,160,0.5);
    background: rgba(240,160,160,0.08);
}
body.light-mode .hd-nav-deep__copy {
    color: rgba(0,0,0,0.35);
    border-color: rgba(0,0,0,0.12);
}
body.light-mode .hd-nav-deep__copy:hover,
body.light-mode .hd-nav-deep__copy:focus-visible {
    color: var(--gold-dark, #8b6914);
    border-color: rgba(139,105,20,0.4);
    background: rgba(139,105,20,0.06);
}
body.light-mode .hd-nav-deep__copy.is-copied {
    color: #2e7d3f;
    border-color: rgba(46,125,63,0.45);
    background: rgba(46,125,63,0.06);
}
body.light-mode .hd-nav-deep__copy-icon--done { color: #2e7d3f; }

/* Sur mobile, toujours visible (pas de hover) */
@media (max-width: 640px) {
    .hd-nav-deep__copy {
        opacity: 0.7;
    }
}

/* ══════════════════════════════════════════════════════════════
   Modale info Navigation BG
   ══════════════════════════════════════════════════════════════ */
.hd-nav-info-modal {
    position: fixed;
    inset: 0;
    z-index: var(--z-top);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}
.hd-nav-info-modal[hidden] {
    display: none;
}
.hd-nav-info-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(5, 12, 28, 0.78);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    animation: hdNavInfoFadeIn 0.2s ease-out;
}
.hd-nav-info-modal__dialog {
    position: relative;
    max-width: 560px;
    width: 100%;
    max-height: calc(100vh - 2rem); /* fallback */
    max-height: calc(100dvh - 2rem);
    overflow-y: auto;
    background: linear-gradient(145deg, #0f1e3a 0%, #0b1428 100%);
    border: 1px solid rgba(201, 168, 76, 0.32);
    border-radius: 18px;
    box-shadow:
        0 30px 60px rgba(0, 0, 0, 0.55),
        inset 0 1px 0 rgba(255, 255, 255, 0.06);
    padding: 1.75rem 1.75rem 1.5rem;
    color: rgba(240, 235, 225, 0.9);
    animation: hdNavInfoSlideUp 0.22s cubic-bezier(0.22, 1, 0.36, 1);
}
@keyframes hdNavInfoFadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}
@keyframes hdNavInfoSlideUp {
    from { opacity: 0; transform: translateY(8px); }
    to   { opacity: 1; transform: translateY(0); }
}

.hd-nav-info-modal__close {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    width: 34px;
    height: 34px;
    padding: 0;
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 50%;
    color: rgba(255, 255, 255, 0.75);
    font-size: 1.3rem;
    line-height: 1;
    cursor: pointer;
    transition: color 0.18s, border-color 0.18s, background 0.18s;
}
.hd-nav-info-modal__close:hover,
.hd-nav-info-modal__close:focus-visible {
    color: #f0a0a0;
    border-color: rgba(240, 160, 160, 0.5);
    background: rgba(240, 160, 160, 0.08);
    outline: none;
}

.hd-nav-info-modal__header {
    margin-bottom: 1rem;
    padding-right: 2.5rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid rgba(201, 168, 76, 0.18);
}
.hd-nav-info-modal__kicker {
    display: inline-block;
    font-size: 0.7rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--gold, #c9a84c);
    margin-bottom: 0.3rem;
    font-weight: 600;
}
.hd-nav-info-modal__title {
    font-family: 'Cormorant Garamond', serif;
    font-size: clamp(1.3rem, 2.5vw, 1.6rem);
    font-weight: 500;
    margin: 0;
    color: #fff;
    letter-spacing: 0.005em;
    line-height: 1.25;
}
.hd-nav-info-modal__body {
    font-family: 'Lora', Georgia, serif;
    font-size: 0.93rem;
    line-height: 1.65;
}
.hd-nav-info-modal__body p {
    margin: 0 0 0.85rem;
}
.hd-nav-info-modal__body strong {
    color: var(--gold, #c9a84c);
    font-weight: 600;
}
.hd-nav-info-modal__subtitle {
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.18rem;
    font-weight: 500;
    color: #fff;
    margin: 1.1rem 0 0.5rem;
    letter-spacing: 0.01em;
}
.hd-nav-info-modal__list {
    margin: 0 0 0.9rem;
    padding-left: 1.1rem;
    list-style: none;
}
.hd-nav-info-modal__list li {
    position: relative;
    padding-left: 0.2rem;
    margin-bottom: 0.4rem;
}
.hd-nav-info-modal__list li::before {
    content: '✦';
    position: absolute;
    left: -1.1rem;
    top: 0;
    color: var(--gold, #c9a84c);
    font-size: 0.78rem;
    opacity: 0.85;
}
.hd-nav-info-modal__note {
    margin-top: 0.9rem;
    padding: 0.7rem 0.9rem;
    background: rgba(201, 168, 76, 0.07);
    border-left: 3px solid rgba(201, 168, 76, 0.5);
    border-radius: 0 8px 8px 0;
    font-size: 0.86rem;
    font-style: italic;
    color: rgba(240, 235, 225, 0.82);
}

.hd-nav-info-modal__footer {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    justify-content: flex-end;
    margin-top: 1.25rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(201, 168, 76, 0.15);
}
.hd-nav-info-modal__cta {
    display: inline-flex;
    align-items: center;
    padding: 0.55rem 1.1rem;
    background: linear-gradient(135deg, #c9a84c 0%, #8b6914 100%);
    color: #fff; text-shadow: 0 1px 2px rgba(0,0,0,0.25);
    border: 1px solid rgba(201, 168, 76, 0.55);
    border-radius: 999px;
    font-weight: 700;
    font-size: 0.86rem;
    text-decoration: none;
    letter-spacing: 0.02em;
    transition: transform 0.15s, box-shadow 0.15s;
}
.hd-nav-info-modal__cta:hover,
.hd-nav-info-modal__cta:focus-visible {
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(201, 168, 76, 0.35);
    outline: 2px solid rgba(201, 168, 76, 0.5);
    outline-offset: 2px;
    text-decoration: none;
}
.hd-nav-info-modal__ok {
    appearance: none;
    padding: 0.55rem 1.1rem;
    background: transparent;
    color: rgba(240, 235, 225, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 999px;
    font-family: inherit;
    font-size: 0.86rem;
    font-weight: 600;
    cursor: pointer;
    letter-spacing: 0.02em;
    transition: color 0.15s, border-color 0.15s, background 0.15s;
}
.hd-nav-info-modal__ok:hover,
.hd-nav-info-modal__ok:focus-visible {
    color: var(--gold, #c9a84c);
    border-color: rgba(201, 168, 76, 0.55);
    background: rgba(201, 168, 76, 0.08);
    outline: none;
}

/* ── Mode jour ── */
body.light-mode .hd-nav-info-modal__backdrop {
    background: rgba(245, 243, 239, 0.85);
}
body.light-mode .hd-nav-info-modal__dialog {
    background: linear-gradient(145deg, #ffffff 0%, #faf7f0 100%);
    border-color: rgba(139, 105, 20, 0.28);
    color: #1f1b14;
    box-shadow:
        0 24px 50px rgba(0, 0, 0, 0.18),
        inset 0 1px 0 rgba(255, 255, 255, 0.8);
}
body.light-mode .hd-nav-info-modal__close {
    color: rgba(0, 0, 0, 0.55);
    border-color: rgba(0, 0, 0, 0.15);
}
body.light-mode .hd-nav-info-modal__close:hover,
body.light-mode .hd-nav-info-modal__close:focus-visible {
    color: #b94040;
    border-color: rgba(185, 64, 64, 0.4);
    background: rgba(185, 64, 64, 0.08);
}
body.light-mode .hd-nav-info-modal__header {
    border-bottom-color: rgba(139, 105, 20, 0.2);
}
body.light-mode .hd-nav-info-modal__kicker,
body.light-mode .hd-nav-info-modal__body strong,
body.light-mode .hd-nav-info-modal__list li::before {
    color: var(--gold, #8b6914);
}
body.light-mode .hd-nav-info-modal__title,
body.light-mode .hd-nav-info-modal__subtitle {
    color: #1a140a;
}
body.light-mode .hd-nav-info-modal__note {
    background: rgba(139, 105, 20, 0.07);
    border-left-color: rgba(139, 105, 20, 0.5);
    color: rgba(30, 22, 10, 0.82);
}
body.light-mode .hd-nav-info-modal__footer {
    border-top-color: rgba(139, 105, 20, 0.18);
}
body.light-mode .hd-nav-info-modal__cta {
    background: linear-gradient(135deg, #b98d28 0%, #8b6914 100%);
    color: #fff;
}
body.light-mode .hd-nav-info-modal__ok {
    color: rgba(30, 22, 10, 0.8);
    border-color: rgba(0, 0, 0, 0.2);
}
body.light-mode .hd-nav-info-modal__ok:hover,
body.light-mode .hd-nav-info-modal__ok:focus-visible {
    color: var(--gold, #8b6914);
    border-color: rgba(139, 105, 20, 0.5);
    background: rgba(139, 105, 20, 0.08);
}

@media (max-width: 560px) {
    .hd-nav-info-modal {
        padding: 0.5rem;
        align-items: flex-end;
    }
    .hd-nav-info-modal__dialog {
        padding: 1.4rem 1.25rem 1.25rem;
        max-height: 90vh;
        border-radius: 16px 16px 0 0;
    }
    .hd-nav-info-modal__footer {
        flex-direction: column-reverse;
        align-items: stretch;
    }
    .hd-nav-info-modal__cta,
    .hd-nav-info-modal__ok {
        justify-content: center;
        text-align: center;
    }
}


/* ══════════════════════════════════════════════════════════════════════
   REFONTE DESIGN - bloc Navigation BG en haut des CPT (.hd-nav-deep--merged)
   ───────────────────────────────────────────────────────────────────────
   Neutralise les palettes vert/gris/orange héritées de --defined/--open/
   --half/--inactive pour UNIFIER l'aspect autour de la charte du site :
   or + bleu nuit (sombre) / or + ivoire (jour). Ce bloc est un CTA
   premium : bien visible, jamais intrusif, clairement cliquable pour
   déplier/replier.
   ══════════════════════════════════════════════════════════════════════ */

.hd-nav-deep--merged {
    /* Fond sobre bleu-nuit avec halo or en haut-gauche */
    background:
        radial-gradient(ellipse 60% 80% at 12% 0%, rgba(201,168,76,0.22), transparent 70%),
        linear-gradient(135deg, #162340 0%, #0b1428 55%, #050c1c 100%);
    border: 1px solid rgba(201,168,76,0.4);
    border-radius: 16px;
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.08),
        0 10px 32px rgba(0,0,0,0.35),
        0 0 0 1px rgba(201,168,76,0.1);
    transition: border-color 0.28s ease, box-shadow 0.28s ease, transform 0.28s ease;
}
.hd-nav-deep--merged::before {
    height: 2px;
    background: linear-gradient(90deg, transparent 0%, rgba(201,168,76,0.15) 20%, var(--gold, #c9a84c) 50%, rgba(201,168,76,0.15) 80%, transparent 100%);
    opacity: 0.95;
}
/* Légère pulse au hover pour inviter au clic (CTA) */
.hd-nav-deep--merged:hover {
    border-color: rgba(201,168,76,0.6);
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.1),
        0 12px 38px rgba(0,0,0,0.4),
        0 0 0 1px rgba(201,168,76,0.18),
        0 0 32px rgba(201,168,76,0.12);
}

/* Icône pastille or */
.hd-nav-deep--merged .hd-nav-deep__icon {
    color: var(--gold-light, #e8d48b);
    background: rgba(201,168,76,0.14);
    border-color: rgba(201,168,76,0.5);
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.12),
        0 0 0 1px rgba(201,168,76,0.08);
}

/* Titre blanc net + détail atténué */
.hd-nav-deep--merged .hd-nav-deep__title {
    color: #f5f2ea;
}
.hd-nav-deep--merged .hd-nav-deep__title strong {
    color: var(--gold-light, #e8d48b);
    font-weight: 600;
}
.hd-nav-deep--merged .hd-nav-deep__detail {
    color: rgba(245,242,234,0.72);
}
.hd-nav-deep--merged .hd-nav-deep__detail strong {
    color: rgba(245,242,234,0.95);
}

/* Body lisible */
.hd-nav-deep--merged .hd-nav-deep__body {
    color: rgba(255,255,255,0.88);
    border-top: 1px solid rgba(201,168,76,0.18);
    margin-top: 1rem;
    padding-top: 1rem;
}
.hd-nav-deep--merged .hd-nav-deep__body strong {
    color: #f5f2ea;
}

/* Sous-titres du body en or */
.hd-nav-deep--merged .hd-nav-deep__subtitle,
.hd-nav-deep--merged .hd-nav-deep__nav-title {
    color: var(--gold-light, #e8d48b);
}

/* Chevron toggle uniformément or */
.hd-nav-deep--merged .hd-nav-deep__toggle {
    background: rgba(201,168,76,0.12);
    border-color: rgba(201,168,76,0.4);
    color: var(--gold-light, #e8d48b);
}
.hd-nav-deep--merged .hd-nav-deep__toggle:hover {
    background: rgba(201,168,76,0.22);
    border-color: rgba(201,168,76,0.65);
}

/* Séparateur header/body uniforme */
.hd-nav-deep--merged .hd-nav-deep__header {
    border-bottom-color: rgba(201,168,76,0.12);
}
.hd-nav-deep--merged .hd-nav-deep__header:hover {
    border-bottom-color: rgba(201,168,76,0.4);
}

/* État replié : suggérer plus fortement la cliquabilité via le chevron */
.hd-nav-deep--merged.is-collapsed {
    cursor: pointer;
}
.hd-nav-deep--merged.is-collapsed .hd-nav-deep__toggle {
    background: rgba(201,168,76,0.18);
    border-color: rgba(201,168,76,0.55);
}
.hd-nav-deep--merged.is-collapsed:hover .hd-nav-deep__toggle {
    background: rgba(201,168,76,0.3);
    border-color: rgba(201,168,76,0.8);
}

/* Pill « Pour [Nom] » en or métallique (inchangé mais centré dans le nouveau design) */
.hd-nav-deep--merged .hd-nav-deep__pill {
    color: #050c1c;
    background: linear-gradient(135deg, #e8d48b 0%, var(--gold, #c9a84c) 100%);
    border: 1px solid rgba(255,255,255,0.2);
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.35),
        0 2px 8px rgba(201,168,76,0.3);
}

/* ─────────────────────────────────────────────────────────────
   Mode jour - ivoire + or foncé
   ───────────────────────────────────────────────────────────── */
body.light-mode .hd-nav-deep--merged {
    background:
        radial-gradient(ellipse 60% 80% at 12% 0%, rgba(201,168,76,0.22), transparent 70%),
        linear-gradient(135deg, #fefcf6 0%, #f6ecd6 100%);
    border-color: rgba(160,124,42,0.35);
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.7),
        0 8px 26px rgba(160,124,42,0.08),
        0 0 0 1px rgba(160,124,42,0.08);
}
body.light-mode .hd-nav-deep--merged:hover {
    border-color: rgba(160,124,42,0.55);
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.8),
        0 10px 32px rgba(160,124,42,0.14),
        0 0 0 1px rgba(160,124,42,0.14),
        0 0 26px rgba(201,168,76,0.18);
}
body.light-mode .hd-nav-deep--merged::before {
    background: linear-gradient(90deg, transparent 0%, rgba(160,124,42,0.2) 20%, var(--gold-dark, #a07c2a) 50%, rgba(160,124,42,0.2) 80%, transparent 100%);
}
body.light-mode .hd-nav-deep--merged .hd-nav-deep__icon {
    color: var(--gold-dark, #8b6914);
    background: rgba(201,168,76,0.18);
    border-color: rgba(160,124,42,0.45);
}
body.light-mode .hd-nav-deep--merged .hd-nav-deep__title {
    color: #1d2742;
}
body.light-mode .hd-nav-deep--merged .hd-nav-deep__title strong {
    color: var(--gold-dark, #8b6914);
}
body.light-mode .hd-nav-deep--merged .hd-nav-deep__detail {
    color: rgba(0,0,0,0.64);
}
body.light-mode .hd-nav-deep--merged .hd-nav-deep__detail strong {
    color: #1d2742;
}
body.light-mode .hd-nav-deep--merged .hd-nav-deep__body {
    color: rgba(0,0,0,0.78);
    border-top-color: rgba(160,124,42,0.2);
}
body.light-mode .hd-nav-deep--merged .hd-nav-deep__body strong {
    color: #1d2742;
}
body.light-mode .hd-nav-deep--merged .hd-nav-deep__subtitle,
body.light-mode .hd-nav-deep--merged .hd-nav-deep__nav-title {
    color: var(--gold-dark, #8b6914);
}
body.light-mode .hd-nav-deep--merged .hd-nav-deep__toggle {
    background: rgba(201,168,76,0.12);
    border-color: rgba(160,124,42,0.4);
    color: var(--gold-dark, #8b6914);
}
body.light-mode .hd-nav-deep--merged .hd-nav-deep__toggle:hover {
    background: rgba(201,168,76,0.2);
    border-color: rgba(160,124,42,0.6);
}
body.light-mode .hd-nav-deep--merged .hd-nav-deep__header {
    border-bottom-color: rgba(160,124,42,0.15);
}
body.light-mode .hd-nav-deep--merged .hd-nav-deep__header:hover {
    border-bottom-color: rgba(160,124,42,0.4);
}
body.light-mode .hd-nav-deep--merged.is-collapsed .hd-nav-deep__toggle {
    background: rgba(201,168,76,0.22);
    border-color: rgba(160,124,42,0.55);
}
body.light-mode .hd-nav-deep--merged.is-collapsed:hover .hd-nav-deep__toggle {
    background: rgba(201,168,76,0.32);
    border-color: rgba(160,124,42,0.75);
}
body.light-mode .hd-nav-deep--merged .hd-nav-deep__pill {
    color: #fff;
    background: linear-gradient(135deg, #a07c2a 0%, #8b6914 100%);
    border-color: rgba(255,255,255,0.3);
    box-shadow:
        inset 0 1px 0 rgba(255,255,255,0.3),
        0 2px 6px rgba(160,124,42,0.3);
}

/* Synthèse pills (Type/Profil/…) dans le bloc - couleurs harmonisées */
.hd-nav-deep--merged .hd-nav-deep__bg-info-label {
    color: rgba(201,168,76,0.85);
}
.hd-nav-deep--merged .hd-nav-deep__bg-info-value {
    color: rgba(255,255,255,0.92);
}
body.light-mode .hd-nav-deep--merged .hd-nav-deep__bg-info-label {
    color: var(--gold-dark, #8b6914);
}
body.light-mode .hd-nav-deep--merged .hd-nav-deep__bg-info-value {
    color: #1d2742;
}

/* ══════════════════════════════════════════════════════════════════════
   UX mobile-first pour le banner Nav BG (.hd-nav-deep--merged)
   ───────────────────────────────────────────────────────────────────────
   Distribue le contenu de façon ergonomique, lisible sur smartphone :
   - Header : icône + titre/détail + chevron (tap target ≥ 44px)
   - Synthèse BG : grid compact toujours visible (contexte)
   - Body : masqué quand replié
   - Footer : barre d'actions (Gérer / Aide / Copier) à portée du pouce
   ══════════════════════════════════════════════════════════════════════ */

/* Padding plus généreux pour respirer, ajusté mobile */
.hd-nav-deep--merged {
    padding: 1.15rem 1.15rem 0.9rem;
}
@media (min-width: 641px) {
    .hd-nav-deep--merged {
        padding: 1.5rem 1.6rem 1.2rem;
    }
}

/* Header compact mobile-first : icône petite, chevron tap target */
.hd-nav-deep--merged .hd-nav-deep__header--merged {
    grid-template-columns: auto 1fr auto;
    gap: 0.7rem;
    padding-right: 0;
    padding-bottom: 0;
    margin-bottom: 0.9rem;
    border-bottom: none;
    align-items: center;
}
@media (min-width: 641px) {
    .hd-nav-deep--merged .hd-nav-deep__header--merged {
        gap: 1rem;
    }
}

/* Icône pastille : 36px mobile / 42px desktop */
.hd-nav-deep--merged .hd-nav-deep__icon {
    width: 36px;
    height: 36px;
    font-size: 1.3rem;
}
@media (min-width: 641px) {
    .hd-nav-deep--merged .hd-nav-deep__icon {
        width: 44px;
        height: 44px;
        font-size: 1.5rem;
    }
}

/* Titre + détail : wrap propre mobile */
.hd-nav-deep--merged .hd-nav-deep__headline {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
}
.hd-nav-deep--merged .hd-nav-deep__header--merged .hd-nav-deep__title {
    font-size: 0.95rem;
    line-height: 1.35;
}
@media (min-width: 641px) {
    .hd-nav-deep--merged .hd-nav-deep__header--merged .hd-nav-deep__title {
        font-size: 1.08rem;
    }
}
.hd-nav-deep--merged .hd-nav-deep__detail {
    font-size: 0.8rem;
    margin: 0;
    line-height: 1.4;
}
@media (min-width: 641px) {
    .hd-nav-deep--merged .hd-nav-deep__detail {
        font-size: 0.85rem;
    }
}

/* Zone actions du header = slot unique pour le chevron toggle (JS) */
.hd-nav-deep--merged .hd-nav-deep__actions {
    gap: 0;
    justify-content: flex-end;
}
.hd-nav-deep--merged .hd-nav-deep__toggle {
    width: 38px;
    height: 38px;
}
@media (min-width: 641px) {
    .hd-nav-deep--merged .hd-nav-deep__toggle {
        width: 36px;
        height: 36px;
    }
}

/* ───── Synthèse BG : visible même replié, grid mobile-first ───── */
.hd-nav-deep--merged .hd-nav-deep__bg-info {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.4rem 0.8rem;
    margin: 0 0 0.9rem;
    padding: 0.65rem 0.8rem;
    list-style: none;
    background: rgba(201,168,76,0.05);
    border: 1px solid rgba(201,168,76,0.16);
    border-radius: 10px;
    align-items: start;
}
@media (min-width: 481px) {
    .hd-nav-deep--merged .hd-nav-deep__bg-info {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}
@media (min-width: 768px) {
    .hd-nav-deep--merged .hd-nav-deep__bg-info {
        grid-template-columns: repeat(4, minmax(0, 1fr));
        gap: 0.5rem 1rem;
    }
}
.hd-nav-deep--merged .hd-nav-deep__bg-info-item {
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
    align-items: flex-start;
    min-width: 0;
    padding: 0;
    border: none;
}
.hd-nav-deep--merged .hd-nav-deep__bg-info-item--cross {
    grid-column: 1 / -1;
    flex: initial;
    margin-top: 0.1rem;
    padding-top: 0.45rem;
    border-top: 1px dashed rgba(201,168,76,0.2);
}
.hd-nav-deep--merged .hd-nav-deep__bg-info-label {
    font-size: 0.6rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: rgba(201,168,76,0.72);
    font-weight: 600;
}
.hd-nav-deep--merged .hd-nav-deep__bg-info-value {
    font-family: var(--font-heading, 'Cormorant Garamond', serif);
    font-size: 1rem;
    line-height: 1.2;
    color: rgba(255,255,255,0.95);
    font-weight: 500;
    letter-spacing: 0.01em;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    width: 100%;
}
.hd-nav-deep--merged .hd-nav-deep__bg-info-item--cross .hd-nav-deep__bg-info-value {
    white-space: normal;
    font-style: italic;
    font-size: 0.95rem;
}

body.light-mode .hd-nav-deep--merged .hd-nav-deep__bg-info {
    background: rgba(139,105,20,0.06);
    border-color: rgba(139,105,20,0.2);
}
body.light-mode .hd-nav-deep--merged .hd-nav-deep__bg-info-label {
    color: rgba(139,105,20,0.75);
}
body.light-mode .hd-nav-deep--merged .hd-nav-deep__bg-info-value {
    color: #1d2742;
}
body.light-mode .hd-nav-deep--merged .hd-nav-deep__bg-info-item--cross {
    border-top-color: rgba(139,105,20,0.22);
}

/* Masquer la synthèse quand le bloc est replié ? NON - on veut voir
   le contexte (qui on navigue). On la garde visible en permanence. */

/* ───── Footer d'actions : barre horizontale mobile-first ───── */
.hd-nav-deep--merged .hd-nav-deep__footer {
    display: flex;
    gap: 0.45rem;
    margin-top: 0.9rem;
    padding-top: 0.85rem;
    border-top: 1px solid rgba(201,168,76,0.15);
    align-items: stretch;
    justify-content: flex-end;
    flex-wrap: wrap;
}
.hd-nav-deep--merged.is-collapsed .hd-nav-deep__footer {
    margin-top: 0.5rem;
    padding-top: 0.6rem;
    border-top-color: rgba(201,168,76,0.1);
}
body.light-mode .hd-nav-deep--merged .hd-nav-deep__footer {
    border-top-color: rgba(139,105,20,0.18);
}

.hd-nav-deep--merged .hd-nav-deep__footer-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    min-height: 40px;
    padding: 0.5rem 0.9rem;
    background: transparent;
    border: 1px solid rgba(201,168,76,0.22);
    border-radius: 10px;
    color: rgba(255,255,255,0.75);
    font-family: inherit;
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    line-height: 1;
    text-decoration: none;
    cursor: pointer;
    transition: color 0.18s, border-color 0.18s, background 0.18s, transform 0.1s;
    white-space: nowrap;
    flex: 0 0 auto;
}
.hd-nav-deep--merged .hd-nav-deep__footer-btn svg {
    flex-shrink: 0;
    opacity: 0.9;
}
.hd-nav-deep--merged .hd-nav-deep__footer-btn:hover,
.hd-nav-deep--merged .hd-nav-deep__footer-btn:focus-visible {
    color: var(--gold-light, #e8d48b);
    border-color: rgba(201,168,76,0.55);
    background: rgba(201,168,76,0.1);
    outline: none;
}
.hd-nav-deep--merged .hd-nav-deep__footer-btn:active {
    transform: scale(0.97);
}

/* Bouton manage = accent CTA primaire */
.hd-nav-deep--merged .hd-nav-deep__footer-btn--manage {
    color: var(--gold-light, #e8d48b);
    border-color: rgba(201,168,76,0.4);
    background: rgba(201,168,76,0.08);
    margin-right: auto; /* pousse les autres à droite */
}
.hd-nav-deep--merged .hd-nav-deep__footer-btn--manage:hover,
.hd-nav-deep--merged .hd-nav-deep__footer-btn--manage:focus-visible {
    background: rgba(201,168,76,0.18);
    border-color: rgba(201,168,76,0.7);
}

/* États Copier (succès / erreur) */
.hd-nav-deep--merged .hd-nav-deep__footer-btn--copy .hd-nav-deep__copy-icon--done {
    display: none;
    color: #7dd587;
}
.hd-nav-deep--merged .hd-nav-deep__footer-btn--copy.is-copied {
    color: #7dd587;
    border-color: rgba(125,213,135,0.55);
    background: rgba(125,213,135,0.1);
}
.hd-nav-deep--merged .hd-nav-deep__footer-btn--copy.is-copied .hd-nav-deep__copy-icon:not(.hd-nav-deep__copy-icon--done) {
    display: none;
}
.hd-nav-deep--merged .hd-nav-deep__footer-btn--copy.is-copied .hd-nav-deep__copy-icon--done {
    display: inline-block;
}
.hd-nav-deep--merged .hd-nav-deep__footer-btn--copy.is-copy-error {
    color: #f0a0a0;
    border-color: rgba(240,160,160,0.55);
    background: rgba(240,160,160,0.1);
}

/* Mode jour footer */
body.light-mode .hd-nav-deep--merged .hd-nav-deep__footer-btn {
    color: rgba(0,0,0,0.6);
    border-color: rgba(139,105,20,0.22);
}
body.light-mode .hd-nav-deep--merged .hd-nav-deep__footer-btn:hover,
body.light-mode .hd-nav-deep--merged .hd-nav-deep__footer-btn:focus-visible {
    color: var(--gold-dark, #8b6914);
    border-color: rgba(139,105,20,0.5);
    background: rgba(139,105,20,0.06);
}
body.light-mode .hd-nav-deep--merged .hd-nav-deep__footer-btn--manage {
    color: var(--gold-dark, #8b6914);
    border-color: rgba(139,105,20,0.4);
    background: rgba(139,105,20,0.08);
}
body.light-mode .hd-nav-deep--merged .hd-nav-deep__footer-btn--manage:hover,
body.light-mode .hd-nav-deep--merged .hd-nav-deep__footer-btn--manage:focus-visible {
    background: rgba(139,105,20,0.14);
    border-color: rgba(139,105,20,0.65);
}
body.light-mode .hd-nav-deep--merged .hd-nav-deep__footer-btn--copy.is-copied {
    color: #2e7d3f;
    border-color: rgba(46,125,63,0.5);
    background: rgba(46,125,63,0.08);
}

/* ───── Mobile : icônes seules pour Aide/Copier, label visible pour Gérer ───── */
@media (max-width: 480px) {
    .hd-nav-deep--merged .hd-nav-deep__footer {
        gap: 0.4rem;
    }
    .hd-nav-deep--merged .hd-nav-deep__footer-btn {
        min-height: 44px;
        min-width: 44px;
        padding: 0.5rem 0.6rem;
    }
    .hd-nav-deep--merged .hd-nav-deep__footer-btn--info .hd-nav-deep__footer-btn-label,
    .hd-nav-deep--merged .hd-nav-deep__footer-btn--copy .hd-nav-deep__footer-btn-label {
        display: none;
    }
    .hd-nav-deep--merged .hd-nav-deep__footer-btn--info,
    .hd-nav-deep--merged .hd-nav-deep__footer-btn--copy {
        padding: 0.5rem;
        width: 44px;
    }
    .hd-nav-deep--merged .hd-nav-deep__footer-btn--manage {
        flex: 1 1 auto;
    }
}

/* ───── Retrait de la bordure header/body qui existait avant ───── */
.hd-nav-deep--merged .hd-nav-deep__body {
    border-top: none;
    margin-top: 0;
    padding-top: 0;
}

/* Override de la règle mobile existante qui cassait le layout */
@media (max-width: 640px) {
    .hd-nav-deep--merged .hd-nav-deep__header--merged {
        grid-template-columns: auto 1fr auto;
        grid-template-areas: none;
    }
    .hd-nav-deep--merged .hd-nav-deep__header--merged .hd-nav-deep__actions {
        padding-top: 0;
        border-top: none;
        margin-top: 0;
        justify-content: flex-end;
    }
}
