/* =====================================================================
   VERSION CV (lecture rapide) et IMPRESSION
   ---------------------------------------------------------------------
   html.cv (js/version-cv.js) : tout est affiché d'un coup, sans
   animations ni ciel animé, le pseudo en texte simple et les détails
   des projets (tags, liens) directement dans les cartes.
   @media print : même principe, en noir sur blanc.
   ===================================================================== */

/* Détails des projets : visibles seulement en Version CV et à l'impression */
.projet-cv { display: none; }

html.cv { scroll-behavior: auto; }

html.cv *,
html.cv *::before,
html.cv *::after {
  animation: none !important;
  transition: none !important;
}

html.cv :is(#ciel, #constellation, #curseur, .rave-lumieres, .indice-scroll) { display: none !important; }
html.cv.curseur-actif,
html.cv.curseur-actif * { cursor: revert !important; }
html.cv .apparition { opacity: 1 !important; transform: none !important; }

/* Le pseudo en texte (d'habitude réservé aux lecteurs d'écran) */
html.cv #pseudo {
  position: static;
  width: auto;
  height: auto;
  margin: 0;
  overflow: visible;
  clip: auto;
  white-space: normal;
  font-family: var(--police-titre);
  font-size: clamp(2.4rem, 8vw, 4.2rem);
  line-height: 1.1;
}

html.cv .constellation { margin: 0.4rem 0 1.4rem; }
html.cv .accueil { min-height: auto; padding: 6.5rem 1rem 3rem; }
html.cv .section { padding-top: 3.5rem; padding-bottom: 3.5rem; }
html.cv .section-entete { margin-bottom: 2rem; }
html.cv .projet-voir { display: none; }

/* Projets en grille compacte (plus de frise en zigzag) */
html.cv .carte-projets {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1.5rem;
}

html.cv .carte-projets::before,
html.cv .projet-etoile { display: none; }
html.cv .projet,
html.cv .projet:nth-child(even) { width: auto; margin: 0; padding: 0; }

html.cv .projet-cv {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.6rem;
  margin-top: 0.8rem;
}

html.cv .projet-cv .tags { margin: 0; }
html.cv .projet-cv .bouton { padding: 0.45rem 1rem; font-size: 0.82rem; }

/* ---------- Impression (bouton « Imprimer » de la Version CV, ou Ctrl + P) ---------- */
@media print {
  :root,
  [data-theme] {
    --fond: #fff;
    --texte: #111;
    --texte-doux: #444;
    --accent: #33415c;
    --accent-2: #2c5d62;
    --carte: #fff;
    --carte-survol: #fff;
    --bordure: #ccc;
    --bordure-forte: #999;
    --ombre: none;
    color-scheme: light;
  }

  body { background: #fff; }

  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
    text-shadow: none !important;
  }

  #ciel, #constellation, #curseur, .reglages, .indice-scroll, .accueil-boutons, .bouton-carnet, .carnet, .trophee,
  .notification, .annonce, .rave-lumieres, .pied-liens, .projet-voir, .salut-anime { display: none !important; }

  .apparition { opacity: 1 !important; transform: none !important; }
  .accueil-salut .sr-only { position: static; width: auto; height: auto; margin: 0; clip: auto; white-space: normal; }

  #pseudo {
    position: static;
    width: auto;
    height: auto;
    margin: 0;
    overflow: visible;
    clip: auto;
    white-space: normal;
    font-family: var(--police-titre);
    font-size: 2.6rem;
  }

  .accueil { min-height: auto; padding: 1rem 0; }
  .section { padding: 1.5rem 0; }
  .projet-cv { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-top: 0.6rem; }
  .projet-cv a::after { content: " (" attr(href) ")"; font-size: 0.75em; }
  .projet-carte, .contact, .groupe { break-inside: avoid; box-shadow: none; }
}
