/* =============================================================
   ARTE AZZURRA — Rubrique Guides (articles longs)
   Chargé uniquement par GuideLayout, après style.css.
   ============================================================= */

.guide-head { max-width: 760px; margin: 0 auto; padding-top: clamp(1rem, 3vw, 2rem); }
.guide-head h1 {
  font: 600 clamp(1.9rem, 4.5vw, 2.8rem)/1.15 var(--font-display);
  color: var(--marine-deep, #003d6b); text-wrap: balance; margin: 0.5rem 0 1rem;
}
.guide-head__lede { font-size: 1.08rem; line-height: 1.6; color: var(--marine, #00487c); max-width: 62ch; }
.guide-head__meta {
  display: flex; flex-wrap: wrap; gap: 0.5rem 1.4rem; align-items: center;
  margin-top: 1.2rem; padding-top: 1rem; border-top: 1px solid rgba(0, 72, 124, 0.14);
  font: 500 0.84rem/1.4 "Jost", system-ui, sans-serif; color: var(--marine, #00487c);
}
.guide-head__meta b { font-weight: 600; color: var(--marine-deep, #003d6b); }
.guide-head__meta span { opacity: 0.75; }

/* --- Corps de l'article --- */
.guide-prose { max-width: 760px; margin: 0 auto; }
.guide-prose > * { max-width: 68ch; }
.guide-prose h2 {
  font: 600 clamp(1.4rem, 3vw, 1.75rem)/1.25 var(--font-display);
  color: var(--marine-deep, #003d6b); margin: 2.4rem 0 0.8rem; text-wrap: balance;
}
.guide-prose h3 {
  font: 600 1.08rem/1.35 "Jost", system-ui, sans-serif;
  color: var(--marine-deep, #003d6b); margin: 1.7rem 0 0.5rem;
}
.guide-prose p { line-height: 1.7; margin: 0 0 1rem; }
.guide-prose ul, .guide-prose ol { line-height: 1.65; padding-left: 1.3rem; margin: 0 0 1.1rem; }
.guide-prose li { margin-bottom: 0.45rem; }
.guide-prose li::marker { color: var(--electric, #2e7cf6); font-weight: 600; }
.guide-prose strong { color: var(--marine-deep, #003d6b); }
.guide-prose a { color: var(--electric, #2e7cf6); }

/* Encadré définition / à retenir */
.guide-note {
  background: #fff; border: 1px solid rgba(0, 72, 124, 0.12);
  border-left: 4px solid var(--electric, #2e7cf6);
  border-radius: 12px; padding: 1rem 1.2rem; margin: 1.4rem 0;
  font-size: 0.95rem;
}
.guide-note b { color: var(--marine-deep, #003d6b); }

/* Tableau lexique */
.guide-table-wrap { overflow-x: auto; border: 1px solid rgba(0, 72, 124, 0.14); border-radius: 14px; background: #fff; margin: 1.4rem 0; }
.guide-table { border-collapse: collapse; width: 100%; min-width: 520px; font-size: 0.92rem; }
.guide-table th {
  text-align: left; font: 600 0.7rem/1.3 "Jost", sans-serif; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--marine, #00487c); opacity: 0.75; padding: 0.75rem 1rem; border-bottom: 1px solid rgba(0, 72, 124, 0.14);
}
.guide-table td { padding: 0.7rem 1rem; border-bottom: 1px solid rgba(0, 72, 124, 0.1); vertical-align: top; }
.guide-table tr:last-child td { border-bottom: none; }
.guide-table td:first-child { font-weight: 600; color: var(--marine-deep, #003d6b); white-space: nowrap; }

/* CTA doux en fil d'article */
.guide-cta {
  background: linear-gradient(150deg, var(--marine, #00487c), var(--marine-deep, #003d6b));
  border-radius: 18px; padding: clamp(1.4rem, 3vw, 2rem); margin: 2.2rem 0;
  color: #fff; max-width: none;
}
.guide-cta h2, .guide-cta h3 { color: #fff; margin: 0 0 0.5rem; }
.guide-cta p { color: rgba(255, 255, 255, 0.9); margin-bottom: 1.1rem; }
.guide-cta .btn { margin-right: 0.6rem; margin-bottom: 0.4rem; }

/* Checklist */
.guide-check { list-style: none; padding: 0; }
.guide-check li { padding-left: 1.6rem; position: relative; }
.guide-check li::before { content: "✓"; position: absolute; left: 0; color: #17b06b; font-weight: 700; }

/* Bloc téléchargement (lead magnet) */
.guide-dl {
  background: #fff; border: 1px solid rgba(0, 72, 124, 0.14); border-radius: 18px;
  padding: clamp(1.4rem, 3vw, 2rem); margin: 2rem 0;
  box-shadow: var(--shadow-lg, 0 16px 40px rgba(0, 61, 107, 0.12));
  max-width: none;
}
.guide-dl__eyebrow {
  display: inline-flex; align-items: center; gap: 0.5rem;
  font: 600 0.72rem/1 "Jost", sans-serif; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--electric, #2e7cf6); background: rgba(46, 124, 246, 0.09);
  border-radius: 999px; padding: 0.4rem 0.8rem; margin-bottom: 0.8rem;
}
.guide-dl h2, .guide-dl h3 { margin-top: 0 !important; }
.guide-dl form { display: grid; gap: 0.75rem; max-width: 460px; margin-top: 1rem; }
.guide-dl__consent { display: flex; gap: 0.55rem; align-items: flex-start; font: 400 0.8rem/1.45 "Jost", sans-serif; color: var(--marine, #00487c); }
.guide-dl__consent input { margin-top: 0.2rem; flex: none; }
.guide-dl__hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.guide-dl__ok { display: grid; gap: 0.8rem; max-width: 460px; }
.guide-dl__ok p { margin: 0; }

/* Signature auteur */
.guide-author {
  max-width: 760px; margin: 2.5rem auto 0; padding-top: 1.2rem;
  border-top: 1px solid rgba(0, 72, 124, 0.14);
  font: 400 0.9rem/1.55 "Jost", sans-serif; color: var(--marine, #00487c);
}
.guide-author b { color: var(--marine-deep, #003d6b); }

/* --- Hub /guides --- */
.guides-grid { display: grid; gap: 1.1rem; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); align-items: stretch; }
.guide-card {
  background: #fff; border: 1px solid rgba(0, 72, 124, 0.12); border-radius: 16px;
  padding: 1.3rem 1.4rem; text-decoration: none; display: flex; flex-direction: column; gap: 0.55rem;
  transition: transform 0.35s var(--curve, cubic-bezier(0.32, 0.72, 0, 1)), box-shadow 0.35s ease;
}
.guide-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg, 0 16px 40px rgba(0, 61, 107, 0.15)); }
.guide-card__tag {
  align-self: flex-start; font: 600 0.68rem/1 "Jost", sans-serif; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--electric, #2e7cf6); background: rgba(46, 124, 246, 0.09); border-radius: 999px; padding: 0.32rem 0.62rem;
}
.guide-card h2, .guide-card h3 {
  font: 600 1.25rem/1.3 var(--font-display);
  color: var(--marine-deep, #003d6b); margin: 0;
}
.guide-card p { color: var(--marine, #00487c); font-size: 0.92rem; line-height: 1.55; margin: 0; flex: 1; }
.guide-card__go { font: 600 0.86rem/1 "Jost", sans-serif; color: var(--electric, #2e7cf6); }

/* Les liens-boutons ne prennent pas la couleur des liens d'article */
.guide-prose a.btn--primary, .guide-cta a.btn--primary { color: #fff; }
.guide-prose a.btn--glass, .guide-cta a.btn--glass { color: #fff; }

/* --- Feuilleteur du modèle (aperçu avant téléchargement) — PROTOTYPE --- */
.doc-flip { margin: 1.4rem 0 0.4rem; max-width: none; }
.doc-flip__stage {
  position: relative; max-width: 430px; aspect-ratio: 210/265; margin: 0 auto;
  perspective: 1600px;
}
.doc-flip__page {
  position: absolute; inset: 0;
  background: #fff; border: 1px solid rgba(0, 72, 124, 0.14); border-radius: 6px;
  box-shadow: 0 10px 30px rgba(0, 61, 107, 0.14);
  padding: clamp(1.1rem, 4vw, 1.8rem);
  transform-origin: left center;
  transition: transform 0.65s cubic-bezier(0.4, 0.1, 0.2, 1), opacity 0.4s ease;
  backface-visibility: hidden;
  overflow: hidden;
  display: flex; flex-direction: column;
}
.doc-flip__page.is-turned { transform: rotateY(-105deg); opacity: 0; pointer-events: none; }
@media (prefers-reduced-motion: reduce) {
  .doc-flip__page { transition: none; }
  .doc-flip__page.is-turned { transform: none; display: none; }
}
/* pile : légers décalages des pages suivantes, effet liasse */
.doc-flip__page:nth-child(2) { transform: translate(3px, 3px); }
.doc-flip__page:nth-child(3) { transform: translate(6px, 6px); }
.doc-flip__page:nth-child(4) { transform: translate(9px, 9px); }
.doc-flip__page.is-top { transform: none; z-index: 5; }

/* typographie « papier » des mini-pages */
.dfp__center { margin: auto; text-align: center; }
.dfp__kicker { font: 700 clamp(0.9rem, 3vw, 1.15rem)/1.2 "Jost", sans-serif; color: #003d6b; letter-spacing: 0.02em; }
.dfp__ph { color: #8aa0ac; font-size: clamp(0.6rem, 2vw, 0.74rem); line-height: 1.5; }
.dfp__foot { margin-top: auto; text-align: center; color: #9fb2bc; font-size: clamp(0.5rem, 1.6vw, 0.62rem); }
.dfp__h { font: 700 clamp(0.72rem, 2.3vw, 0.88rem)/1.3 "Jost", sans-serif; color: #00487c; margin: 0 0 0.4rem; }
.dfp__t { font-size: clamp(0.58rem, 1.9vw, 0.72rem); line-height: 1.55; color: #2c4a5c; margin: 0 0 0.5rem; }
.dfp__c { font-size: clamp(0.55rem, 1.8vw, 0.68rem); line-height: 1.5; color: #8aa0ac; font-style: italic; margin: 0 0 0.5rem; }
.dfp__field { font-size: clamp(0.55rem, 1.8vw, 0.68rem); color: #5c737d; background: #f2f6f7; border-radius: 4px; padding: 0.3rem 0.5rem; margin: 0 0 0.3rem; }

/* dernière page : voilée + cadenas */
.doc-flip__page--locked .doc-flip__veil {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(255,255,255,0.35), rgba(255,255,255,0.94) 62%);
  display: flex; flex-direction: column; align-items: center; justify-content: flex-end;
  padding: 1.4rem; text-align: center; gap: 0.6rem;
}
.doc-flip__veil b { color: #003d6b; font-size: 0.92rem; }
.doc-flip__veil p { color: #5c737d; font-size: 0.8rem; margin: 0; }

/* commandes */
.doc-flip__nav {
  display: flex; align-items: center; justify-content: center; gap: 1rem;
  margin-top: 1rem;
}
.doc-flip__btn {
  width: 42px; height: 42px; border-radius: 50%;
  border: 1px solid rgba(0, 72, 124, 0.25); background: #fff;
  color: var(--marine, #00487c); font-size: 1.1rem; cursor: pointer;
  transition: border-color 0.2s ease, color 0.2s ease, opacity 0.2s ease;
}
.doc-flip__btn:hover:not(:disabled) { border-color: var(--electric, #2e7cf6); color: var(--electric, #2e7cf6); }
.doc-flip__btn:disabled { opacity: 0.35; cursor: default; }
.doc-flip__count { font: 600 0.84rem/1 "Jost", sans-serif; color: var(--marine, #00487c); min-width: 3.2em; text-align: center; }
.doc-flip__hint { text-align: center; font: 500 0.78rem/1.4 "Jost", sans-serif; color: var(--marine, #00487c); opacity: 0.65; margin-top: 0.5rem; }

/* Feuilleteur intégré à la carte de téléchargement */
.guide-dl .doc-flip { margin: 1.3rem 0 1.6rem; }
.guide-dl .doc-flip__stage { max-width: 360px; }

/* Page couverture réelle dans le feuilleteur */
.doc-flip__page--cover { padding: 0; }
.doc-flip__page--cover img { width: 100%; height: 100%; object-fit: cover; border-radius: 6px; }

/* Illustration pleine largeur dans le corps d'un guide */
.guide-illu { margin: 1.9rem 0; }
.guide-illu img { width: 100%; height: auto; display: block; border-radius: 14px; box-shadow: 0 10px 30px rgba(0, 61, 107, 0.12); }

/* Bandeau e-book en tête du sommaire des guides */
.guide-banner {
  display: flex;
  align-items: center;
  gap: 1.4rem;
  padding: 1.15rem 1.7rem;
  margin-bottom: 1.5rem;
  background: linear-gradient(115deg, #ffffff 55%, #eef4fb 100%);
  border: 1px solid rgba(46, 124, 246, 0.35);
  border-radius: 14px;
  text-decoration: none;
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}
.guide-banner:hover { transform: translateY(-2px); box-shadow: 0 12px 30px rgba(0, 61, 107, 0.14); }
.guide-banner > img {
  height: 96px;
  width: auto;
  border-radius: 6px;
  box-shadow: 0 6px 16px rgba(0, 61, 107, 0.28);
  transform: rotate(-2deg);
  flex: none;
}
.guide-banner__txt { display: flex; flex-direction: column; gap: 0.35rem; flex: 1; min-width: 0; }
.guide-banner__txt .guide-card__tag { align-self: flex-start; }
.guide-banner__title { font-family: var(--font-display); font-weight: 600; font-size: 1.38rem; line-height: 1.3; color: var(--deep, #003d6b); }
.guide-banner__go { font: 600 0.92rem/1 "Jost", sans-serif; color: #fff; background: var(--marine, #00487c); padding: 0.8rem 1.35rem; border-radius: 9px; flex: none; }
@media (max-width: 640px) {
  .guide-banner { flex-direction: column; align-items: stretch; gap: 0.9rem; padding: 1.1rem 1.2rem; }
  .guide-banner > img { height: 120px; width: auto; align-self: center; }
  .guide-banner__txt { align-items: center; text-align: center; }
  .guide-banner__txt .guide-card__tag { align-self: center; white-space: nowrap; }
  .guide-banner__title { font-size: 1.22rem; }
  .guide-banner__go { text-align: center; }
}

/* Puces des cartes du sommaire */
.guide-card__points { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 0.45rem; flex: 1; }
.guide-card__points li { position: relative; padding-left: 1.15rem; color: var(--marine, #00487c); font-size: 0.92rem; line-height: 1.5; }
.guide-card__points li::before { content: "◆"; position: absolute; left: 0; top: 0.1em; font-size: 0.62rem; color: var(--electric, #2e7cf6); }

/* Liens vers les pages territoire, en fin de guide */
.guide-terr { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem 0.6rem; max-width: 760px; margin: 2.2rem auto 0; padding-top: 1.4rem; border-top: 1px solid rgba(0, 72, 124, 0.14); }
.guide-terr b { flex-basis: 100%; font-weight: 600; color: var(--ink, #0B2A44); }
.guide-terr a { padding: 0.4rem 0.95rem; border: 1px solid rgba(0, 72, 124, 0.22); border-radius: 999px; background: #fff; font-size: 0.92rem; color: var(--marine, #00487c); }
.guide-terr a:hover { border-color: var(--marine, #00487c); }
