/* =============================================================================
   base.css — socle commun des maquettes « refonte outils » (21/09/2026)
   -----------------------------------------------------------------------------
   Direction artistique fixée en amont, non négociable :
     · canvas blanc, encre sombre, UNE couleur d'accent par outil
     · titres Sora 700, texte Figtree
     · conteneur 1200 px, sections 96 px (64 px mobile), tout sur une grille de 8 px
     · pas de bande sombre pleine largeur, pas de dégradé, pas de filet latéral coloré

   Utilisation dans une maquette :
     <link rel="stylesheet" href="../_assets/fonts/fonts.css">
     <link rel="stylesheet" href="../_assets/base.css">
     <style> :root { --accent: #2F6BFF; } </style>   <-- couleur de l'outil

   Chaque maquette ne redéfinit QUE --accent (et --accent-ink si l'accent est clair).
   ========================================================================== */


/* -----------------------------------------------------------------------------
   1. Jetons (variables CSS)
   -------------------------------------------------------------------------- */
:root {
  /* Couleur de l'outil — surchargée par chaque maquette. Noir = valeur neutre. */
  --accent: #000000;
  --accent-ink: #FFFFFF;                                   /* texte sur accent plein */
  --accent-hover: color-mix(in srgb, var(--accent) 92%, #000);  /* hover : accent assombri de 8 % */
  --accent-soft: color-mix(in srgb, var(--accent) 8%, #FFF);    /* teinte 8 % : puces, chips */
  --accent-ring: color-mix(in srgb, var(--accent) 35%, transparent); /* anneau de focus */

  /* Encres et surfaces */
  --ink: #111827;        /* titres */
  --text: #374151;       /* texte courant */
  --muted: #6B7280;      /* texte atténué */
  --line: #E6E8EE;       /* filets et bords de cartes */
  --line-strong: #C9CDD6;/* bord de carte au survol */
  --soft: #F7F8FA;       /* surface douce — deux bandes par page au maximum */
  --canvas: #FFFFFF;     /* fond de page */

  /* Formes */
  --radius: 14px;        /* cartes */
  --radius-sm: 10px;     /* boutons, pastilles, logo */
  --radius-pill: 999px;  /* chips */
  --shadow: 0 1px 2px rgba(17, 24, 39, .04), 0 8px 24px rgba(17, 24, 39, .06);

  /* Rythme — tout est multiple de 8 px */
  --container: 1200px;
  --gutter: 24px;        /* 16 px en mobile, cf. § 11 */
  --section-y: 96px;     /* 64 px en mobile, cf. § 11 */
  --space-1: 8px;
  --space-2: 16px;
  --space-3: 24px;
  --space-4: 32px;
  --space-5: 40px;
  --space-6: 48px;
  --space-8: 64px;

  /* Typographie */
  --font-title: 'Sora', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-body: 'Figtree', system-ui, -apple-system, 'Segoe UI', sans-serif;

  /* Mouvement */
  --t: 160ms;
  --ease: cubic-bezier(.2, .6, .3, 1);
}

/* Repli si color-mix n'est pas disponible : on retombe sur des valeurs neutres
   plutôt que sur une variable vide (qui casserait les fonds). */
@supports not (color: color-mix(in srgb, #000 8%, #fff)) {
  :root {
    --accent-hover: var(--accent);
    --accent-soft: var(--soft);
    --accent-ring: var(--line-strong);
  }
}


/* -----------------------------------------------------------------------------
   2. Reset léger
   -------------------------------------------------------------------------- */
*,
*::before,
*::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--canvas);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.6;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;                 /* garde-fou : aucun débordement latéral */
}

h1, h2, h3, h4, p, figure, blockquote, ul, ol, dl { margin: 0; }
ul, ol { padding: 0; list-style: none; }

img, svg, video { display: block; max-width: 100%; }
img { height: auto; }

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

button, input, select, textarea { font: inherit; color: inherit; }

/* Un seul style de focus pour toute la page : contour net #111827 + halo accent léger. */
:focus-visible {
  /* anneau net (contraste > 3:1 sur blanc comme sur les bandes teintées),
     doublé d'un halo accent léger : visible au clavier, invisible à la souris */
  outline: 2px solid var(--focus-ring, #111827);
  outline-offset: 2px;
  box-shadow: 0 0 0 5px var(--accent-ring);
  border-radius: 4px;
}
:focus:not(:focus-visible) { outline: none; }

/* Lien d'évitement : hors écran, il apparaît au focus clavier. */
.skip-link {
  position: absolute; left: 12px; top: -60px; z-index: 1000;
  padding: 10px 16px; border-radius: 10px;
  background: #fff; color: #111827; font-weight: 600;
  box-shadow: 0 0 0 1px var(--line-strong, #d1d5db);
  transition: none;
}
.skip-link:focus, .skip-link:focus-visible { top: 12px; }

/* Réservé aux lecteurs d'écran (libellé du burger, titres de sections muettes). */
.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .001ms !important;
    transition-duration: .001ms !important;
    scroll-behavior: auto !important;
  }
}


/* -----------------------------------------------------------------------------
   3. Conteneur et sections
   -------------------------------------------------------------------------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* Espacement vertical standard d'une section. */
.section { padding-block: var(--section-y); }
.section--tight { padding-block: var(--space-8); }

/* Bande de surface douce. Deux au maximum par page. */
.section--soft { background: var(--soft); }

/* Filet de séparation discret entre deux sections de même fond. */
.section--ruled { border-top: 1px solid var(--line); }

/* En-tête de section : eyebrow + H2 + une ligne d'intro. */
.section-head { max-width: 720px; margin-bottom: var(--space-6); }
.section-head > * + * { margin-top: var(--space-2); }
.section-head p { color: var(--muted); }


/* -----------------------------------------------------------------------------
   4. Typographie
   -------------------------------------------------------------------------- */
.eyebrow {
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 600;
  line-height: 1.4;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--accent);
}

.h1, h1 {
  font-family: var(--font-title);
  font-weight: 700;
  font-size: 44px;
  line-height: 1.1;
  letter-spacing: -.02em;
  color: var(--ink);
  text-wrap: balance;
}
.h1--xl { font-size: 48px; }

.h2, h2 {
  font-family: var(--font-title);
  font-weight: 700;
  font-size: 32px;
  line-height: 1.2;
  letter-spacing: -.015em;
  color: var(--ink);
  text-wrap: balance;
}

.h3, h3 {
  font-family: var(--font-title);
  font-weight: 700;
  font-size: 20px;
  line-height: 1.3;
  letter-spacing: -.01em;
  color: var(--ink);
}

/* Le SEUL mot mis en couleur dans le H1. */
.accent { color: var(--accent); }

.lead { font-size: 19px; line-height: 1.6; color: var(--text); }
.muted { color: var(--muted); }
.small { font-size: 15px; line-height: 1.5; }

/* Lien texte fléché « Lire le guide → ». */
.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  font-weight: 600;
  font-size: 16px;
  color: var(--accent);
}
.link-arrow svg { transition: transform var(--t) var(--ease); }
.link-arrow:hover svg { transform: translateX(3px); }


/* -----------------------------------------------------------------------------
   5. Boutons
   -------------------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-1);
  min-height: 48px;
  padding: 0 var(--space-3);
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 16px;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
  transition: background-color var(--t) var(--ease),
              border-color var(--t) var(--ease),
              color var(--t) var(--ease),
              transform var(--t) var(--ease);
}
.btn:hover { text-decoration: none; }
.btn:active { transform: translateY(1px); }

/* Primaire — accent plein. Un seul par écran. */
.btn--primary {
  background: var(--accent);
  color: var(--accent-ink);
}
.btn--primary:hover { background: var(--accent-hover); }

/* Secondaire — contour encre, fond blanc. */
.btn--secondary {
  background: var(--canvas);
  color: var(--ink);
  border-color: var(--ink);
}
.btn--secondary:hover { background: var(--ink); color: var(--canvas); }

/* Discret — pour la nav (Connexion, FR/EN). */
.btn--ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--line);
}
.btn--ghost:hover { border-color: var(--line-strong); background: var(--soft); }

.btn--block { width: 100%; }


/* -----------------------------------------------------------------------------
   6. Barre de navigation
   -------------------------------------------------------------------------- */
.nav {
  position: relative;
  z-index: 20;
  border-bottom: 1px solid var(--line);
  background: var(--canvas);
}
.nav__inner {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  height: 64px;
}

/* Variante : liens centrés, marque à gauche, actions à droite. */
.nav--centered .nav__links { justify-content: center; flex: 1; }

/* Marque : carré 36 px aux couleurs de l'outil + nom + « by Belentia ». */
.brand { display: flex; align-items: center; gap: var(--space-2); text-decoration: none; }
.brand:hover { text-decoration: none; }
.brand__mark {
  display: grid;
  place-items: center;
  width: 36px; height: 36px;
  flex: 0 0 36px;
  border-radius: var(--radius-sm);
  background: var(--accent);
  color: var(--accent-ink);
}
.brand__mark svg { width: 20px; height: 20px; }
.brand__text { display: flex; flex-direction: column; line-height: 1.1; }
.brand__name {
  font-family: var(--font-title);
  font-weight: 700;
  font-size: 18px;
  color: var(--ink);
}
.brand__by { font-size: 11px; color: var(--muted); }

.nav__links {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin-left: var(--space-5);
}
.nav__link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;                    /* cible tactile */
  padding-inline: 4px;
  font-weight: 500;
  font-size: 16px;
  color: var(--text);
}
.nav__link { white-space: nowrap; }
/* textes courants : pas de mot seul en fin de paragraphe */
p, li, dd, blockquote, figcaption, .fact > span { text-wrap: pretty; }
/* libellés courts et questions : lignes équilibrées, jamais un mot seul (boucle 5) */
.faq summary, .tool__d, .link-arrow, .check__title, .step__d, .ticks li > span { text-wrap: balance; }
.nav__link:hover { color: var(--ink); text-decoration: none; }
.nav__link[aria-current="page"] { color: var(--ink); font-weight: 600; }

.nav__spacer { margin-left: auto; }
.nav__actions { display: flex; align-items: center; gap: var(--space-2); }
.nav__actions .btn { min-height: 44px; padding-inline: var(--space-2); white-space: nowrap; }


/* -----------------------------------------------------------------------------
   7. Menu « Plus » — <details> natif, panneau 260 px
   (fermeture au clic extérieur et à Échap : voir le JS de chaque maquette)
   -------------------------------------------------------------------------- */
.more { position: relative; }
.more > summary {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 44px;
  padding-inline: 4px;
  font-weight: 500;
  font-size: 16px;
  color: var(--text);
  cursor: pointer;
  list-style: none;
  user-select: none;
}
.more > summary::-webkit-details-marker { display: none; }
.more > summary:hover { color: var(--ink); }
.more > summary svg { transition: transform var(--t) var(--ease); }
.more[open] > summary svg { transform: rotate(180deg); }

.more__panel {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  width: 260px;
  padding: var(--space-1);
  background: var(--canvas);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.more__panel a {
  display: block;
  min-height: 44px;
  padding: 11px var(--space-2);
  border-radius: var(--radius-sm);
  font-size: 16px;
  font-weight: 500;
  color: var(--text);
}
.more__panel a:hover { background: var(--soft); color: var(--ink); text-decoration: none; }


/* -----------------------------------------------------------------------------
   8. Burger mobile — panneau plein écran, sans dépendance
   -------------------------------------------------------------------------- */
.burger {
  display: none;                       /* affiché sous 900 px, cf. § 11 */
  align-items: center;
  justify-content: center;
  width: 44px; height: 44px;
  margin-left: auto;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  color: var(--ink);
  cursor: pointer;
}
.burger:hover { border-color: var(--line-strong); }

.mobile-panel {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 50;
  background: var(--canvas);
  /* le .container intérieur porte déjà la gouttière : pas de double marge,
     la marque et le bouton Fermer restent à la place de la marque et du burger */
  padding: 0 0 var(--gutter);
  overflow-y: auto;
}
.mobile-panel[data-open="true"] { display: block; }
.mobile-panel__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  margin-bottom: var(--space-3);
}
.mobile-panel__close {
  width: 44px; height: 44px;
  display: grid; place-items: center;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  color: var(--ink);
  cursor: pointer;
}
.mobile-panel nav a {
  display: block;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
  font-family: var(--font-title);
  font-weight: 700;
  font-size: 20px;
  color: var(--ink);
}
.mobile-panel nav a:hover { text-decoration: none; color: var(--accent); }
.mobile-panel .btn { margin-top: var(--space-4); }

/* Quand le panneau est ouvert, la page dessous ne défile plus. */
body[data-menu-open="true"] { overflow: hidden; }


/* -----------------------------------------------------------------------------
   9. Cartes
   -------------------------------------------------------------------------- */
.card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  padding: var(--space-3);
  background: var(--canvas);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  transition: transform var(--t) var(--ease),
              border-color var(--t) var(--ease),
              box-shadow var(--t) var(--ease);
}
.card:hover {
  transform: translateY(-2px);
  border-color: var(--line-strong);
  box-shadow: 0 6px 20px rgba(17, 24, 39, .06);
}
.card p { color: var(--text); }
.card .h3 + p { margin-top: 0; }

/* Pastille d'icône : teinte 8 % de l'accent, glyphe SVG de 20 px. */
.card__icon {
  display: grid;
  place-items: center;
  width: 40px; height: 40px;
  border-radius: var(--radius-sm);
  background: var(--accent-soft);
  color: var(--accent);
}
.card__icon svg { width: 20px; height: 20px; }

/* Carte non cliquable : on neutralise le survol. */
.card--static:hover { transform: none; border-color: var(--line); box-shadow: none; }


/* -----------------------------------------------------------------------------
   10. Carte de guide — couverture RÉELLE en 16:10, chip, titre 2 lignes
   -------------------------------------------------------------------------- */
.guide-card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: var(--canvas);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  transition: transform var(--t) var(--ease),
              border-color var(--t) var(--ease),
              box-shadow var(--t) var(--ease);
}
.guide-card:hover { text-decoration: none; }
.guide-card:hover .link-arrow { text-decoration: underline; }
.guide-card:hover {
  transform: translateY(-2px);
  border-color: var(--line-strong);
  box-shadow: 0 6px 20px rgba(17, 24, 39, .06);
}
.guide-card__cover {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  background: var(--soft);
  border-bottom: 1px solid var(--line);
}
.guide-card__body {
  display: flex;
  flex: 1 1 auto;                 /* « Lire le guide » aligné en bas de chaque carte */
  flex-direction: column;
  gap: var(--space-1);
  padding: var(--space-3);
}
.guide-card__body > .link-arrow:last-child { margin-top: auto; padding-top: var(--space-1); }
.guide-card__title {
  font-family: var(--font-title);
  font-weight: 700;
  font-size: 20px;
  line-height: 1.3;
  color: var(--ink);
  /* titre toujours entier (jamais tronqué), sans mot seul en fin */
  text-wrap: balance;
}
.guide-card__excerpt {
  font-size: 16px;
  color: var(--muted);
  /* deux lignes d'accroche au plus */
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.guide-card .link-arrow { margin-top: var(--space-1); }


/* -----------------------------------------------------------------------------
   11. Chips
   -------------------------------------------------------------------------- */
.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  align-self: flex-start;
  padding: 5px 11px;
  border-radius: var(--radius-pill);
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 13px;
  font-weight: 600;
  line-height: 1.4;
}
.chip--neutral { background: var(--soft); color: var(--muted); }
.chip svg { width: 14px; height: 14px; }


/* -----------------------------------------------------------------------------
   12. Listes à puces teintées
   -------------------------------------------------------------------------- */
.ticks { display: grid; gap: var(--space-2); }
.ticks li { display: flex; align-items: flex-start; gap: var(--space-2); }
.ticks__mark {
  display: grid;
  place-items: center;
  width: 24px; height: 24px;
  flex: 0 0 24px;
  margin-top: 2px;
  border-radius: 8px;
  background: var(--accent-soft);
  color: var(--accent);
}
.ticks__mark svg { width: 14px; height: 14px; }


/* -----------------------------------------------------------------------------
   13. FAQ — lignes <details>, filet 1 px, chevron SVG
   -------------------------------------------------------------------------- */
.faq { border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  min-height: 56px;
  padding: var(--space-2) 0;
  font-family: var(--font-title);
  font-weight: 700;
  font-size: 18px;
  line-height: 1.4;
  color: var(--ink);
  cursor: pointer;
  list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary:hover { color: var(--accent); }
.faq summary svg {
  flex: 0 0 20px;
  color: var(--muted);
  transition: transform var(--t) var(--ease);
}
.faq details[open] summary svg { transform: rotate(180deg); }
.faq__answer {
  padding: 0 0 var(--space-3);
  max-width: 68ch;
  color: var(--text);
}
.faq__answer p + p { margin-top: var(--space-2); }


/* -----------------------------------------------------------------------------
   14. Pied de page — une rangée, sobre
   -------------------------------------------------------------------------- */
.footer {
  border-top: 1px solid var(--line);
  padding-block: var(--space-6);
  background: var(--canvas);
}
.footer__row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-3) var(--space-4);
}
.footer__tagline { font-size: 15px; color: var(--muted); max-width: 40ch; }
.footer__links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-1) var(--space-3);
  margin-left: auto;
}
.footer__links a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font-size: 15px;
  color: var(--text);
}
.footer__links a:hover { color: var(--ink); }
.footer__legal {
  margin-top: var(--space-3);
  padding-top: var(--space-3);
  border-top: 1px solid var(--line);
  font-size: 14px;
  color: var(--muted);
}


/* -----------------------------------------------------------------------------
   15. Grilles
   -------------------------------------------------------------------------- */
.grid { display: grid; gap: var(--space-3); }
.grid-2 { display: grid; gap: var(--space-3); grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { display: grid; gap: var(--space-3); grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { display: grid; gap: var(--space-3); grid-template-columns: repeat(4, minmax(0, 1fr)); }

/* Deux colonnes déséquilibrées (texte + visuel). */
.split {
  display: grid;
  gap: var(--space-8);
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: center;
}
.split--wide-left { grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); }

/* Pile d'éléments avec un pas de 8 px. */
.stack > * + * { margin-top: var(--space-2); }
.stack-3 > * + * { margin-top: var(--space-3); }
.stack-4 > * + * { margin-top: var(--space-4); }

/* Rangée d'actions : un primaire + un secondaire. */
.actions { display: flex; flex-wrap: wrap; gap: var(--space-2); }

/* Visuel encadré (capture produit, couverture). */
.frame {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--canvas);
}
.frame img { width: 100%; display: block; }


/* -----------------------------------------------------------------------------
   16. Points de rupture
   -------------------------------------------------------------------------- */

/* Tablette — les grilles à 3 et 4 colonnes passent à 2. */
@media (max-width: 1024px) {
  .grid-3, .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .split, .split--wide-left { gap: var(--space-6); }
  .nav__links { gap: var(--space-2); margin-left: var(--space-3); }
  .footer__links { margin-left: 0; flex-basis: 100%; }
}
/* 901-1100 px : la barre complète doit tenir sur une ligne, même avec des libellés longs */
@media (min-width: 901px) and (max-width: 1100px) {
  .nav__inner { gap: var(--space-2); }
  .nav__links { gap: 12px; margin-left: var(--space-2); }
  .nav__link { font-size: 15px; }
  .nav__actions { gap: 4px; }
}

/* Bascule mobile de la navigation. */
@media (max-width: 900px) {
  .nav__links, .nav__actions { display: none; }
  .burger { display: inline-flex; }
  .split, .split--wide-left { grid-template-columns: minmax(0, 1fr); }
}

/* Mobile — gouttières 16 px, sections 64 px, typo réduite. */
@media (max-width: 720px) {
  :root {
    --gutter: 16px;
    --section-y: 64px;
  }

  body { font-size: 16px; }

  .h1, h1 { font-size: 32px; }
  .h1--xl { font-size: 32px; }
  .h2, h2 { font-size: 26px; }
  .h3, h3 { font-size: 19px; }
  .lead { font-size: 17px; }

  .grid-2, .grid-3, .grid-4 { grid-template-columns: minmax(0, 1fr); }

  .section-head { margin-bottom: var(--space-4); }

  .actions { flex-direction: column; align-items: stretch; }
  .actions .btn { width: 100%; }

  .footer__row { flex-direction: column; align-items: flex-start; }
  .footer__links { margin-left: 0; }

  .faq summary { font-size: 17px; }
}
