/* ============================================================
   Charte partagée avec nathaliedujardin.fr
   Source unique des couleurs, typographies, composants,
   en-tête et pied de page des outils. Les trois pages
   (accueil, Diagnostic GEO, Diagnostic IA) la chargent.
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Licorice&display=swap');

/* Manrope : police de texte (variable, graisses 200 à 800), servie en local
   comme sur le site principal. */
@font-face {
  font-family: 'Manrope';
  src: url('/charte/fonts/manrope-latin-ext.woff2') format('woff2');
  font-weight: 200 800;
  font-style: normal;
  font-display: swap;
  unicode-range: U+100-2BA, U+2BD-2C5, U+2C7-2CC, U+2CE-2D7, U+2DD-2FF, U+304, U+308, U+329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Manrope';
  src: url('/charte/fonts/manrope-latin.woff2') format('woff2');
  font-weight: 200 800;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+131, U+152-153, U+2BB-2BC, U+2C6, U+2DA, U+2DC, U+304, U+308, U+329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: 'TT Ramillas';
  src: url('/charte/fonts/tt-ramillas-regular.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  /* Fonds et textes */
  --nd-creme: #f6f0e8;
  --nd-surface: #fcfaf7;
  --nd-blanc: #ffffff;
  --nd-parme-clair: #eee7f3;
  --nd-texte: #202337;
  --nd-texte-2: #4e4b5c;
  --nd-texte-discret: #655d71;
  --nd-filet: rgba(11, 16, 34, 0.12);

  /* Accents */
  --nd-violet: #73518d;
  --nd-violet-vif: #845ee2;
  --nd-orchid: #d08cf2;
  --nd-rose: #a44970;
  --nd-rose-nuit: #f1bfd4;
  --nd-parme-nuit: #d2b9ea;
  --nd-focus: #9470b2;

  /* Fonds sombres */
  --nd-nuit: #101426;
  --nd-nuit-bandeau: #0a0e20;
  --nd-sur-nuit: #faf5ec;
  --nd-sur-nuit-2: #cbc4d6;
  --nd-filet-nuit: rgba(250, 245, 236, 0.14);

  /* Dégradé principal */
  --nd-degrade: linear-gradient(110deg, #d5bee9, #efd3da);
  --nd-texte-bouton: #252037;

  /* Typographies */
  --nd-font-titre: 'TT Ramillas', Georgia, serif;
  --nd-font-texte: 'Manrope', system-ui, -apple-system, sans-serif;
  --nd-font-main: 'Licorice', 'Segoe Script', cursive;

  /* Formes */
  --nd-rayon-carte: 22px;
  --nd-rayon-champ: 11px;
  --nd-ombre: 0 22px 50px -30px rgba(36, 36, 59, 0.3);
  --nd-largeur: 1120px;
  --nd-gouttiere: clamp(1rem, 5vw, 5rem);
}

/* ---------- Base ---------- */

.nd-page {
  margin: 0;
  background: var(--nd-creme);
  color: var(--nd-texte-2);
  font-family: var(--nd-font-texte);
  font-size: 15px;
  line-height: 1.85;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}
.nd-page *, .nd-page *::before, .nd-page *::after { box-sizing: border-box; }
.nd-page :where(strong, b) { font-weight: 600; color: var(--nd-texte); }
.nd-page ::selection { background: var(--nd-violet); color: #fff; }
.nd-page :focus-visible { outline: 3px solid var(--nd-focus); outline-offset: 5px; }

.nd-titre, :where(.nd-page) :where(h1, h2, h3) {
  font-family: var(--nd-font-titre);
  font-weight: 400;
  letter-spacing: -0.035em;
  text-wrap: balance;
  color: var(--nd-texte);
}
.nd-h1 { font-size: clamp(2.3rem, 4.3vw, 3.85rem); line-height: 1.17; }
.nd-h2 { font-size: clamp(1.6rem, 2.5vw, 2.4rem); line-height: 1.25; }
.nd-h3 { font-size: 1.35rem; line-height: 1.3; }
.nd-rose { color: var(--nd-rose); }
.nd-nuit .nd-rose { color: var(--nd-rose-nuit); }

.nd-eyebrow {
  display: block;
  font-family: var(--nd-font-texte);
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.17em;
  line-height: 1.5;
  color: var(--nd-violet);
}
.nd-nuit .nd-eyebrow { color: var(--nd-parme-nuit); }

.nd-manuscrit {
  font-family: var(--nd-font-main);
  font-size: 1.9rem;
  line-height: 1.2;
  color: var(--nd-violet);
}
.nd-nuit .nd-manuscrit { color: var(--nd-orchid); }

.nd-conteneur {
  width: 100%;
  max-width: var(--nd-largeur);
  margin-inline: auto;
  padding-inline: var(--nd-gouttiere);
}

/* ---------- Boutons ---------- */

.nd-bouton {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 46px;
  max-width: 100%;
  padding: 15px 24px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: var(--nd-degrade);
  color: var(--nd-texte-bouton);
  font-family: var(--nd-font-texte);
  font-size: 12px;
  font-weight: 600;
  line-height: 1.4;
  letter-spacing: 0.02em;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: transform 180ms ease, background 180ms ease, opacity 180ms ease;
}
.nd-bouton::after { content: '\2192'; font-size: 14px; line-height: 1; }
.nd-bouton.nd-sans-fleche::after { content: none; }
.nd-bouton:hover:not(:disabled) { transform: translateY(-2px); }
.nd-bouton:active:not(:disabled) { transform: scale(0.98); }
.nd-bouton:disabled { opacity: 0.5; cursor: not-allowed; }

.nd-bouton-contour {
  background: transparent;
  border-color: #aea0b7;
  color: var(--nd-texte);
  padding: 11px 18px;
  font-size: 11px;
}
.nd-bouton-contour::after { content: none; }

.nd-lien {
  font-family: var(--nd-font-texte);
  font-weight: 500;
  color: var(--nd-texte);
  text-decoration: underline;
  text-underline-offset: 6px;
  text-decoration-color: #9b8ea6;
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
  font-size: inherit;
}
.nd-lien:hover { text-decoration-color: var(--nd-violet); color: var(--nd-violet); }

/* ---------- Cartes ---------- */

.nd-carte {
  position: relative;
  background: var(--nd-blanc);
  border: 1px solid var(--nd-filet);
  border-radius: var(--nd-rayon-carte);
  box-shadow: var(--nd-ombre);
  padding: clamp(1.4rem, 3vw, 2.2rem);
}
.nd-carte-nuit {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background: var(--nd-nuit);
  color: var(--nd-sur-nuit-2);
  border-color: transparent;
}
.nd-carte-nuit::before {
  content: '';
  position: absolute;
  z-index: -1;
  width: 70%;
  aspect-ratio: 1;
  top: -35%;
  right: -20%;
  border-radius: 50%;
  background: #b99ce8;
  opacity: 0.35;
  filter: blur(70px);
}
.nd-carte-nuit :where(h2, h3, strong) { color: var(--nd-sur-nuit); }
.nd-etiquette {
  position: absolute;
  top: 0;
  left: clamp(1.4rem, 3vw, 2.2rem);
  transform: translateY(-50%);
  padding: 5px 14px;
  border-radius: 999px;
  background: var(--nd-degrade);
  color: var(--nd-texte-bouton);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  white-space: nowrap;
}
.nd-carte-nuit.nd-avec-etiquette { overflow: visible; }
.nd-carte-nuit.nd-avec-etiquette::before { top: 0; right: 0; width: 55%; }

/* ---------- Listes ---------- */

.nd-liste { list-style: none; margin: 0; padding: 0; }
.nd-liste li {
  position: relative;
  padding: 0.7rem 0 0.7rem 1.35rem;
  border-bottom: 1px solid var(--nd-filet);
}
.nd-liste li:last-child { border-bottom: 0; }
.nd-liste li::before {
  content: '';
  position: absolute;
  left: 0;
  top: calc(0.7rem + 0.925em - 3px);
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--nd-violet);
}
.nd-nuit .nd-liste li { border-color: var(--nd-filet-nuit); }
.nd-nuit .nd-liste li::before { background: var(--nd-orchid); }

/* ---------- Fonds sombres ---------- */

.nd-nuit { background: var(--nd-nuit); color: var(--nd-sur-nuit-2); }
.nd-nuit :where(h1, h2, h3) { color: var(--nd-sur-nuit); }

/* ============================================================
   En-tête
   ============================================================ */

.nd-entete {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--nd-parme-clair);
  border-bottom: 1px solid #ddd5df;
  font-family: var(--nd-font-texte);
}
.nd-entete-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 76px;
  padding: 10px var(--nd-gouttiere);
}
.nd-marque {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
  color: var(--nd-texte);
  text-decoration: none;
}
.nd-marque img {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  object-fit: cover;
  background: #b99ce8;
  box-shadow: 0 0 0 3px #b99ce8;
}
.nd-marque-nom {
  display: flex;
  flex-direction: column;
  font-family: var(--nd-font-titre);
  font-size: 26px;
  line-height: 1.05;
  letter-spacing: -0.02em;
  white-space: nowrap;
}
.nd-marque-nom small {
  margin-top: 5px;
  font-family: var(--nd-font-texte);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.16em;
  line-height: 1.4;
  text-transform: uppercase;
}
.nd-menu { display: flex; align-items: center; gap: 24px; }
.nd-menu a {
  color: var(--nd-texte-2);
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  transition: color 160ms ease;
}
.nd-menu a:hover { color: var(--nd-texte); text-decoration: underline; text-underline-offset: 6px; }
.nd-entete .nd-bouton-contour { font-size: 11px; }
.nd-burger {
  display: none;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 1px solid rgba(11, 16, 34, 0.22);
  border-radius: 50%;
  background: transparent;
  color: var(--nd-texte);
  cursor: pointer;
}
.nd-burger svg { width: 20px; height: 20px; }
.nd-menu-mobile { display: none; }

@media (max-width: 1023px) {
  .nd-entete .nd-menu, .nd-entete .nd-entete-cta { display: none; }
  .nd-burger { display: grid; }
  .nd-marque-nom { font-size: 22px; }
  .nd-marque img { width: 46px; height: 46px; }
  .nd-entete-inner { min-height: 68px; gap: 12px; }
  .nd-entete.nd-ouvert .nd-menu-mobile {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 8px var(--nd-gouttiere) 24px;
    border-top: 1px solid #ddd5df;
  }
  .nd-menu-mobile a:not(.nd-bouton) {
    padding: 12px 0;
    color: var(--nd-texte);
    font-size: 16px;
    font-weight: 500;
    text-decoration: none;
    border-bottom: 1px solid var(--nd-filet);
  }
  .nd-menu-mobile .nd-bouton { margin-top: 16px; align-self: flex-start; }
}
@media (max-width: 380px) {
  .nd-marque-nom { font-size: 19px; }
  .nd-marque-nom small { font-size: 9px; letter-spacing: 0.12em; }
}

/* ============================================================
   Pied de page
   ============================================================ */

.nd-pied {
  background: var(--nd-nuit);
  color: var(--nd-sur-nuit-2);
  font-family: var(--nd-font-texte);
  font-size: 14px;
  line-height: 1.7;
}
.nd-pied a { color: var(--nd-sur-nuit-2); text-decoration: none; }
.nd-pied a:hover { color: var(--nd-sur-nuit); text-decoration: underline; text-underline-offset: 4px; }
.nd-pied-grille {
  display: grid;
  gap: 40px;
  padding-block: clamp(3.2rem, 6vw, 4.5rem) 0;
}
@media (min-width: 768px) { .nd-pied-grille { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1024px) { .nd-pied-grille { grid-template-columns: 1.5fr 1fr 1fr 1fr; } }
.nd-pied-marque {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--nd-font-titre);
  font-size: 1.1rem;
  color: var(--nd-sur-nuit) !important;
}
.nd-pied-marque img { width: 44px; height: 44px; border-radius: 50%; }
.nd-pied-texte { margin: 16px 0 0; max-width: 36ch; }
.nd-pied-lieu { margin: 12px 0 0; max-width: 36ch; font-size: 11px; font-style: italic; }
.nd-pied h2 {
  margin: 0 0 12px;
  font-family: var(--nd-font-texte);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.17em;
  text-transform: uppercase;
  color: var(--nd-sur-nuit);
}
.nd-pied ul { list-style: none; margin: 0; padding: 0; }
.nd-pied li a { display: block; padding: 4px 0; }
.nd-pied .nd-bouton { margin-top: 16px; color: var(--nd-texte-bouton); }
.nd-pied .nd-bouton:hover { color: var(--nd-texte-bouton); text-decoration: none; }
.nd-reseaux { display: flex; gap: 12px; margin-top: 20px; }
.nd-reseaux a {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border: 1px solid var(--nd-filet-nuit);
  border-radius: 50%;
}
.nd-reseaux a:hover { border-color: var(--nd-orchid); }
.nd-reseaux svg { width: 18px; height: 18px; }
.nd-pied-bas {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  margin-top: 32px;
  padding: 24px 0 32px;
  border-top: 1px solid var(--nd-filet-nuit);
  font-size: 12px;
}
.nd-pied-bas span { display: inline-flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.nd-coeur { width: 14px; height: 14px; fill: var(--nd-orchid); }
.nd-pied-legal { display: flex; gap: 16px; flex-wrap: wrap; }

/* ============================================================
   Bloc « Et maintenant ? »
   ============================================================ */

.nd-suite { padding-block: clamp(3rem, 7vw, 5rem); }
.nd-suite-intro { max-width: 62ch; margin-bottom: 2.5rem; }
.nd-suite-intro p { margin: 0.8rem 0 0; }
.nd-offres {
  display: grid;
  gap: 28px 20px;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr));
}
.nd-offre { display: flex; flex-direction: column; gap: 10px; padding-top: 1.8rem; }
.nd-offre h3 { margin: 0; font-size: 1.35rem; line-height: 1.3; }
.nd-offre p { margin: 0; flex: 1; }
.nd-offre .nd-lien { align-self: flex-start; margin-top: 6px; }
.nd-carte-nuit .nd-lien { color: var(--nd-sur-nuit); text-decoration-color: var(--nd-orchid); }
.nd-offre-vedette { grid-column: 1 / -1; }
.nd-offre-vedette h3 { font-size: clamp(1.5rem, 2.3vw, 2rem); }
.nd-cta-final {
  margin-top: clamp(2.5rem, 6vw, 4rem);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.nd-cta-final h2 { margin: 0; }
.nd-cta-final p { margin: 8px 0 0; max-width: 52ch; }

@media (prefers-reduced-motion: reduce) {
  .nd-bouton, .nd-menu a { transition: none; }
  .nd-bouton:hover:not(:disabled) { transform: none; }
}

/* ---------- Sous-menu « Accompagnements » ---------- */

.nd-sousmenu { position: relative; }
.nd-sousmenu-bouton {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0;
  border: 0;
  background: none;
  color: var(--nd-texte-2);
  font: 500 14px/1.4 var(--nd-font-texte);
  cursor: pointer;
  transition: color 160ms ease;
}
.nd-sousmenu-bouton:hover, .nd-sousmenu-bouton[aria-expanded="true"] { color: var(--nd-texte); }
.nd-sousmenu-bouton svg { width: 14px; height: 14px; transition: transform 200ms ease; }
.nd-sousmenu-bouton[aria-expanded="true"] svg { transform: rotate(180deg); }
.nd-sousmenu-panneau {
  position: absolute;
  top: 100%;
  left: 50%;
  z-index: 40;
  min-width: 16rem;
  padding-top: 12px;
  transform: translate(-50%, -4px);
  opacity: 0;
  visibility: hidden;
  transition: opacity 200ms ease, transform 200ms ease, visibility 0s linear 200ms;
}
.nd-sousmenu.nd-sousmenu-ouvert .nd-sousmenu-panneau {
  transform: translate(-50%, 0);
  opacity: 1;
  visibility: visible;
  transition: opacity 200ms ease, transform 200ms ease, visibility 0s;
}
.nd-sousmenu-panneau ul {
  list-style: none;
  margin: 0;
  padding: 8px;
  background: var(--nd-surface);
  border: 1px solid var(--nd-filet);
  border-radius: 16px;
  box-shadow: 0 24px 50px -24px rgba(28, 16, 51, 0.35);
}
.nd-sousmenu-panneau li { position: relative; padding: 10px 12px; border-radius: var(--nd-rayon-champ); }
.nd-entete .nd-sousmenu-panneau a { color: var(--nd-texte); font-size: 14px; font-weight: 500; white-space: nowrap; }
.nd-entete .nd-sousmenu-panneau a:hover { color: var(--nd-violet); text-decoration: underline; text-underline-offset: 4px; }
/* Description en infobulle, à droite du menu, au survol ou au focus clavier */
.nd-infobulle {
  position: absolute;
  top: 50%;
  left: 100%;
  z-index: 50;
  margin-left: 16px;
  padding: 8px 12px;
  background: #fff;
  border: 1px solid var(--nd-filet);
  border-radius: var(--nd-rayon-champ);
  box-shadow: 0 14px 30px -16px rgba(28, 16, 51, 0.35);
  color: var(--nd-texte-2);
  font-size: 12px;
  line-height: 1.4;
  white-space: nowrap;
  pointer-events: none;
  opacity: 0;
  transform: translate(4px, -50%);
  transition: opacity 150ms ease, transform 150ms ease;
}
.nd-sousmenu-panneau li:hover .nd-infobulle,
.nd-sousmenu-panneau li:focus-within .nd-infobulle { opacity: 1; transform: translate(0, -50%); }

/* Version mobile : les entrées sont listées directement dans le menu */
.nd-menu-mobile-groupe { padding: 12px 0 8px; border-bottom: 1px solid var(--nd-filet); }
.nd-menu-mobile-groupe ul { list-style: none; margin: 8px 0 0; padding: 0; }
.nd-menu-mobile-groupe li { padding: 6px 0; }
.nd-entete .nd-menu-mobile .nd-menu-mobile-groupe a {
  display: inline-block;
  padding: 0;
  border: 0;
  font-family: var(--nd-font-titre);
  font-size: 20px;
  font-weight: 400;
  letter-spacing: -0.02em;
}
.nd-menu-mobile-groupe li span { display: block; margin-top: 2px; font-size: 13px; font-style: italic; color: var(--nd-texte-discret); }

@media (prefers-reduced-motion: reduce) {
  .nd-sousmenu-panneau, .nd-infobulle, .nd-sousmenu-bouton svg { transition: none; }
}
