/* ───────── Guides (refonte du 18/11/2026) ─────────
   Les guides repris de l'ancien lestudiodetom.com faisaient « vieux blog » :
   vignettes Webflow, texte en pavés. Ici, l'esprit de l'accueil : héros crème
   à pois, titre surligné de travers, une illustration dessinée par guide,
   post-it « En 30 secondes », étapes numérotées, encadrés Astuce / Attention.

   Pages GÉNÉRÉES par modeles/build_guides.py : modifier le script, pas le HTML.

   Chaque guide a sa couleur (--acc), posée en style inline sur le héros et sur
   les cartes. Le texte posé dessus est toujours bleu marine (--navy) : ces
   couleurs sont claires, le contraste reste AA.

   Fichier séparé de pages.css, et appelé avec ?v= : pages.css est mis en cache
   une heure, et le HTML neuf s'est déjà affiché sans style avec l'ancien. */

/* ── Héros ── */
.ghero { background: var(--hero-bg); position: relative; overflow: hidden; padding-block: 28px 64px; }
.ghero::before { content: ""; position: absolute; inset: 0; background-image: radial-gradient(rgba(255,130,0,.22) 1.2px, transparent 1.3px); background-size: 22px 22px; mask-image: linear-gradient(90deg, transparent 25%, #000 70%); pointer-events: none; }
.ghero .wrap { position: relative; display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: 48px; align-items: center; }
.ghero .crumbs { font-family: var(--mono); font-size: 13px; color: var(--muted); margin: 0 0 18px; }
.ghero .crumbs a { text-decoration: none; } .ghero .crumbs a:hover { text-decoration: underline; }
.stickers { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.sticker { display: inline-block; font-family: var(--mono); font-size: 12px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; padding: 6px 12px; border-radius: 99px; background: var(--navy); color: #fff; }
.sticker.acc { background: var(--acc); color: var(--navy); transform: rotate(-3deg); box-shadow: 0 3px 0 rgba(27,45,90,.18); }
.ghero h1 { font-family: var(--display); font-stretch: 118%; font-weight: 900; font-size: clamp(36px, 5.6vw, 68px); line-height: 1.02; letter-spacing: -.035em; margin: 18px 0 0; }
.ghero h1 em { font-style: normal; display: inline-block; background: var(--signal); color: #fff; padding: 0 .14em .04em; transform: rotate(-1.5deg); border-radius: 6px; }
.ghero .lead { font-size: clamp(17px, 1.6vw, 19px); color: var(--muted); max-width: 46ch; margin: 22px 0 0; }
.ghero .meta { font-family: var(--mono); font-size: 12.5px; color: var(--muted); margin-top: 18px; }

/* ── Illustration du héros : une petite scène, un objet par guide ── */
.illu { position: relative; aspect-ratio: 1 / 1; max-width: 440px; width: 100%; justify-self: center; }
.illu .blob { position: absolute; inset: 8% 4% 4% 8%; background: var(--acc); border-radius: 42% 58% 55% 45% / 48% 42% 58% 52%; transform: rotate(-6deg); }
.illu .paper { position: absolute; background: #fff; color: var(--navy); border-radius: 14px; box-shadow: 0 24px 44px -22px rgba(27,45,90,.55), 0 0 0 1px rgba(27,45,90,.08); padding: 16px; }
.illu .tag { position: absolute; font-family: var(--display); font-stretch: 118%; font-weight: 900; font-size: clamp(15px, 1.7vw, 19px); background: var(--navy); color: #fff; padding: 6px 14px; border-radius: 10px; transform: rotate(-8deg); box-shadow: 0 10px 20px -10px rgba(27,45,90,.6); white-space: nowrap; }
.illu .tag.o { background: var(--signal); color: #fff; }
.illu .mono { font-family: var(--mono); font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: #4F5D7A; }
.illu .big { font-family: var(--display); font-stretch: 118%; font-weight: 900; line-height: 1; }
.illu .bars { display: block; width: 100%; height: 34px; margin-top: 8px; background: repeating-linear-gradient(90deg, var(--navy) 0 2px, transparent 2px 4px, var(--navy) 4px 7px, transparent 7px 9px, var(--navy) 9px 10px, transparent 10px 13px); }
.illu .chipset { display: flex; flex-wrap: wrap; gap: 6px; }
.illu .chipset span { font-family: var(--mono); font-size: 12px; font-weight: 600; padding: 4px 9px; border-radius: 99px; background: #F1F4F9; color: var(--navy); }
.illu .chipset span.on { background: var(--signal); color: #fff; transform: scale(1.12); }
/* Un léger flottement, coupé si « moins de mouvement ». */
.illu .flot { animation: flot 5s ease-in-out infinite; }
.illu .flot.b { animation-delay: -2.5s; }
@keyframes flot { 50% { translate: 0 -8px; } }

/* ── Post-it « En 30 secondes » (aussi ce que les moteurs IA citent) ── */
.tldr { position: relative; background: #FFE58A; color: var(--navy); border-radius: 4px 4px 18px 4px; padding: 26px 26px 22px; margin: 0 0 44px; transform: rotate(-.8deg); box-shadow: 0 18px 30px -22px rgba(27,45,90,.5); }
.tldr::before { content: ""; position: absolute; top: -12px; left: 50%; width: 110px; height: 26px; translate: -50% 0; rotate: 2deg; background: rgba(255,255,255,.55); border: 1px solid rgba(27,45,90,.08); }
.tldr b { display: block; font-family: var(--display); font-stretch: 118%; font-weight: 900; font-size: 22px; margin-bottom: 8px; }
.tldr ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.tldr li { padding-left: 30px; position: relative; font-weight: 500; }
.tldr li::before { content: "✓"; position: absolute; left: 0; top: 1px; width: 20px; height: 20px; border-radius: 50%; background: var(--navy); color: #FFE58A; font-size: 12px; font-weight: 800; display: grid; place-items: center; }

/* ── Corps de l'article ── */
.garticle { padding-block: 64px 24px; }
.garticle .inner { max-width: 740px; counter-reset: sec; overflow-wrap: anywhere; }
.garticle h2 { counter-increment: sec; font-family: var(--display); font-stretch: 112%; font-weight: 900; font-size: clamp(26px, 3.4vw, 36px); letter-spacing: -.025em; line-height: 1.1; margin: 56px 0 14px; scroll-margin-top: 96px; }
.garticle h2::before { content: counter(sec, decimal-leading-zero); display: block; font-family: var(--mono); font-size: 13px; font-weight: 600; letter-spacing: .08em; color: var(--signal-deep); margin-bottom: 6px; }
.garticle h2.nonum::before { content: none; }
.garticle h3 { font-family: var(--display); font-weight: 800; font-size: 20px; margin: 0 0 6px; }
.garticle p, .garticle ul, .garticle ol { margin: 0 0 14px; font-size: 17px; }
.garticle ul { padding-left: 22px; } .garticle li { margin-bottom: 6px; }
.garticle a { text-decoration-color: var(--signal); text-decoration-thickness: 2px; text-underline-offset: 3px; }
.garticle strong { color: var(--navy); }
.garticle .kbd { font-family: var(--mono); font-size: .88em; background: var(--surface); border: 1px solid var(--line); border-bottom-width: 3px; border-radius: 6px; padding: 1px 6px; white-space: nowrap; }

/* Étapes : gros numéros reliés par un pointillé. */
.garticle .gsteps { list-style: none; padding: 0 !important; margin: 18px 0 20px; counter-reset: st; display: grid; gap: 0; }
.gsteps li { counter-increment: st; position: relative; padding: 0 0 22px 58px; margin: 0; }
.gsteps li::before { content: counter(st); position: absolute; left: 0; top: -4px; width: 40px; height: 40px; border-radius: 50%; background: var(--signal); color: #fff; font-family: var(--display); font-weight: 900; font-size: 18px; display: grid; place-items: center; box-shadow: 0 4px 0 var(--signal-deep); }
.gsteps li::after { content: ""; position: absolute; left: 19px; top: 42px; bottom: 2px; border-left: 2px dashed var(--line); }
.gsteps li:last-child::after { display: none; }

/* Deux (ou trois) cartes côte à côte. */
.duo { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr)); gap: 16px; margin: 18px 0 20px; }
.duo > div { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 22px; }
.duo > div p:last-child { margin-bottom: 0; }
.duo .ico { width: 42px; height: 42px; border-radius: 12px; background: var(--acc, var(--tint)); display: grid; place-items: center; margin-bottom: 12px; }
.duo .ico svg { width: 24px; height: 24px; }

/* Grosses pastilles (montants, formats, codes…). */
.garticle .bigchips { display: flex; flex-wrap: wrap; gap: 10px; margin: 16px 0 18px; padding: 0 !important; list-style: none; }
.bigchips li { margin: 0; font-family: var(--display); font-stretch: 112%; font-weight: 900; font-size: 22px; padding: 8px 18px; border-radius: 14px; background: var(--surface); border: 2px solid var(--navy); box-shadow: 0 4px 0 var(--navy); }
.bigchips li:nth-child(odd) { transform: rotate(-2deg); } .bigchips li:nth-child(even) { transform: rotate(1.5deg); }

/* Événements (guide CRM) : pastilles moyennes, lisibles en liste. */
.garticle .evchips { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; padding: 0; margin: 8px 0 22px; }
.garticle .evchips li { margin: 0; font-size: 14px; font-weight: 600; padding: 6px 12px; border-radius: 99px; background: var(--surface); border: 2px solid var(--navy); }
.garticle h3 + .evchips { margin-top: 8px; }

/* Encadrés : astuce (vert) et attention (orange). */
.note { position: relative; border-radius: 16px; padding: 22px 22px 20px; margin: 26px 0; border: 2px solid; }
.note > b:first-child { position: absolute; top: -13px; left: 18px; font-family: var(--mono); font-size: 11.5px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; padding: 3px 10px; border-radius: 99px; transform: rotate(-3deg); }
.note p:last-child { margin-bottom: 0; }
.note.tip { background: #E8F7EF; border-color: #2E9E6A; } .note.tip > b:first-child { background: #2E9E6A; color: #fff; }
.note.warn { background: #FFF1E2; border-color: var(--signal); } .note.warn > b:first-child { background: var(--signal); color: #fff; }

/* FAQ : reprend .faq de pages.css, avec de l'air. */
.garticle .faq { margin: 18px 0 8px; }

/* Pour aller plus loin. */
.garticle .gmore { display: flex; flex-wrap: wrap; gap: 10px; margin: 40px 0 0; padding: 0 !important; list-style: none; }
.gmore li { margin: 0; }
.gmore a { display: inline-flex; align-items: center; gap: 8px; text-decoration: none; font-weight: 600; font-size: 15px; padding: 10px 16px; border-radius: 99px; background: var(--surface); border: 1px solid var(--line); }
.gmore a:hover { border-color: var(--signal); }
.gmore a::after { content: "→"; color: var(--signal-deep); }

/* ── Cartes de guides (index et « À lire ensuite ») ── */
.gcards { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap: 22px; }
.gcards li { margin: 0; }
.gcard { display: grid; grid-template-rows: auto 1fr; height: 100%; text-decoration: none; color: var(--ink); background: var(--surface); border: 2px solid var(--navy); border-radius: 22px; overflow: hidden; box-shadow: 0 6px 0 var(--navy); transition: transform .18s ease, box-shadow .18s ease; }
.gcard:hover { transform: translateY(-4px) rotate(-.6deg); box-shadow: 0 10px 0 var(--navy); }
.gcard .vis { background: var(--acc); aspect-ratio: 16 / 9; display: grid; place-items: center; position: relative; border-bottom: 2px solid var(--navy); overflow: hidden; }
.gcard .vis::before { content: ""; position: absolute; inset: 0; background-image: radial-gradient(rgba(27,45,90,.16) 1.2px, transparent 1.3px); background-size: 16px 16px; }
.gcard .vis svg { position: relative; width: 34%; height: auto; transition: transform .3s cubic-bezier(.3,1.6,.5,1); }
.gcard:hover .vis svg { transform: rotate(-8deg) scale(1.08); }
.gcard .vis .sticker { position: absolute; top: 12px; right: 12px; background: #fff; color: var(--navy); font-size: 11px; transform: rotate(4deg); }
.gcard .txt { padding: 18px 20px 22px; display: grid; gap: 8px; align-content: start; }
.gcard .txt b { font-family: var(--display); font-stretch: 112%; font-weight: 900; font-size: 21px; line-height: 1.15; letter-spacing: -.01em; }
.gcard .txt span { color: var(--muted); font-size: 15px; }

/* Ces listes ont leur propre marge : préfixées par .garticle, sinon la règle
   « .garticle ul » (plus précise) l'écrase. Les listes de cartes n'héritent pas du retrait des listes de l'article. */
.garticle .gcards { padding: 0; }

/* Index : rubriques en pastilles, liens d'ancre (aucun JS). */
.gtopics { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 26px; }
.gtopics a { text-decoration: none; font-weight: 600; font-size: 14px; padding: 8px 14px; border-radius: 99px; background: #fff; border: 2px solid var(--navy); box-shadow: 0 3px 0 var(--navy); }
.gtopics a:hover { background: var(--signal); color: #fff; }
.gindex { counter-reset: sec; }
.gindex h2 { font-family: var(--display); font-stretch: 112%; font-weight: 900; font-size: clamp(26px, 3.4vw, 36px); letter-spacing: -.025em; margin: 0 0 22px; scroll-margin-top: 96px; }
.gindex section + section { margin-top: 64px; }
.ghero .big-illu { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; max-width: 420px; justify-self: center; }
.ghero .big-illu span { aspect-ratio: 1; border-radius: 22px; background: var(--c); border: 2px solid var(--navy); box-shadow: 0 5px 0 var(--navy); display: grid; place-items: center; }
.ghero .big-illu span:nth-child(odd) { transform: rotate(-4deg); } .ghero .big-illu span:nth-child(even) { transform: rotate(3deg) translateY(10px); }
.ghero .big-illu svg { width: 48%; height: auto; }

@media (max-width: 860px) {
  .ghero .wrap { grid-template-columns: 1fr; gap: 28px; }
  .illu { max-width: 340px; }
  .ghero .big-illu { max-width: 320px; }
}
@media (max-width: 420px) { .tldr { transform: none; padding-inline: 20px; } }
@media (prefers-reduced-motion: reduce) {
  .illu .flot { animation: none; }
  .gcard, .gcard .vis svg { transition: none; } .gcard:hover { transform: none; } .gcard:hover .vis svg { transform: none; }
}
