/* ============================================================
   josselinleydier.com — Design System
   ============================================================ */

/* 1. Variables
   ============================================================ */
:root {
  --primary:       #05106e;
  --primary-light: #1e2d9c;
  --primary-pale:  #eaecf7;
  --dark:          #1c1c1c;
  --dark-mid:      #2e2e2e;
  --text:          #1c1c1c;
  --text-light:    #5a5a5a;
  --text-muted:    #8a8a8a;
  --bg:            #f5f4f0;
  --bg-alt:        #edecea;
  --bg-white:      #ffffff;
  --border:        rgba(28, 28, 28, 0.12);
  --border-strong: rgba(28, 28, 28, 0.22);
  --shadow:        rgba(28, 28, 28, 0.08);

  --font-serif:    'Lora', Georgia, serif;
  --font-sans:     'Inter', system-ui, -apple-system, sans-serif;

  --radius:        4px;
  --radius-md:     8px;
  --max-width:     1160px;
  --max-article:   760px;
}

/* 2. Reset & Base
   ============================================================ */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 18px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.85;
  color: var(--text);
  background: var(--bg-white);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

a {
  color: var(--primary);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  transition: color 0.15s;
}

a:hover {
  color: var(--primary-light);
}

ul, ol {
  padding-left: 1.4em;
}

/* 3. Typographie
   ============================================================ */
h1, h2, h3 {
  font-family: var(--font-serif);
  font-weight: 700;
  line-height: 1.25;
  color: var(--dark);
}

h4, h5, h6 {
  font-family: var(--font-sans);
  font-weight: 600;
  line-height: 1.35;
  color: var(--dark);
}

h1 { font-size: clamp(1.9rem, 4vw, 2.8rem); }
h2 { font-size: clamp(1.4rem, 3vw, 2rem);   }
h3 { font-size: clamp(1.1rem, 2vw, 1.4rem); }
h4 { font-size: 0.9rem; text-transform: uppercase; letter-spacing: 0.08em; }

p { margin-bottom: 1.2em; }
p:last-child { margin-bottom: 0; }

strong { font-weight: 600; }

/* 4. Layout
   ============================================================ */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

.container--narrow {
  max-width: var(--max-article);
}

/* 5. Navigation
   ============================================================ */
.site-header {
  background: var(--bg-white);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
}

.site-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.site-logo {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  flex-shrink: 0;
}

.site-logo img {
  height: 32px;
  width: auto;
  display: block;
}

.site-logo:hover {
  opacity: 0.85;
}

.footer-brand .site-logo img {
  filter: brightness(0) invert(1);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 32px;
  list-style: none;
  padding: 0;
  margin: 0;
}

.site-nav a {
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text);
  text-decoration: none;
  letter-spacing: 0.01em;
  padding: 4px 0;
  border-bottom: 2px solid transparent;
  transition: color 0.15s, border-color 0.15s;
}

.site-nav a:hover,
.site-nav a.active {
  color: var(--primary);
  border-bottom-color: var(--primary);
}

.site-nav .nav-cta {
  background: var(--primary);
  color: #fff;
  padding: 8px 18px;
  border-radius: var(--radius);
  border-bottom: none;
  transition: background 0.15s;
}

.site-nav .nav-cta:hover {
  background: var(--primary-light);
  color: #fff;
  border-bottom: none;
}

/* Dropdown */
.has-dropdown {
  position: relative;
}

.nav-arrow {
  font-size: 0.7rem;
  opacity: 0.55;
  margin-left: 1px;
  display: inline-block;
  transition: transform 0.2s;
}

.has-dropdown.open .nav-arrow {
  transform: rotate(180deg);
}

.nav-dropdown {
  display: none;
  position: absolute;
  top: 100%;
  left: -16px;
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: 0 8px 24px var(--shadow);
  min-width: 210px;
  padding: 6px 0;
  list-style: none;
  z-index: 200;
  margin-top: 8px;
}

/* Pont invisible entre le lien et le dropdown pour éviter la rupture du hover */
.nav-dropdown::before {
  content: '';
  position: absolute;
  top: -8px;
  left: 0;
  right: 0;
  height: 8px;
}

.has-dropdown:hover .nav-dropdown,
.has-dropdown.open .nav-dropdown {
  display: block;
}

.nav-dropdown li {
  width: 100%;
}

.nav-dropdown a {
  display: block;
  padding: 9px 20px;
  font-size: 0.84rem;
  font-weight: 500;
  color: var(--text);
  text-decoration: none;
  border-bottom: none;
  white-space: nowrap;
  transition: color 0.12s, background 0.12s;
}

.nav-dropdown a:hover {
  color: var(--primary);
  background: var(--primary-pale);
  border-bottom: none;
}

/* Burger mobile */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  flex-direction: column;
  gap: 5px;
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--dark);
  transition: transform 0.2s, opacity 0.2s;
}

/* 6. En-tête de page
   ============================================================ */
.page-header {
  border-bottom: 1px solid var(--border);
  padding: 48px 0 40px;
  background: var(--bg-white);
}

.page-header-inner {
  max-width: 720px;
}

.page-eyebrow {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--primary);
  margin-bottom: 14px;
}

.page-header h1 {
  margin-bottom: 16px;
}

.page-intro {
  font-size: 1.05rem;
  color: var(--text-light);
  margin-bottom: 0;
  line-height: 1.75;
}

/* Variante sombre (accueil uniquement) */
.page-header--dark {
  background: var(--dark);
  border-bottom-color: rgba(255,255,255,0.08);
}

.page-header--dark .page-eyebrow {
  color: var(--primary-pale);
}

.page-header--dark h1 {
  color: #fff;
}

.page-header--dark .page-intro {
  color: rgba(255,255,255,0.7);
}

/* 7. Fil d'Ariane
   ============================================================ */
.breadcrumb {
  padding: 14px 0;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.breadcrumb ol {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  list-style: none;
  padding: 0;
  margin: 0;
  align-items: center;
}

.breadcrumb li + li::before {
  content: '/';
  margin-right: 6px;
  color: var(--border-strong);
}

.breadcrumb a {
  color: var(--text-muted);
  text-decoration: none;
}

.breadcrumb a:hover {
  color: var(--primary);
}

/* 8. Layout article (article + sidebar)
   ============================================================ */
.article-layout {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 56px;
  align-items: start;
  padding: 48px 0 72px;
  max-width: var(--max-width);
  margin: 0 auto;
  padding-left: 24px;
  padding-right: 24px;
}

.article-body {
  min-width: 0;
}

.article-figure {
  margin: 0 0 40px;
  border-radius: var(--radius-md);
  overflow: hidden;
  line-height: 0;
}

.article-figure img {
  width: 100%;
  max-height: 360px;
  object-fit: cover;
  display: block;
}

.article-body h2 {
  margin-top: 2.4em;
  margin-bottom: 0.7em;
  padding-top: 0.4em;
  border-top: 2px solid var(--border);
}

.article-body h2:first-child {
  margin-top: 0;
  border-top: none;
}

.article-body h3 {
  margin-top: 1.6em;
  margin-bottom: 0.5em;
}

.article-body ul,
.article-body ol {
  margin-bottom: 1.2em;
}

.article-body li {
  margin-bottom: 0.3em;
}

/* 9. Sidebar
   ============================================================ */
.sidebar {
  position: sticky;
  top: 80px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.sidebar-block {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 20px;
}

.sidebar-block h4 {
  color: var(--text-muted);
  margin-bottom: 12px;
}

.sidebar-toc {
  list-style: none;
  padding: 0;
}

.sidebar-toc li {
  border-bottom: 1px solid var(--border);
  margin-bottom: 0;
}

.sidebar-toc li:last-child {
  border-bottom: none;
}

.sidebar-toc a {
  display: block;
  padding: 8px 0;
  font-size: 0.85rem;
  color: var(--text);
  text-decoration: none;
}

.sidebar-toc a:hover {
  color: var(--primary);
}

.sidebar-links {
  list-style: none;
  padding: 0;
}

.sidebar-links li {
  border-bottom: 1px solid var(--border);
  margin-bottom: 0;
}

.sidebar-links li:last-child {
  border-bottom: none;
}

.sidebar-links a {
  display: block;
  padding: 8px 0;
  font-size: 0.85rem;
  text-decoration: none;
  color: var(--text);
}

.sidebar-links a:hover {
  color: var(--primary);
}

.sidebar-cta {
  background: var(--primary);
  border-radius: var(--radius-md);
  padding: 22px;
  color: #fff;
}

.sidebar-cta h3,
.sidebar-cta h4 {
  color: rgba(255,255,255,0.7);
  margin-bottom: 8px;
}

.sidebar-cta p {
  font-size: 0.9rem;
  color: rgba(255,255,255,0.88);
  margin-bottom: 16px;
}

.sidebar-cta a {
  display: inline-block;
  background: #fff;
  color: var(--primary);
  padding: 9px 18px;
  border-radius: var(--radius);
  font-size: 0.85rem;
  font-weight: 600;
  text-decoration: none;
  transition: opacity 0.15s;
}

.sidebar-cta a:hover {
  opacity: 0.9;
  color: var(--primary);
}

/* 10. Info-box / Highlight-box
   ============================================================ */
.info-box {
  background: var(--primary-pale);
  border-left: 3px solid var(--primary);
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  padding: 20px 24px;
  margin: 28px 0;
}

.info-box h3 {
  font-size: 1rem;
  margin-bottom: 8px;
  color: var(--primary);
}

.info-box p:last-child {
  margin-bottom: 0;
}

.highlight-box {
  background: var(--bg-alt);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-md);
  padding: 22px 26px;
  margin: 28px 0;
}

/* 11. Boutons
   ============================================================ */
.btn {
  display: inline-block;
  padding: 12px 28px;
  font-family: var(--font-sans);
  font-size: 0.9rem;
  font-weight: 600;
  border-radius: var(--radius);
  text-decoration: none;
  border: 2px solid transparent;
  cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
  line-height: 1.4;
}

.btn-primary {
  background: var(--primary);
  color: #fff;
}

.btn-primary:hover {
  background: var(--primary-light);
  color: #fff;
}

.btn-outline {
  background: transparent;
  color: var(--primary);
  border-color: var(--primary);
}

.btn-outline:hover {
  background: var(--primary);
  color: #fff;
}

.btn-ghost {
  background: transparent;
  color: var(--text);
  border-color: var(--border-strong);
}

.btn-ghost:hover {
  border-color: var(--dark);
  color: var(--dark);
}

.btn-white {
  background: #fff;
  color: var(--primary);
  border-color: #fff;
}

.btn-white:hover {
  background: var(--primary-pale);
  color: var(--primary);
  border-color: var(--primary-pale);
}

/* 12. Badges / Tags
   ============================================================ */
.tag {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 3px 10px;
  border-radius: 2px;
  background: var(--bg-alt);
  color: var(--text-light);
  text-decoration: none;
}

.tag:hover {
  background: var(--primary-pale);
  color: var(--primary);
}

.tag--primary {
  background: var(--primary-pale);
  color: var(--primary);
}

/* 13. Cards (blog, lexique)
   ============================================================ */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(300px, 100%), 1fr));
  gap: 24px;
}

.card {
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: box-shadow 0.2s, border-color 0.2s;
}

.card:hover {
  box-shadow: 0 4px 20px var(--shadow);
  border-color: var(--border-strong);
}

.card-img {
  aspect-ratio: 16/9;
  overflow: hidden;
}

.card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s;
}

.card:hover .card-img img {
  transform: scale(1.03);
}

.card-body {
  padding: 22px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.card-meta {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-bottom: 10px;
  display: flex;
  gap: 12px;
  align-items: center;
}

.card-body h3,
.card-body h2 {
  font-size: 1.05rem;
  margin-bottom: 10px;
  line-height: 1.3;
}

.card-body h3 a,
.card-body h2 a {
  color: var(--dark);
  text-decoration: none;
}

.card-body h3 a:hover,
.card-body h2 a:hover {
  color: var(--primary);
}

.card-body p {
  font-size: 0.88rem;
  color: var(--text-light);
  line-height: 1.65;
  margin-bottom: 0;
  flex: 1;
}

.card-footer {
  padding: 14px 22px;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.card-link {
  font-size: 0.82rem;
  font-weight: 600;
  text-decoration: none;
}

/* 14. Sections génériques
   ============================================================ */
.section {
  padding: 72px 0;
}

.section--alt {
  background: var(--bg-alt);
}

.section--white {
  background: var(--bg-white);
}

.section--dark {
  background: var(--dark);
  color: #fff;
}

.section--dark h2,
.section--dark h3,
.section--dark h4 {
  color: #fff;
}

.section--dark p {
  color: rgba(255,255,255,0.78);
}

.section-header {
  max-width: 600px;
  margin-bottom: 48px;
}

.section-header h2 {
  margin-bottom: 14px;
}

.section-header p {
  color: var(--text-light);
  font-size: 1rem;
  margin-bottom: 0;
}

.section-header--center {
  text-align: center;
  margin-left: auto;
  margin-right: auto;
}

/* 15. Outils (pages /outils/)
   ============================================================ */
.tool-wrap {
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 32px;
  margin-bottom: 32px;
}

.tool-wrap textarea,
.tool-wrap input[type="text"],
.tool-wrap input[type="url"] {
  width: 100%;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  color: var(--text);
  background: var(--bg);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  padding: 12px 16px;
  resize: vertical;
  line-height: 1.7;
  transition: border-color 0.15s;
}

.tool-wrap textarea:focus,
.tool-wrap input:focus {
  outline: none;
  border-color: var(--primary);
}

.tool-result {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  font-family: 'Courier New', monospace;
  font-size: 0.85rem;
  white-space: pre-wrap;
  word-break: break-all;
  min-height: 80px;
  margin-top: 16px;
}

.tool-stats {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
  margin-top: 16px;
}

.tool-stat {
  text-align: center;
  min-width: 100px;
}

.tool-stat-value {
  display: block;
  font-size: 2rem;
  font-weight: 700;
  font-family: var(--font-serif);
  color: var(--primary);
  line-height: 1;
}

.tool-stat-label {
  font-size: 0.78rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* 16. Article partenaire
   ============================================================ */
.partner-notice {
  background: var(--bg-alt);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  padding: 10px 16px;
  font-size: 0.78rem;
  color: var(--text-muted);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-weight: 600;
  margin-bottom: 32px;
  display: inline-block;
}

/* 17. Lexique (index)
   ============================================================ */
.lexique-alphabet {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 40px;
}

.lexique-alphabet a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text);
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  text-decoration: none;
  transition: all 0.15s;
}

.lexique-alphabet a:hover,
.lexique-alphabet a.active {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

.lexique-group {
  margin-bottom: 48px;
}

.lexique-group-letter {
  font-family: var(--font-serif);
  font-size: 2.4rem;
  color: var(--primary);
  border-bottom: 2px solid var(--border);
  padding-bottom: 8px;
  margin-bottom: 20px;
  line-height: 1;
}

.lexique-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 8px;
  list-style: none;
  padding: 0;
}

.lexique-list li a {
  display: block;
  padding: 10px 14px;
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-size: 0.88rem;
  color: var(--text);
  text-decoration: none;
  transition: all 0.15s;
}

.lexique-list li a:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: var(--primary-pale);
}

/* 18. Footer
   ============================================================ */
.site-footer {
  background: var(--dark);
  color: rgba(255,255,255,0.65);
  padding: 56px 0 32px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 48px;
}

.footer-brand .site-logo {
  color: #fff;
  display: inline-block;
  margin-bottom: 14px;
}

.footer-brand p {
  font-size: 0.85rem;
  line-height: 1.7;
  margin-bottom: 0;
}

.footer-col h4 {
  color: #fff;
  margin-bottom: 16px;
  font-size: 0.78rem;
}

.footer-col ul {
  list-style: none;
  padding: 0;
}

.footer-col ul li {
  margin-bottom: 8px;
}

.footer-col ul a {
  font-size: 0.85rem;
  color: rgba(255,255,255,0.55);
  text-decoration: none;
  transition: color 0.15s;
}

.footer-col ul a:hover {
  color: #fff;
}

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.78rem;
}

/* 19. Page 404
   ============================================================ */
.error-404 {
  padding: 96px 24px;
  text-align: center;
}

.error-404-inner {
  max-width: 520px;
  margin: 0 auto;
}

.error-code {
  display: block;
  font-family: var(--font-serif);
  font-size: 7rem;
  font-weight: 700;
  color: var(--primary);
  line-height: 1;
  margin-bottom: 16px;
}

.error-404 h1 {
  font-size: 1.7rem;
  margin-bottom: 14px;
}

.error-404 > .error-404-inner > p {
  color: var(--text-light);
  margin-bottom: 36px;
}

.error-suggestions {
  margin-top: 48px;
}

.error-suggestions h2 {
  font-size: 1rem;
  color: var(--text-muted);
  margin-bottom: 14px;
  font-family: var(--font-sans);
  font-weight: 600;
}

.error-suggestions ul {
  list-style: none;
  padding: 0;
}

.error-suggestions li {
  margin-bottom: 8px;
}

.error-suggestions a {
  color: var(--primary);
}

/* 20. Responsive
   ============================================================ */
@media (max-width: 1024px) {
  .article-layout {
    grid-template-columns: 1fr 260px;
    gap: 36px;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 768px) {
  html { font-size: 17px; }

  .page-header {
    padding: 32px 0 28px;
  }

  .site-nav {
    display: none;
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    background: var(--bg-white);
    flex-direction: column;
    align-items: flex-start;
    padding: 16px 24px 24px;
    border-bottom: 1px solid var(--border);
    gap: 0;
    box-shadow: 0 8px 24px var(--shadow);
  }

  .site-nav.open {
    display: flex;
  }

  .site-nav li {
    width: 100%;
    border-bottom: 1px solid var(--border);
  }

  .site-nav li:last-child {
    border-bottom: none;
  }

  .site-nav a {
    display: block;
    padding: 14px 0;
    border-bottom: none;
  }

  .site-nav .nav-cta {
    margin-top: 12px;
    text-align: center;
    display: block;
    padding: 12px;
  }

  /* Dropdown mobile : inline sous le parent */
  .has-dropdown {
    position: static;
  }

  .nav-dropdown {
    position: static;
    box-shadow: none;
    border: none;
    border-radius: 0;
    background: var(--bg);
    padding: 0;
    min-width: 0;
    width: 100%;
    border-top: 1px solid var(--border);
  }

  .has-dropdown:hover .nav-dropdown {
    display: none;
  }

  .has-dropdown.open .nav-dropdown {
    display: block;
  }

  .nav-dropdown a {
    padding: 11px 16px 11px 28px;
    font-size: 0.84rem;
    color: var(--text-light);
  }

  .nav-dropdown li {
    border-bottom: 1px solid var(--border);
  }

  .nav-dropdown li:last-child {
    border-bottom: none;
  }

  .nav-toggle {
    display: flex;
  }

  .article-layout {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: static;
    order: -1;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .footer-bottom {
    flex-direction: column;
    gap: 8px;
    text-align: center;
  }

  .page-hero {
    padding: 52px 0 44px;
  }

  .section {
    padding: 48px 0;
  }

  .tool-stats {
    justify-content: center;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 16px;
  }

  .article-layout {
    padding-left: 16px;
    padding-right: 16px;
  }

  .card-grid {
    grid-template-columns: 1fr;
  }

  .lexique-list {
    grid-template-columns: 1fr 1fr;
  }

  .lexique-alphabet a {
    width: 32px;
    height: 32px;
    font-size: 0.8rem;
  }

  .page-header {
    padding: 24px 0 20px;
  }

  .section {
    padding: 36px 0;
  }

  .section-header {
    margin-bottom: 28px;
  }

  .split-aside {
    padding: 20px;
  }

  .tool-wrap {
    padding: 20px;
  }
}

/* 21. Étapes numérotées
   ============================================================ */
.steps {
  list-style: none;
  padding: 0;
  counter-reset: step-counter;
}

.steps li {
  counter-increment: step-counter;
  position: relative;
  padding-left: 68px;
  margin-bottom: 32px;
  min-height: 48px;
}

.steps li::before {
  content: counter(step-counter);
  position: absolute;
  left: 0;
  top: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  background: var(--primary);
  color: #fff;
  font-family: var(--font-serif);
  font-size: 1.2rem;
  font-weight: 700;
  border-radius: 50%;
}

.steps li > strong {
  display: block;
  font-size: 1rem;
  margin-bottom: 6px;
  color: var(--dark);
}

.steps li p {
  margin-bottom: 0;
  color: var(--text-light);
  font-size: 0.95rem;
}

/* 22. Section split (texte + contenu 2 colonnes)
   ============================================================ */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}

.split--reverse .split-content:first-child {
  order: 2;
}

.split-content h2 {
  margin-bottom: 16px;
}

.split-content p {
  color: var(--text-light);
}

.split-aside {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 32px;
}

/* 23. Services vitrine (page d'accueil)
   ============================================================ */
.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2px;
  background: var(--border);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.service-item {
  background: var(--bg-white);
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0;
}

.service-item-img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  display: block;
  flex-shrink: 0;
}

.service-item-body {
  padding: 28px 32px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  flex: 1;
}

.service-item-body h3 {
  font-size: 1.15rem;
  margin-bottom: 0;
}

.service-item-body p {
  font-size: 0.9rem;
  color: var(--text-light);
  line-height: 1.7;
  margin-bottom: 0;
  flex: 1;
}

.service-item-body a {
  font-size: 0.85rem;
  font-weight: 600;
  text-decoration: none;
  color: var(--primary);
  margin-top: auto;
}

.service-item-body a:hover {
  text-decoration: underline;
}

/* 24. Ressources hub (page d'accueil)
   ============================================================ */
.hub-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.hub-item {
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 0;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  display: block;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.hub-item:hover {
  border-color: var(--primary);
  box-shadow: 0 4px 16px var(--shadow);
  color: inherit;
}

.hub-item-img {
  width: 100%;
  height: 160px;
  object-fit: cover;
  display: block;
  flex-shrink: 0;
}

.hub-item-body {
  padding: 24px 28px;
}

.hub-item-label {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--primary);
  margin-bottom: 10px;
}

.hub-item h3 {
  font-size: 1.05rem;
  margin-bottom: 8px;
  color: var(--dark);
}

.hub-item p {
  font-size: 0.85rem;
  color: var(--text-light);
  line-height: 1.65;
  margin-bottom: 0;
}

/* 25. Tool cards (page /outils/)
   ============================================================ */
.tool-grid-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.tool-card {
  display: flex;
  gap: 20px;
  align-items: flex-start;
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 24px;
  text-decoration: none;
  color: inherit;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.tool-card:hover {
  border-color: var(--primary);
  box-shadow: 0 4px 16px var(--shadow);
  color: inherit;
}

.tool-card-icon {
  flex-shrink: 0;
  width: 52px;
  height: 52px;
  background: var(--primary-pale);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
}

.tool-card-body {
  flex: 1;
  min-width: 0;
}

.tool-card-label {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--primary);
  margin-bottom: 6px;
}

.tool-card h3 {
  font-size: 1rem;
  margin: 0 0 6px;
  color: var(--dark);
}

.tool-card p {
  font-size: 0.85rem;
  color: var(--text-light);
  line-height: 1.6;
  margin: 0 0 10px;
}

.tool-card-cta {
  font-size: 0.82rem;
  color: var(--primary);
  font-weight: 600;
}

/* 26. Tableau comparatif
   ============================================================ */
.table-wrap {
  overflow-x: auto;
  margin: 24px 0;
}

.table-wrap table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

.table-wrap th {
  background: var(--dark);
  color: #fff;
  padding: 12px 16px;
  text-align: left;
  font-weight: 600;
  font-size: 0.82rem;
  letter-spacing: 0.04em;
}

.table-wrap td {
  padding: 12px 16px;
  border-bottom: 1px solid var(--border);
  color: var(--text);
  vertical-align: top;
}

.table-wrap tr:nth-child(even) td {
  background: var(--bg-alt);
}

.table-wrap tr:last-child td {
  border-bottom: none;
}

/* 26. FAQ
   ============================================================ */
.faq-list {
  margin-top: 24px;
}

.faq-item {
  border-bottom: 1px solid var(--border);
}

.faq-item:first-child {
  border-top: 1px solid var(--border);
}

.faq-question {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 0;
  cursor: pointer;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--dark);
  user-select: none;
  gap: 16px;
}

.faq-question::after {
  content: '+';
  font-size: 1.3rem;
  font-weight: 400;
  color: var(--primary);
  flex-shrink: 0;
  transition: transform 0.2s;
}

.faq-item.open .faq-question::after {
  transform: rotate(45deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  padding: 0 0 20px;
  color: var(--text-light);
  font-size: 0.92rem;
  line-height: 1.75;
}

/* Responsive additions
   ============================================================ */
@media (max-width: 1024px) {
  .services-grid {
    grid-template-columns: 1fr 1fr;
  }

  .hub-grid {
    grid-template-columns: 1fr 1fr;
  }

  .tool-grid-cards {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .split {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .services-grid {
    grid-template-columns: 1fr;
  }

  .hub-grid {
    grid-template-columns: 1fr;
  }

  .tool-grid-cards {
    grid-template-columns: 1fr;
  }

  .steps li {
    padding-left: 54px;
  }

  .steps li::before {
    width: 40px;
    height: 40px;
    font-size: 1rem;
  }
}
