/* Schémas visuels PME — problème, solution, fonctionnement */

.flow-page-hero {
  background: linear-gradient(165deg, #0f172a 0%, #1e3a5f 100%);
  color: #fff;
  padding: 56px 24px 64px;
  text-align: center;
}
.flow-page-hero h1 {
  font-family: 'Syne', sans-serif;
  font-size: clamp(1.6rem, 4vw, 2.4rem);
  margin: 16px 0 12px;
  max-width: 720px;
  margin-left: auto;
  margin-right: auto;
}
.flow-page-hero .lead { color: rgba(255,255,255,.82); max-width: 560px; margin: 0 auto 24px; font-size: 1.05rem; }
.flow-page-hero .hero-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }

.flow-section { padding: 64px 0; }
.flow-section.alt { background: #fff; }
.flow-section.dark { background: var(--navy); color: #fff; }
.flow-section.dark .section-head p { color: rgba(255,255,255,.7); }
.flow-section.dark h2 { color: #fff; }

.flow-tag {
  display: inline-block;
  font-size: .72rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .08em;
  padding: 5px 12px;
  border-radius: 999px;
  margin-bottom: 12px;
}
.flow-tag.problem { background: #fee2e2; color: #991b1b; }
.flow-tag.solution { background: rgba(200,241,53,.25); color: #3d5a00; }
.flow-tag.how { background: #dbeafe; color: #1e40af; }
.flow-section.dark .flow-tag.solution { background: rgba(200,241,53,.2); color: var(--accent); }

/* Coût du problème */
.impact-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  max-width: 800px;
  margin: 32px auto 0;
}
.impact-box {
  background: #fff;
  border: 2px solid #fecaca;
  border-radius: var(--radius);
  padding: 20px;
  text-align: center;
}
.impact-box .num {
  font-family: 'Syne', sans-serif;
  font-size: 2rem;
  color: #dc2626;
  line-height: 1.1;
}
.impact-box p { margin: 8px 0 0; font-size: .88rem; color: var(--muted); }

/* Schéma horizontal */
.flow-schema {
  display: flex;
  align-items: stretch;
  gap: 0;
  margin: 32px 0;
  overflow-x: auto;
  padding-bottom: 8px;
  -webkit-overflow-scrolling: touch;
}
.flow-node {
  flex: 1 1 140px;
  min-width: 120px;
  background: var(--surface);
  border: 2px solid var(--line);
  border-radius: 12px;
  padding: 16px 12px;
  text-align: center;
  position: relative;
}
.flow-node .ico { font-size: 1.8rem; line-height: 1; margin-bottom: 8px; }
.flow-node h4 { margin: 0 0 6px; font-size: .82rem; font-weight: 800; line-height: 1.25; }
.flow-node p { margin: 0; font-size: .72rem; color: var(--muted); line-height: 1.35; }
.flow-node.bad { border-color: #fca5a5; background: #fef2f2; }
.flow-node.bad h4 { color: #991b1b; }
.flow-node.good { border-color: #86efac; background: #f0fdf4; }
.flow-node.good h4 { color: #166534; }
.flow-node.accent { border-color: var(--accent-dark); background: rgba(200,241,53,.12); }
.flow-node.neutral { border-color: #cbd5e1; }

.flow-arrow {
  flex: 0 0 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  font-size: 1.2rem;
  font-weight: 700;
}
.flow-arrow.down { flex: none; height: 28px; width: 100%; }

/* Schéma vertical (mobile-friendly) */
.flow-schema-v {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
  max-width: 320px;
  margin: 32px auto;
}
.flow-schema-v .flow-node { width: 100%; }
.flow-schema-v .flow-arrow { height: 24px; width: auto; transform: rotate(90deg); }

/* Avant / Après */
.compare-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-top: 32px;
}
.compare-col {
  border-radius: var(--radius);
  padding: 24px;
  border: 2px solid var(--line);
}
.compare-col.before { background: #fef2f2; border-color: #fecaca; }
.compare-col.after { background: #f0fdf4; border-color: #86efac; }
.compare-col h3 {
  margin: 0 0 16px;
  font-size: 1rem;
  display: flex;
  align-items: center;
  gap: 8px;
}
.compare-col.before h3 { color: #991b1b; }
.compare-col.after h3 { color: #166534; }
.compare-col ol {
  margin: 0;
  padding-left: 20px;
  font-size: .92rem;
  line-height: 1.7;
}
.compare-col li { margin-bottom: 6px; }

/* Étapes numérotées grandes */
.big-steps {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin-top: 32px;
}
.big-step {
  display: flex;
  gap: 16px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: var(--shadow);
}
.big-step .n {
  flex: 0 0 44px;
  height: 44px;
  border-radius: 12px;
  background: var(--navy);
  color: #fff;
  font-family: 'Syne', sans-serif;
  font-size: 1.2rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
}
.big-step h4 { margin: 0 0 6px; font-size: .95rem; }
.big-step p { margin: 0; font-size: .85rem; color: var(--muted); }

/* Mini téléphone dans schéma */
.flow-phone {
  max-width: 260px;
  margin: 24px auto 0;
  border-radius: 24px;
  border: 3px solid var(--navy);
  overflow: hidden;
  background: #fff;
  box-shadow: var(--shadow-lg);
}
.flow-phone-head {
  background: var(--navy);
  color: #fff;
  font-size: .72rem;
  font-weight: 700;
  padding: 10px;
  text-align: center;
}
.flow-phone-body { padding: 12px; min-height: 120px; }
.flow-phone-body .b {
  font-size: .75rem;
  padding: 8px 10px;
  border-radius: 12px;
  margin-bottom: 8px;
  line-height: 1.35;
}
.flow-phone-body .b.out { background: #e2e8f0; margin-right: 24px; }
.flow-phone-body .b.in { background: var(--accent); margin-left: 24px; text-align: right; }

/* Dashboard simplifié */
.dash-mock {
  background: var(--navy);
  border-radius: var(--radius);
  padding: 20px;
  color: #fff;
  max-width: 480px;
  margin: 24px auto 0;
}
.dash-mock-row {
  display: flex;
  gap: 12px;
  margin-bottom: 12px;
}
.dash-mock-stat {
  flex: 1;
  background: rgba(255,255,255,.1);
  border-radius: 10px;
  padding: 14px;
  text-align: center;
}
.dash-mock-stat .v { font-family: 'Syne', sans-serif; font-size: 1.4rem; color: var(--accent); }
.dash-mock-stat .l { font-size: .68rem; opacity: .75; margin-top: 4px; }

.flow-cta {
  text-align: center;
  padding: 48px 24px;
  background: linear-gradient(135deg, rgba(200,241,53,.15), rgba(200,241,53,.05));
  border-radius: var(--radius);
  margin-top: 48px;
}
.flow-cta h3 { font-family: 'Syne', sans-serif; margin: 0 0 8px; }

/* Mode présentation tablette (porte-à-porte) */
body.mode-vente .nav-links .nav-link,
body.mode-vente .nav-links .btn-ghost:not(.btn-demo) { display: none; }
body.mode-vente .flow-page-hero { padding-top: 80px; }
body.mode-vente .flow-node h4 { font-size: .9rem; }
body.mode-vente .flow-node p { font-size: .8rem; }
body.mode-vente .big-step { padding: 24px; }
body.mode-vente .sticky-vente {
  display: flex;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(15,23,42,.95);
  padding: 12px 16px;
  gap: 10px;
  justify-content: center;
  z-index: 200;
  backdrop-filter: blur(8px);
}
.sticky-vente { display: none; }
body.mode-vente .sticky-vente { display: flex; }
body.mode-vente { padding-bottom: 72px; }

@media (max-width: 768px) {
  .impact-grid, .compare-grid, .big-steps { grid-template-columns: 1fr; }
  .flow-schema { flex-direction: column; align-items: stretch; }
  .flow-arrow { transform: rotate(90deg); height: 20px; flex: none; }
}

@media print {
  .nav, .sticky-vente, .flow-cta .btn { display: none !important; }
  .flow-section { page-break-inside: avoid; padding: 32px 0; }
  body { background: #fff; }
}
