*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  /* ── Palette « MarkdownViewer » : blanc / gris / bleu GitHub ── */
  --white: #ffffff;
  --ivory: #ffffff;            /* base page (ex-papier chaud) → blanc */
  --off-white: #f6f8fa;        /* surface douce (sections alternées) */
  --light-gray: #e4e8ee;       /* filet (hairline) */
  --hairline-strong: #d0d7de;  /* filet appuyé */
  --mid-gray: #5d6772;         /* texte secondaire */
  --faint: #6b7280;            /* texte ténu (contraste AA ≥ 4.5:1 sur blanc) */
  --dark: #1f2328;             /* encre GitHub */
  --ink-soft: #3a3f45;         /* encre adoucie (hover) */
  --accent: #0969da;           /* bleu GitHub — accent principal */
  --accent-hover: #0a4fa8;
  --accent-2: #218bff;
  --accent-deep: #0a4fa8;
  --accent-soft: #ddf4ff;      /* bleu très clair (fonds d'icônes/pills) */
  --gold: #0969da;             /* (ex-champagne) repointé sur l'accent bleu */
  --gold-soft: #218bff;
  --grad: linear-gradient(135deg, #0969da 0%, #218bff 100%);
  --glow: 0 8px 26px rgba(9,105,218,0.28);
  --glow-strong: 0 12px 34px rgba(9,105,218,0.38);
  --font: -apple-system, system-ui, "Segoe UI", Roboto, Helvetica, Arial, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", sans-serif;
  --font-serif: var(--font);   /* plus de serif — tout en sans système */
  --mono: ui-monospace, SFMono-Regular, Menlo, "Cascadia Code", "Roboto Mono", monospace;
}

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

.skip-link {
  position: absolute;
  top: -100%;
  left: 1rem;
  z-index: 1000;
  background: var(--accent);
  color: #fff;
  padding: 0.6rem 1rem;
  border-radius: 6px;
  font-size: 0.9rem;
  text-decoration: none;
  transition: top .2s ease;
}
.skip-link:focus { top: 1rem; }

body {
  font-family: var(--font);
  background: var(--white);
  color: var(--dark);
  -webkit-font-smoothing: antialiased;
}

/* Util : mot-clé d'accent — même graisse, couleur bleue (cf. « instantly on macOS ») */
.grad-text {
  font-style: normal;
  font-weight: inherit;
  color: var(--accent);
}

/* ── NAV ─────────────────────────────────────────── */
body > nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 2rem;
  height: 3.5rem;
  background: transparent;
  border-bottom: 1px solid transparent;
  transition: background 0.3s ease, border-color 0.3s ease;
}

body > nav.nav-scrolled {
  background: rgba(255,255,255,0.85);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--light-gray);
}

.nav-logo {
  font-family: var(--font);
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--dark);
  text-decoration: none;
}

.nav-links {
  display: flex;
  gap: 1.9rem;
  list-style: none;
}

.nav-links a {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--mid-gray);
  text-decoration: none;
  transition: color .2s;
}

.nav-links a:hover { color: var(--dark); }

.nav-links a.nav-active { color: var(--dark); }

.nav-links a.nav-active::after {
  content: '';
  display: block;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--accent);
  margin: 3px auto 0;
}

.lang-toggle {
  display: flex;
  gap: 0.4rem;
  font-family: var(--mono);
  font-size: 0.74rem;
}

.lang-toggle button {
  position: relative;
  background: none;
  border: none;
  cursor: pointer;
  font-family: var(--mono);
  font-size: 0.74rem;
  color: var(--faint);
  min-height: 28px;
  padding: 0.2rem 0.5rem;
  border-radius: 6px;
  transition: all .2s;
}

/* Zone tactile étendue à 44px sans grossir la pilule (WCAG 2.5.8) */
.lang-toggle button::after {
  content: "";
  position: absolute;
  left: 0; right: 0;
  top: -8px; bottom: -8px;
}

.lang-toggle button.active {
  color: var(--accent);
  background: var(--accent-soft);
  font-weight: 600;
}

.nav-hamburger {
  display: none;
  align-items: center;
  justify-content: center;
  background: none;
  border: none;
  cursor: pointer;
  font-size: 1.3rem;
  color: var(--dark);
  min-width: 44px;
  min-height: 44px;
  padding: 0.25rem 0.4rem;
  line-height: 1;
}

.nav-mobile-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(13,17,23,0.96);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  z-index: 101;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2.5rem;
}

.nav-mobile-overlay.open { display: flex; }

.nav-mobile-close {
  position: absolute;
  top: 1rem;
  right: 1.5rem;
  background: none;
  border: none;
  color: rgba(255,255,255,0.5);
  font-size: 1.6rem;
  cursor: pointer;
  line-height: 1;
  padding: 0.4rem;
}

.nav-mobile-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
}

.nav-mobile-links a {
  font-size: 1.7rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: rgba(255,255,255,0.9);
  text-decoration: none;
  transition: color .15s;
}

.nav-mobile-links a:hover { color: #fff; }

.nav-mobile-lang {
  display: flex;
  gap: 0.75rem;
}

.nav-mobile-lang button {
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.18);
  color: rgba(255,255,255,0.65);
  padding: 0.4rem 1.1rem;
  border-radius: 8px;
  cursor: pointer;
  font-family: var(--mono);
  font-size: 0.82rem;
  transition: all .2s;
}

.nav-mobile-lang button:hover,
.nav-mobile-lang button.active {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

@media (max-width: 640px) {
  .nav-hamburger { display: flex; }
}

/* ── HERO ────────────────────────────────────────── */
.hero {
  position: relative;
  min-height: 84svh;
  display: flex;
  align-items: center;
  padding: 6rem 1.5rem 3rem;
  background:
    radial-gradient(680px 360px at 84% 6%, rgba(9,105,218,0.10), transparent 60%),
    linear-gradient(180deg, #f6f9fc 0%, var(--white) 46%);
}

.hero-inner {
  max-width: 1080px;
  width: 100%;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.08fr 0.92fr;
  gap: 3.5rem;
  align-items: center;
}

.hero-text { text-align: left; }

.hero-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--white);
  border: 1px solid var(--light-gray);
  color: var(--mid-gray);
  font-family: var(--mono);
  font-size: 0.78rem;
  padding: 0.4rem 0.9rem;
  border-radius: 980px;
  margin-bottom: 1.4rem;
  box-shadow: 0 1px 3px rgba(31,35,40,0.06);
  opacity: 0;
  animation: fadeUp .8s .05s ease forwards;
}
.hero-pill b { color: var(--dark); font-weight: 600; }
.hero-pill .star { color: var(--accent); }

.hero-avatar {       /* visible uniquement en mobile, au-dessus du texte */
  display: none;
  width: 104px;
  height: 104px;
  border-radius: 50%;
  object-fit: cover;
  object-position: center top;
  margin: 0 auto 1.5rem;
  box-shadow: 0 8px 32px rgba(31,35,40,0.16);
}

.hero h1 {
  font-family: var(--font);
  font-size: clamp(2.8rem, 7vw, 5rem);
  font-weight: 800;
  letter-spacing: -0.035em;
  line-height: 1.0;
  color: var(--dark);
  margin-bottom: 1.5rem;
  opacity: 0;
  animation: fadeUp .8s .35s ease forwards;
}

.hero-sub {
  font-size: clamp(1.05rem, 2.2vw, 1.25rem);
  font-weight: 400;
  color: var(--mid-gray);
  max-width: 32em;
  line-height: 1.6;
  margin-bottom: 2.2rem;
  opacity: 0;
  animation: fadeUp .8s .5s ease forwards;
}

.hero-sub .fr, .hero-sub .en, .hero-sub .zh { display: block; }

.hero-meta {
  margin-top: 1.4rem;
  font-size: 0.82rem;
  color: var(--faint);
  opacity: 0;
  animation: fadeUp .8s .8s ease forwards;
}
.hero-meta b { color: var(--mid-gray); font-weight: 600; }

/* Carte portrait signature (colonne droite) */
.hero-visual {
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  animation: fadeUp .9s .4s ease forwards;
}

.hero-card {
  position: relative;
  width: min(340px, 100%);
  border-radius: 16px;
  padding: 12px 12px 4px;
  background: var(--white);
  border: 1px solid var(--light-gray);
  box-shadow:
    0 1px 0 rgba(31,35,40,0.02),
    0 18px 48px rgba(31,35,40,0.12),
    0 4px 12px rgba(31,35,40,0.06);
}
.hero-card::before {     /* halo bleu diffus, sobre */
  content: "";
  position: absolute;
  inset: -34px -30px -14px;
  z-index: -1;
  border-radius: 30px;
  background: radial-gradient(58% 58% at 70% 18%, rgba(9,105,218,0.16), transparent 72%);
  filter: blur(12px);
}
.hero-card-photo {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 10px;
  object-fit: cover;
  aspect-ratio: 1 / 1;
  object-position: center top;
}
.hero-card-cap {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  padding: 0.95rem 0.55rem 0.7rem;
  text-align: left;
}
.hero-card-cap b {
  font-family: var(--font);
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--dark);
}
.hero-card-cap span {
  font-family: var(--mono);
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--accent);
}

@media (max-width: 820px) {
  .hero { min-height: auto; padding: 6.5rem 1.5rem 4rem; text-align: center; }
  .hero-inner { grid-template-columns: 1fr; gap: 2rem; }
  .hero-text { text-align: center; }
  .hero-pill { margin-left: auto; margin-right: auto; }
  .hero-sub { margin-left: auto; margin-right: auto; }
  .cta-group { justify-content: center; }
  .hero-visual { order: -1; }
  .hero-avatar { display: block; }
  .hero-card { display: none; }   /* en mobile on garde juste l'avatar rond */
}

.cta-group {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  justify-content: center;
  opacity: 0;
  animation: fadeUp .8s .65s ease forwards;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  background: var(--accent);
  color: #fff;
  padding: 0.8rem 1.7rem;
  border-radius: 10px;
  font-size: 0.92rem;
  font-weight: 600;
  letter-spacing: 0.005em;
  text-decoration: none;
  box-shadow: var(--glow);
  transition: box-shadow .25s, transform .2s, background .25s;
}

.btn-primary:hover {
  background: var(--accent-hover);
  box-shadow: var(--glow-strong);
  transform: translateY(-2px);
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  background: var(--white);
  color: var(--dark);
  padding: 0.8rem 1.7rem;
  border-radius: 10px;
  font-size: 0.92rem;
  font-weight: 600;
  letter-spacing: 0.005em;
  text-decoration: none;
  border: 1px solid var(--hairline-strong);
  transition: all .25s;
}

.btn-secondary:hover {
  border-color: var(--accent);
  color: var(--accent);
  transform: translateY(-2px);
}

.scroll-hint {
  position: absolute;
  bottom: 2.5rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--mono);
  font-size: 0.7rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--faint);
  animation: fadeIn 1s 1.4s ease forwards;
  opacity: 0;
}

.scroll-hint svg {
  animation: bounce 2s infinite;
}

/* ── BOOKS SECTION ───────────────────────────────── */
.section-books {
  background: var(--off-white);
  padding: 7rem 1.5rem;
  border-top: 1px solid var(--light-gray);
}

.section-header {
  text-align: center;
  margin-bottom: 4rem;
}

.section-eyebrow {
  display: inline-block;
  font-family: var(--mono);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1rem;
}

.section-title {
  font-family: var(--font);
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.08;
  color: var(--dark);
}

.section-title .fr, .section-title .en, .section-title .zh { display: block; }

.books-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 480px), 1fr));
  gap: 1.5rem;
  max-width: 1100px;
  margin: 0 auto;
}

.book-card {
  background: var(--white);
  border: 1px solid var(--light-gray);
  border-radius: 14px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform .3s ease, box-shadow .3s ease, border-color .3s ease;
  box-shadow: 0 1px 3px rgba(31,35,40,0.04);
  cursor: pointer;
}

.book-card:hover {
  transform: translateY(-4px);
  border-color: var(--hairline-strong);
  box-shadow: 0 16px 40px rgba(31,35,40,0.12);
}

.book-cover {
  width: 100%;
  background: #f0f3f6;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 3rem 2.5rem;
}

.book-cover-ia {
  background: linear-gradient(135deg, #0b1f3a 0%, #0969da 100%);
}

.book-cover-bmad {
  background: linear-gradient(135deg, #0d1117 0%, #1e3a5f 100%);
}

.book-cover img {
  height: 260px;
  width: auto;
  display: block;
  border-radius: 4px;
  box-shadow:
    0 2px 4px rgba(0,0,0,0.08),
    0 8px 24px rgba(0,0,0,0.13),
    0 20px 48px rgba(0,0,0,0.08);
  transition: transform .35s ease, box-shadow .35s ease;
}

.book-card:hover .book-cover img {
  transform: translateY(-4px) scale(1.02);
  box-shadow:
    0 4px 8px rgba(0,0,0,0.1),
    0 16px 40px rgba(0,0,0,0.18),
    0 32px 64px rgba(0,0,0,0.1);
}

.book-body {
  padding: 2rem;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.book-tag {
  display: inline-block;
  align-self: flex-start;
  background: var(--accent-soft);
  color: var(--accent);
  font-family: var(--mono);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  padding: 0.25rem 0.6rem;
  border-radius: 980px;
  margin-bottom: 1rem;
}

.book-title {
  font-family: var(--font);
  font-size: 1.45rem;
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.15;
  color: var(--dark);
  margin-bottom: 0.75rem;
}

.book-desc {
  font-size: 0.95rem;
  color: var(--mid-gray);
  line-height: 1.65;
  flex: 1;
  margin-bottom: 1.5rem;
}

.book-desc .fr, .book-desc .en, .book-desc .zh { display: block; }

.book-cta {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--accent);
  font-size: 0.88rem;
  font-weight: 600;
  letter-spacing: 0.005em;
  text-decoration: none;
  transition: gap .2s;
}

.book-cta:hover { gap: 0.7rem; }

.book-cta svg {
  transition: transform .2s;
}

.book-cta:hover svg { transform: translateX(3px); }

/* ── TOOLS SECTION ───────────────────────────────── */
.section-tools {
  background: var(--white);
  padding: 7rem 1.5rem;
}

/* Disclosure des outils : 4 phares visibles, le reste plié */
.tools-more {
  display: flex;
  justify-content: center;
  margin-top: 2.5rem;
}
#tools-toggle svg { transition: transform .25s ease; }
#tools-toggle[aria-expanded="true"] svg { transform: rotate(180deg); }
.tools-all { margin-top: 1.5rem; }
.tools-all[hidden] { display: none; }

.tools-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
  max-width: 1080px;
  margin: 0 auto;
}

@media (max-width: 760px) {
  .tools-grid { grid-template-columns: 1fr; }
}

.tools-category {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 0.55rem;
  margin: 3rem 0 -0.25rem;
  font-family: var(--mono);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--accent);
}

.tools-category:first-child {
  margin-top: 0;
}

.tools-category-icon {
  font-size: 1rem;
  line-height: 1;
}

.tool-card {
  background: var(--white);
  border: 1px solid var(--light-gray);
  border-radius: 14px;
  padding: 2.4rem;
  display: flex;
  flex-direction: column;
  transition: transform .3s ease, box-shadow .3s ease, border-color .3s ease;
  box-shadow: 0 1px 3px rgba(31,35,40,0.03);
  cursor: pointer;
}

.tool-card:hover {
  transform: translateY(-4px);
  border-color: var(--hairline-strong);
  box-shadow: 0 16px 40px rgba(31,35,40,0.10);
}

.tool-icon {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  background: var(--accent-soft);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.5rem;
  border: 1px solid rgba(9,105,218,0.18);
  transition: transform .35s ease;
}
.tool-icon svg { width: 32px; height: 32px; }

.tool-card:hover .tool-icon {
  transform: scale(1.05) rotate(-2deg);
}

.tool-tag {
  display: inline-block;
  align-self: flex-start;
  background: var(--accent-soft);
  color: var(--accent);
  font-family: var(--mono);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  padding: 0.25rem 0.6rem;
  border-radius: 980px;
  margin-bottom: 1rem;
}

.tool-tag-network {
  background: var(--accent-soft);
  color: var(--accent);
}

.tool-title {
  font-family: var(--font);
  font-size: 1.55rem;
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.15;
  color: var(--dark);
  margin-bottom: 0.7rem;
}

.tool-desc {
  font-size: 1rem;
  color: var(--mid-gray);
  line-height: 1.65;
  flex: 1;
  margin-bottom: 1.75rem;
}

.tool-desc .fr, .tool-desc .en, .tool-desc .zh { display: block; }

.tool-cta {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--accent);
  font-size: 0.88rem;
  font-weight: 600;
  letter-spacing: 0.005em;
  text-decoration: none;
  transition: gap .2s;
  align-self: flex-start;
}

.tool-cta:hover { gap: 0.7rem; }
.tool-cta:hover svg { transform: translateX(3px); }
.tool-cta svg { transition: transform .2s; }

/* ── ABOUT SECTION ───────────────────────────────── */
.section-about {
  background: linear-gradient(160deg, #161b22 0%, #0d1117 100%);
  color: var(--white);
  padding: 8rem 1.5rem;
}
.section-about .section-title,
.about-name { color: #fff; }

.about-inner {
  max-width: 760px;
  margin: 0 auto;
  text-align: center;
}

.about-photo {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  object-fit: cover;
  object-position: center top;
  margin: 0 auto 2rem;
  display: block;
  border: 2px solid rgba(255,255,255,0.15);
  box-shadow: 0 4px 20px rgba(0,0,0,0.4);
}

.about-eyebrow {
  font-family: var(--mono);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  color: #79c0ff;
  margin-bottom: 1.5rem;
}

.about-name {
  font-family: var(--font);
  font-size: clamp(2.2rem, 5vw, 3.2rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  margin-bottom: 1.75rem;
  line-height: 1.1;
}

.about-text {
  font-size: 1.12rem;
  line-height: 1.75;
  color: rgba(255,255,255,0.72);
  margin-bottom: 3rem;
}

.about-text .fr, .about-text .en, .about-text .zh { display: block; }

.social-group {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

.social-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  background: rgba(255,255,255,0.1);
  color: var(--white);
  padding: 0.75rem 1.6rem;
  border-radius: 10px;
  font-size: 0.92rem;
  font-weight: 600;
  text-decoration: none;
  border: 1px solid rgba(255,255,255,0.15);
  transition: all .25s;
}

.social-btn:hover {
  background: rgba(255,255,255,0.18);
  border-color: rgba(255,255,255,0.3);
  transform: translateY(-2px);
}

/* ── CONTACT SECTION ────────────────────────────── */
.section-contact {
  background: var(--off-white);
  padding: 7rem 1.5rem;
  border-top: 1px solid var(--light-gray);
}

.contact-inner {
  max-width: 560px;
  margin: 0 auto;
  text-align: center;
}

.contact-sub {
  font-size: 1.08rem;
  color: var(--mid-gray);
  line-height: 1.65;
  margin-bottom: 2.5rem;
  max-width: 480px;
  margin-left: auto;
  margin-right: auto;
}

/* ── CONTACT FORM ────────────────────────────────── */
#contact-form {
  width: 100%;
  max-width: 560px;
  margin: 0 auto 2rem;
  text-align: left;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  margin-bottom: 1rem;
}

.form-group label {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--dark);
  letter-spacing: 0.01em;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 0.8rem 1rem;
  border: 1px solid var(--hairline-strong);
  border-radius: 8px;
  font-family: var(--font);
  font-size: 0.95rem;
  color: var(--dark);
  background: var(--white);
  transition: border-color .2s, box-shadow .2s;
  resize: none;
  outline: none;
  box-sizing: border-box;
}

.form-group input:focus,
.form-group textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(9,105,218,0.18);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: var(--faint);
}

#form-submit {
  width: 100%;
  justify-content: center;
  margin-bottom: 1.5rem;
}

#form-submit:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

#form-status {
  font-size: 0.95rem;
  line-height: 1.5;
  margin-bottom: 1rem;
  min-height: 1.5rem;
}

#form-status.success { color: #1a7f37; }
#form-status.error   { color: #cf222e; }

/* Honeypot anti-spam (Web3Forms botcheck) */
.hp {
  position: absolute;
  width: 1px; height: 1px;
  opacity: 0;
  pointer-events: none;
}

/* Alternative mailto — le contact survit sans JS et sans Web3Forms */
.contact-alt {
  font-size: 0.95rem;
  color: var(--mid-gray);
  margin-bottom: 1.6rem;
}
.contact-alt a {
  color: var(--accent);
  font-weight: 600;
  text-decoration: none;
}
.contact-alt a:hover { text-decoration: underline; text-underline-offset: 3px; }

.contact-linkedin {
  display: flex;
  justify-content: center;
}

@media (max-width: 640px) {
  .form-row { grid-template-columns: 1fr; }
}

/* ── FOOTER ──────────────────────────────────────── */
footer {
  background: var(--white);
  padding: 3rem 1.5rem;
  text-align: center;
  border-top: 1px solid var(--light-gray);
}

.footer-name {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 0.5rem;
}

.footer-copy {
  font-family: var(--mono);
  font-size: 0.78rem;
  color: var(--faint);
}

.footer-links {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
  margin: 0.6rem 0;
}

.footer-links a {
  font-size: 0.8rem;
  color: var(--mid-gray);
  text-decoration: none;
  transition: color .2s;
}

.footer-links a:hover { color: var(--accent); }

.footer-sep {
  color: var(--light-gray);
  font-size: 0.8rem;
}

/* ── STATS STRIP (KPI façon MarkdownViewer) ──────── */
.stats-strip {
  background: var(--white);
  padding: 4.5rem 1.5rem;
  border-top: 1px solid var(--light-gray);
  border-bottom: 1px solid var(--light-gray);
}
.stats-inner {
  max-width: 1000px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
}
.stat-item {
  text-align: left;
  padding: 1.4rem 1.5rem;
  border: 1px solid var(--light-gray);
  border-radius: 12px;
  background: var(--off-white);
}
.stat-k {
  font-family: var(--font);
  font-size: clamp(2.1rem, 4.2vw, 2.9rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1;
  color: var(--accent);
}
.stat-v {
  margin-top: 0.6rem;
  font-family: var(--mono);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  text-transform: uppercase;
  color: var(--mid-gray);
}
.stat-v .fr, .stat-v .en, .stat-v .zh { display: block; }

@media (max-width: 640px) {
  .stats-inner { grid-template-columns: 1fr 1fr; gap: 1rem; }
}

/* ── EXPERTISE SECTION ───────────────────────────── */
.section-expertise {
  background: var(--off-white);
  padding: 7rem 1.5rem;
  border-top: 1px solid var(--light-gray);
}

.expertise-grid {
  max-width: 1080px;
  margin: 0 auto;
}

/* ── STEPS SECTION (collaboration 1·2·3) ─────────── */
.section-steps {
  background: var(--white);
  padding: 7rem 1.5rem;
  border-top: 1px solid var(--light-gray);
}

.steps-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  max-width: 1080px;
  margin: 0 auto;
}

@media (max-width: 760px) {
  .steps-grid { grid-template-columns: 1fr; }
}

.step-card {
  position: relative;
  background: var(--white);
  border: 1px solid var(--light-gray);
  border-radius: 14px;
  padding: 2.2rem 2rem;
  transition: border-color .25s ease, box-shadow .25s ease, transform .25s ease;
}

.step-card:hover {
  transform: translateY(-4px);
  border-color: var(--hairline-strong);
  box-shadow: 0 16px 40px rgba(31,35,40,0.10);
}

.step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: var(--accent);
  color: #fff;
  font-family: var(--mono);
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 1.2rem;
  box-shadow: var(--glow);
}

.step-card h3 {
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--dark);
  margin-bottom: 0.6rem;
}

.step-card p {
  font-size: 0.95rem;
  color: var(--mid-gray);
  line-height: 1.65;
}

.step-card h3 .fr, .step-card h3 .en, .step-card h3 .zh,
.step-card p .fr, .step-card p .en, .step-card p .zh { display: block; }

/* ── CTA BAND (clôture) ──────────────────────────── */
.cta-band {
  background:
    radial-gradient(680px 320px at 50% 0%, rgba(9,105,218,0.12), transparent 65%),
    var(--off-white);
  padding: 7rem 1.5rem;
  border-top: 1px solid var(--light-gray);
}

.cta-band-inner {
  max-width: 640px;
  margin: 0 auto;
  text-align: center;
}

.cta-band .section-eyebrow { justify-content: center; }

.cta-band-title {
  font-family: var(--font);
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.08;
  color: var(--dark);
  margin-bottom: 1rem;
}

.cta-band-title .fr, .cta-band-title .en, .cta-band-title .zh { display: block; }

.cta-band-sub {
  font-size: 1.08rem;
  color: var(--mid-gray);
  line-height: 1.65;
  max-width: 30em;
  margin: 0 auto 2rem;
}

.cta-band .cta-group {
  opacity: 1;
  animation: none;
}

/* ── ANIMATIONS ──────────────────────────────────── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

@keyframes bounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(5px); }
}

/* ── INTERSECTION OBSERVER ANIMATIONS ────────────── */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .7s ease, transform .7s ease;
}

.reveal.reveal-left  { transform: translateX(-24px); }
.reveal.reveal-right { transform: translateX(24px); }

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

.reveal.reveal-left.visible,
.reveal.reveal-right.visible {
  transform: translateX(0);
}

.reveal-delay-1 { transition-delay: .1s; }
.reveal-delay-2 { transition-delay: .2s; }
.reveal-delay-3 { transition-delay: .35s; }
.reveal-delay-4 { transition-delay: .5s; }

/* ── RESPONSIVE ──────────────────────────────────── */
@media (max-width: 640px) {
  .nav-links { display: none; }
  .cta-group { flex-direction: column; align-items: center; }
  .scroll-hint { display: none; }
  .book-cover { padding: 2rem 1.5rem; }
  .tool-card  { padding: 1.5rem; }
}

/* ── REDUCED MOTION ─────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  .hero-avatar, .hero h1, .hero-sub, .cta-group, .scroll-hint {
    animation: none !important;
    opacity: 1 !important;
  }
  .scroll-hint svg { animation: none; }
  .reveal {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
}

/* ── LANG SWITCH ─────────────────────────────────── */
/* Système N langues : on masque toute langue non active.
   Défaut = FR (body sans classe de langue ou .lang-fr). */
body.lang-en .fr, body.lang-zh .fr { display: none !important; }
body:not(.lang-en) .en { display: none !important; }
body:not(.lang-zh) .zh { display: none !important; }

/* ══════════════════════════════════════════════════ */
/* ── LANDING PAGES (pages par sujet) ─────────────── */
/* ══════════════════════════════════════════════════ */

/* Layout général landing */
.landing-main { padding-top: 3.5rem; }

/* Hero de landing */
.landing-hero {
  padding: 4.5rem 1.5rem 3.5rem;
  background: linear-gradient(180deg, #f6f9fc 0%, var(--white) 60%);
}

.landing-hero-inner {
  max-width: 980px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 3rem;
  align-items: center;
}

.landing-hero-inner.no-visual { grid-template-columns: 1fr; max-width: 760px; text-align: center; }
.landing-hero-inner.no-visual .breadcrumb,
.landing-hero-inner.no-visual .cta-group { justify-content: center; }

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  align-items: center;
  font-family: var(--mono);
  font-size: 0.78rem;
  color: var(--mid-gray);
  margin-bottom: 1.5rem;
}

.breadcrumb a { color: var(--mid-gray); text-decoration: none; transition: color .2s; }
.breadcrumb a:hover { color: var(--accent); }
.breadcrumb .sep { opacity: 0.5; }
.breadcrumb .current { color: var(--dark); font-weight: 500; }

.landing-tag {
  display: inline-block;
  align-self: flex-start;
  background: var(--accent-soft);
  color: var(--accent);
  font-family: var(--mono);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  padding: 0.25rem 0.65rem;
  border-radius: 980px;
  margin-bottom: 1.1rem;
}

.landing-hero h1 {
  font-family: var(--font);
  font-size: clamp(2.4rem, 6vw, 3.7rem);
  font-weight: 800;
  letter-spacing: -0.035em;
  line-height: 1.04;
  color: var(--dark);
  margin-bottom: 1.25rem;
}

.landing-lead {
  font-size: clamp(1.05rem, 2vw, 1.2rem);
  color: var(--mid-gray);
  line-height: 1.65;
  margin-bottom: 2rem;
  max-width: 60ch;
}

.landing-lead .fr, .landing-lead .en, .landing-lead .zh { display: block; }

/* Visuel hero (icône outil ou couverture livre) */
.landing-visual {
  display: flex;
  align-items: center;
  justify-content: center;
}

.landing-visual-icon {
  width: 140px;
  height: 140px;
  border-radius: 28px;
  background: var(--accent-soft);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(9,105,218,0.18);
  box-shadow: 0 16px 48px rgba(9,105,218,0.16);
}

.landing-visual-icon svg { width: 76px; height: 76px; }

.landing-visual-cover {
  border-radius: 8px;
  box-shadow: 0 10px 24px rgba(0,0,0,0.14), 0 30px 60px rgba(0,0,0,0.12);
  max-height: 360px;
  width: auto;
}

/* Sections de contenu landing */
.landing-section { padding: 5rem 1.5rem; }
.landing-section.alt { background: var(--off-white); }

.landing-section-inner { max-width: 980px; margin: 0 auto; }

.landing-h2 {
  font-family: var(--font);
  font-size: clamp(1.7rem, 3.5vw, 2.3rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.12;
  color: var(--dark);
  margin-bottom: 2.5rem;
  text-align: center;
}

/* Grille de fonctionnalités */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
  gap: 1.25rem;
}

.feature-card {
  background: var(--white);
  border: 1px solid var(--light-gray);
  border-radius: 12px;
  padding: 1.75rem;
  transition: border-color .25s ease, box-shadow .25s ease;
}

.feature-card:hover {
  border-color: var(--hairline-strong);
  box-shadow: 0 8px 24px rgba(31,35,40,0.07);
}

.landing-section.alt .feature-card { background: var(--white); }

.feature-icon {
  width: 44px;
  height: 44px;
  border-radius: 11px;
  background: var(--accent-soft);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
}

.feature-card h3 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 0.5rem;
  letter-spacing: -0.02em;
}

.feature-card p {
  font-size: 0.92rem;
  color: var(--mid-gray);
  line-height: 1.6;
}

.feature-card p .fr, .feature-card p .en, .feature-card p .zh { display: block; }

/* Badges (plateforme / techno / infos livre) */
.badge-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  justify-content: center;
  margin-top: 1rem;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: var(--white);
  border: 1px solid var(--light-gray);
  color: var(--dark);
  font-family: var(--mono);
  font-size: 0.8rem;
  font-weight: 500;
  padding: 0.5rem 1rem;
  border-radius: 980px;
}

/* Bloc CTA central */
.landing-cta-block {
  text-align: center;
  max-width: 620px;
  margin: 0 auto;
}

.landing-cta-block p {
  font-size: 1.1rem;
  color: var(--mid-gray);
  line-height: 1.65;
  margin-bottom: 2rem;
}

.landing-cta-block > p .fr, .landing-cta-block > p .en, .landing-cta-block > p .zh { display: block; }

/* Cross-linking « Autres … » */
.related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr));
  gap: 1rem;
}

.related-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  background: var(--white);
  border: 1px solid var(--light-gray);
  border-radius: 12px;
  padding: 1.1rem 1.25rem;
  text-decoration: none;
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}

.related-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 28px rgba(31,35,40,0.08);
  border-color: var(--hairline-strong);
}

.related-icon {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--accent-soft);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
}

.related-icon svg { width: 22px; height: 22px; }

.related-card .related-name {
  font-size: 0.98rem;
  font-weight: 700;
  color: var(--dark);
  letter-spacing: -0.02em;
}

.related-card .related-kind {
  font-family: var(--mono);
  font-size: 0.76rem;
  color: var(--mid-gray);
}

@media (max-width: 760px) {
  .landing-hero-inner { grid-template-columns: 1fr; text-align: center; }
  .landing-hero-inner .breadcrumb,
  .landing-hero-inner .cta-group,
  .landing-tag { justify-content: center; align-self: center; }
  .landing-visual { order: -1; margin-bottom: 1rem; }
  .landing-lead { margin-left: auto; margin-right: auto; }
}

