/* ══════════════════════════════════════
       VARIABLES & RESET
    ══════════════════════════════════════ */
    :root {
      --primary:   #2563eb;
      --bg:        #f6faff;
      --card:      #ffffff;
      --border:    #e2e2d9;
      --text:      #0f172a;
      --muted:     #6b7280;
     --primary-light:#dbeafe;
      --shadow-sm: 0 1px 3px rgba(0,0,0,.04), 0 4px 12px rgba(0,0,0,.05);
      --shadow-md: 0 8px 24px rgba(0,0,0,.08), 0 2px 6px rgba(0,0,0,.04);
      --shadow-lg: 0 20px 48px rgba(0,0,0,.12);
      --radius-card: 22px;
      --radius-btn:  12px;
    }

    *, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

    body {
      font-family: 'Outfit', sans-serif;
      background: var(--bg);
      color: var(--text);
      min-height: 100vh;
    }

    /* ══════════════════════════════════════
       FOND DÉCORATIF
    ══════════════════════════════════════ */
    body::before {
      content: '';
      position: fixed;
      inset: 0;
      background:
        radial-gradient(ellipse 60% 40% at 10% 10%, rgba(37,99,235,.06) 0%, transparent 70%),
        radial-gradient(ellipse 50% 50% at 90% 80%, rgba(16,185,129,.05) 0%, transparent 70%);
      pointer-events: none;
      z-index: 0;
    }

/* À ajouter dans css/style_chapters.css (ou un nouveau fichier importé) */

.pdf-canvas-container {
    overflow-y: auto;
    background: #525659; /* gris type visionneuse PDF */
    padding: 16px;
    user-select: none;       /* empêche la sélection/copie de texte du filigrane et alentours */
    -webkit-user-select: none;
}

.pdf-page-canvas {
    user-select: none;
    -webkit-user-select: none;
    pointer-events: auto;
}

.pdf-loading {
    color: #fff;
    text-align: center;
    padding: 40px 0;
    font-family: var(--font-body, sans-serif);
}

/* Filet supplémentaire : si jamais quelqu'un imprime la PAGE (pas le PDF),
   le viewer ne sort rien à l'impression */
@media print {
    .pdf-modal-overlay.active {
        display: none !important;
    }
}
    /* ══════════════════════════════════════
       LAYOUT
    ══════════════════════════════════════ */
    .container {
      position: relative;
      z-index: 1;
      width: min(1280px, 95%);
      margin: auto;
      padding: 3.5rem 0 4rem;
    }

    /* ══════════════════════════════════════
       EN-TÊTE
    ══════════════════════════════════════ */
    .page-header {
      text-align: center;
      margin-bottom: 3.5rem;
    }

    .page-eyebrow {
      display: inline-block;
      font-size: .75rem;
      font-weight: 600;
      letter-spacing: .14em;
      text-transform: uppercase;
      color: var(--primary);
      background: rgba(37,99,235,.08);
      padding: .35rem .9rem;
      border-radius: 999px;
      margin-bottom: 1rem;
    }

    .page-title {
      font-family: 'Lora', serif;
      font-size: clamp(2rem, 4vw, 2.8rem);
      font-weight: 700;
      line-height: 1.15;
      letter-spacing: -.02em;
      margin-bottom: .75rem;
      color: var(--text);
    }

    .page-subtitle {
      color: var(--muted);
      font-size: 1rem;
      font-weight: 300;
      max-width: 500px;
      margin: auto;
      line-height: 1.7;
    }

    /* ══════════════════════════════════════
       GRILLE
    ══════════════════════════════════════ */
    .chapters-grid {
      display: grid;
      grid-template-columns: repeat(auto-fit, minmax(min(380px, 100%), 1fr));
      gap: 1.5rem;
    }

    /* ══════════════════════════════════════
       CARTE
    ══════════════════════════════════════ */
    .chapter-card {
      background: var(--card);
      border: 1px solid #ccc !important;
      border-radius: var(--radius-card);
      overflow: hidden;
      min-height: 180px;
      display: flex;
      flex-direction: column;
      box-shadow: var(--shadow-sm);
      transition: transform .28s cubic-bezier(.22,.68,0,1.2), box-shadow .28s ease;
      animation: fadeUp .5s ease both;
    }

    .chapter-card:hover {
      transform: translateY(-7px);
      box-shadow: var(--shadow-lg);
    }

    /* ── Bande colorée ── */
    .card-band {
      height: 7px;
      width: 100%;
      flex-shrink: 0;
    }

    .card-band.band-slate   { background: linear-gradient(90deg, #04748b, #22b8d1, #7de3f0); }
    .card-band.band-blue    { background: linear-gradient(90deg, #1d4ed8, #3b82f6, #93c5fd); }
    .card-band.band-amber   { background: linear-gradient(90deg, #d97706, #f59e0b, #fcd34d); }
    .card-band.band-emerald { background: linear-gradient(90deg, #059669, #10b981, #6ee7b7); }
    .card-band.band-purple  { background: linear-gradient(90deg, #7c3aed, #8b5cf6, #c4b5fd); }
    .card-band.band-rose    { background: linear-gradient(90deg, #e11d48, #f43f5e, #fda4af); }

    /* ── Corps ── */
    .card-body {
      padding: 1.4rem 1.5rem 1.5rem;
      display: flex;
      flex-direction: column;
      flex: 1;
    }

    .card-top {
      display: flex;
      align-items: center;
      gap: .6rem;
      width: 100%;
      margin-bottom: 1rem;
    
      padding: 6px 10px;
      border-radius: 10px;
    }

    .card-badge {
    display: inline-block;
    background: rgba(37,99,235,.11);
    color: #000000;
    padding: 6px 10px;
    border-radius: 20px;
    font-size: 0.9rem;
    margin-bottom: 15px;text-transform: uppercase;
    }



    .badge-slate   { background: #04748b; }
    .badge-blue    { background: #2563eb; }
    .badge-amber   { background: #f59e0b; }
    .badge-emerald { background: #10b981; }
    .badge-purple  { background: #8b5cf6; }
    .badge-rose    { background: #f43f5e; }

    .card-time {
      color: var(--muted);
      font-size: .82rem;
      font-weight: 400;
      margin-left: auto;
    }

    .card-title {
      font-family: 'Lora', serif;
      font-size: 1.15rem;
      font-weight: 700;
      line-height: 1.35;
      margin-bottom: .65rem;
      color: var(--text);
    }

    .card-desc {
      color: #000;
      font-size: .9rem;
      line-height: 1.75;
      font-weight: 300;
      flex: 1;
    }

    /* ── Footer ── */
    .card-footer {
      display: flex;
      justify-content: space-between;
      align-items: center;
      margin-top: 1.4rem;
      gap: .6rem;
    }

    .card-videos {
      display: inline-flex;
      align-items: center;
      gap: 5px;
      color: white;
      background: var(--muted);
      font-size: .78rem;
      font-weight: 500;
      padding: .35rem .75rem;
      border-radius: 999px;
    }

    .card-actions {
    display: flex;
    justify-content: space-between; /* un bouton à gauche, l'autre à droite */
    align-items: center;
    width: 100%;
    }



    /* ── Boutons CTA ──
       .card-cta et .cta-fiche partageaient un bloc de déclarations quasi
       identique (dupliqué à 90%) : factorisé ici, seules les vraies
       différences (background, padding) restent séparées.
       La propriété "right:2px" a été retirée : sans "position" définie sur
       ces éléments, elle n'avait jamais eu d'effet. */
    .card-cta,
    .cta-fiche {
      border: none;
      color: white;
      border-radius: var(--radius-btn);
      font-family: 'Outfit', sans-serif;
      font-size: .8rem;
      font-weight: 600;
      cursor: pointer;
      transition: transform .18s, box-shadow .18s, opacity .18s;
      display: inline-flex;
      align-items: center;
      gap: 5px;
    }

    .card-cta {
      background: var(--muted);
      padding: .48rem .4rem;
    }

    .cta-fiche {
      padding: .48rem .7rem;
    }

    .card-cta.open-pdf {
      margin-left: 90px;
    }

    .card-cta:hover,
    .cta-fiche:hover {
      transform: translateY(-2px);
      box-shadow: 0 6px 18px rgba(37,99,235,.35);
    }

    .card-cta.cta-outline {
      background: rgba(37,99,235,.06);
      color: var(--primary);
      border: 1.5px solid rgba(37,99,235,.85);
    }

    .card-cta.cta-outline:hover {
      background: rgba(37,99,235,.25);
      box-shadow: none;
    }

    .cta-fiche.cta-outline {
      background: transparent;
      color: var(--primary);
      border: 1.5px solid rgba(37,99,235,.35);
    }

    .cta-fiche.cta-outline:hover {
      background: rgba(37,99,235,.06);
      box-shadow: none;
    }

    /* ══════════════════════════════════════
       MODAL OVERLAY
    ══════════════════════════════════════ */
    .pdf-modal-overlay {
      position: fixed;
      inset: 0;
      background: rgba(10,14,26,.75);
      backdrop-filter: blur(6px);
      -webkit-backdrop-filter: blur(6px);
      display: flex;
      align-items: center;
      justify-content: center;
      opacity: 0;
      visibility: hidden;
      transition: opacity .28s ease, visibility .28s ease;
      z-index: 9999;
      padding: 1rem;
    }

    .pdf-modal-overlay.active {
      opacity: 1;
      visibility: visible;
    }

    /* ── Fenêtre modale ── */
    .pdf-modal {
      width: min(1400px, 96vw);
      height: 100vh;
      background: white;
      border-radius: 24px;
      overflow: hidden;
      transform: translateY(20px) scale(.97);
      transition: transform .3s cubic-bezier(.22,.68,0,1.1);
      box-shadow: 0 32px 80px rgba(0,0,0,.3);
      display: flex;
      flex-direction: column;
    }

    .pdf-modal-overlay.active .pdf-modal {
      transform: translateY(0) scale(1);
    }

    /* ── En-tête du modal ── */
    .pdf-modal-band {
      height: 6px;
      width: 100%;
      flex-shrink: 0;
    }
#pdfTitle {
    font-size: 1.4rem;
    font-weight: bolder;
    color:#009999;
    font-family:Arial, Helvetica, sans-serif; 
    line-height: 1.0;
    margin: 0 0 10px 0;
    letter-spacing: 1.5px;
}
    .pdf-modal-header {
      height: 68px;
      display: flex;
      justify-content: space-between;
      align-items: center;
      padding: 0 1.5rem;
      border-bottom: 1px solid #f0f0ed;
      flex-shrink: 0;
    }

    .pdf-modal-title {
      font-family: 'Lora', serif;
      font-size: 1.05rem;
      font-weight: 700;
      color: var(--text);
    }

    .pdf-modal-close {
      width: 34px;
      height: 34px;
      display: flex;
      justify-content: center;
      align-items: center;
      border: none;
      border-radius: 50%;
      background: #dc2626;
      color: #ffffff;
      cursor: pointer;
      font-size: 16px;
      font-weight: 700;
      line-height: 1;
      transition: background .18s, color .18s, transform .18s;
    }

    .pdf-modal-close:hover {
      background: blue;
      color: white;
      transform: rotate(90deg);
    }

    .pdf-modal-frame {
      width: 100%;
      flex: 1;
      border: none;
    }

    /* ══════════════════════════════════════
       ANIMATION D'ENTRÉE DES CARTES
    ══════════════════════════════════════ */
    @keyframes fadeUp {
      from { opacity: 0; transform: translateY(22px); }
      to   { opacity: 1; transform: translateY(0); }
    }

    .chapter-card:nth-child(1) { animation-delay: .05s; }
    .chapter-card:nth-child(2) { animation-delay: .10s; }
    .chapter-card:nth-child(3) { animation-delay: .15s; }
    .chapter-card:nth-child(4) { animation-delay: .20s; }
    .chapter-card:nth-child(5) { animation-delay: .25s; }
    .chapter-card:nth-child(6) { animation-delay: .30s; }

    /* ══════════════════════════════════════
       RESPONSIVE
    ══════════════════════════════════════ */
    @media (max-width: 600px) {
      .card-footer { flex-wrap: wrap; }
      .card-actions { width: 100%; }
      .card-cta { flex: 1; justify-content: center; }
    }