/* =========================================================================
   Composants transverses : témoignages, calculateur de devis, disponibilité,
   réservation, blog, glossaire, newsletter, timeline, FAQ recherche,
   espace client.
   ========================================================================= */

/* ---- Témoignages (#13) ---- */
.testimonial-card {
  background: #fff;
  border-radius: 12px;
  padding: 28px;
  box-shadow: 0 10px 25px rgba(15, 23, 42, .06);
  height: 100%;
}
.testimonial-stars { color: var(--accent); font-size: .9rem; margin-bottom: 10px; }
.testimonial-avatar {
  width: 44px; height: 44px; border-radius: 9999px;
  background: var(--primary); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: .85rem;
}

/* ---- Logos clients (#14) ---- */
.client-logos-strip { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 40px; opacity: .8; }
.client-logos-strip img { height: 32px; width: auto; filter: grayscale(1); }

/* ---- Calculateur de devis (#16) ---- */
#quoteCalcModal {
  position: fixed; inset: 0; z-index: 90; display: none;
  align-items: flex-start; justify-content: center;
  background: rgba(15, 23, 42, .6);
  padding: 24px 16px; overflow-y: auto;
}
#quoteCalcModal.open { display: flex; }
.quote-calc-panel {
  background: #fff; border-radius: 16px; max-width: 640px; width: 100%;
  margin-top: 40px; padding: 32px; position: relative;
}
html.dark .quote-calc-panel { background: #111827; }
.quote-calc-close {
  position: absolute; top: 16px; right: 16px;
  width: 36px; height: 36px; border-radius: 9999px;
  display: flex; align-items: center; justify-content: center;
  background: #f1f5f9;
}
html.dark .quote-calc-close { background: #1f2937; }
.quote-calc-option {
  border: 2px solid #e2e8f0; border-radius: 10px; padding: 12px 16px;
  cursor: pointer; display: flex; align-items: center; justify-content: space-between;
  transition: border-color .2s ease, background-color .2s ease;
}
.quote-calc-option:hover { border-color: rgba(30,90,245,.4); }
.quote-calc-option.selected { border-color: var(--primary); background: rgba(30,90,245,.06); }
.quote-calc-total {
  background: linear-gradient(135deg, var(--primary), var(--accent));
  color: #fff; border-radius: 12px; padding: 20px; text-align: center;
}
#openQuoteCalc { min-height: 44px; }

/* ---- Badge disponibilité (#19) ---- */
.availability-badge {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: .85rem; font-weight: 500;
  background: #fff; border: 1px solid #e2e8f0; border-radius: 9999px;
  padding: 6px 14px;
}
.availability-dot { width: 9px; height: 9px; border-radius: 9999px; background: #22c55e; }
.availability-dot.limitee { background: #f59e0b; }
.availability-dot.complet { background: #ef4444; }
@keyframes availability-pulse { 0%,100% { opacity: 1; } 50% { opacity: .4; } }
.availability-dot { animation: availability-pulse 2s ease-in-out infinite; }

/* ---- Réservation / RDV (#20) ---- */
.booking-frame-wrap { border-radius: 16px; overflow: hidden; min-height: 480px; background: #f8fafc; }
html.dark .booking-frame-wrap { background: #0b1220; }
.booking-frame-wrap iframe { width: 100%; height: 640px; border: 0; }

/* ---- Blog (#21) ---- */
.blog-card {
  background: #fff; border-radius: 12px; overflow: hidden;
  box-shadow: 0 10px 25px rgba(15, 23, 42, .06);
  transition: transform .3s ease, box-shadow .3s ease;
  display: flex; flex-direction: column; height: 100%;
}
.blog-card:hover { transform: translateY(-6px); box-shadow: 0 20px 35px rgba(15,23,42,.1); }
.blog-card-thumb {
  height: 10rem; display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, rgba(30,90,245,.12), rgba(255,122,0,.12));
}
.blog-meta { font-size: .8rem; color: #64748b; }
article.blog-article h2 { font-size: 1.5rem; font-weight: 700; margin: 32px 0 16px; }
article.blog-article h3 { font-size: 1.15rem; font-weight: 700; margin: 24px 0 12px; }
article.blog-article p { margin-bottom: 16px; line-height: 1.75; color: #334155; }
html.dark article.blog-article p { color: #cbd5e1; }
article.blog-article ul { list-style: disc; padding-left: 22px; margin-bottom: 16px; }

/* ---- Timeline processus enrichie (#22) ---- */
.process-step .step-detail {
  max-height: 0; overflow: hidden; opacity: 0;
  transition: max-height .35s ease, opacity .35s ease, margin .35s ease;
}
.process-step.step-open .step-detail { max-height: 220px; opacity: 1; margin-top: 10px; }
.process-step .step-toggle { cursor: pointer; }

/* ---- FAQ recherche (#23) ---- */
.faq-search-wrap { position: relative; max-width: 420px; margin: 0 auto 32px; }
.faq-search-wrap input {
  width: 100%; padding: 12px 16px 12px 42px; border-radius: 9999px;
  border: 1px solid #e2e8f0; background: #fff;
}
.faq-search-wrap i { position: absolute; left: 16px; top: 50%; transform: translateY(-50%); color: #94a3b8; }
.faq-item.faq-hidden { display: none; }
.faq-no-results { display: none; text-align: center; color: #64748b; padding: 20px; }
.faq-no-results.show { display: block; }
mark.faq-mark { background: rgba(255,122,0,.35); color: inherit; border-radius: 3px; padding: 0 2px; }

/* ---- Glossaire (#24) ---- */
.glossary-term { border-bottom: 1px solid #e2e8f0; padding: 20px 0; }
.glossary-term dt { font-weight: 700; color: var(--secondary); margin-bottom: 6px; font-size: 1.05rem; }
html.dark .glossary-term dt { color: #f1f5f9; }
.glossary-term dd { color: #475569; line-height: 1.6; }
html.dark .glossary-term dd { color: #94a3b8; }
.glossary-nav { position: sticky; top: 96px; }
.glossary-nav a { display: block; padding: 6px 0; color: #64748b; }
.glossary-nav a:hover { color: var(--primary); }

/* ---- Newsletter (#32) ---- */
.newsletter-box {
  background: linear-gradient(135deg, var(--secondary), #1e293b);
  border-radius: 16px; padding: 32px; color: #fff;
}
.newsletter-box input {
  width: 100%; padding: 12px 16px; border-radius: 9999px; border: none;
  color: #0f172a;
}
.newsletter-note { font-size: .75rem; opacity: .7; margin-top: 10px; }

/* ---- CTA "Ce projet vous intéresse" (#34) ---- */
.project-interest-cta {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; flex-wrap: wrap;
  background: rgba(30,90,245,.06); border-radius: 12px; padding: 16px 20px; margin-top: 20px;
}

/* ---- Espace client / suivi de projet (#35) ---- */
.client-status-timeline { position: relative; padding-left: 28px; }
.client-status-timeline::before {
  content: ""; position: absolute; left: 9px; top: 4px; bottom: 4px; width: 2px; background: #e2e8f0;
}
.client-status-step { position: relative; padding-bottom: 28px; }
.client-status-step::before {
  content: ""; position: absolute; left: -28px; top: 2px; width: 20px; height: 20px;
  border-radius: 9999px; background: #e2e8f0; border: 3px solid #fff;
}
.client-status-step.done::before { background: var(--primary); }
.client-status-step.current::before { background: var(--accent); }
.demo-banner {
  background: #fff7ed; border: 1px solid #fed7aa; color: #9a3412;
  border-radius: 10px; padding: 14px 18px; font-size: .9rem;
}
html.dark .demo-banner { background: rgba(154,52,18,.15); border-color: rgba(251,146,60,.3); color: #fdba74; }

/* ---- Sélecteur de langue (#27) ---- */
#langToggle { display: inline-flex; border: 1px solid #e2e8f0; border-radius: 9999px; overflow: hidden; font-size: .78rem; font-weight: 600; }
#langToggle button { padding: 6px 10px; color: #64748b; }
#langToggle button.active { background: var(--primary); color: #fff; }

/* ---- Bannière PWA / installation (#30) ---- */
#pwaInstallBanner {
  position: fixed; left: 16px; right: 16px; bottom: 16px; z-index: 45;
  max-width: 420px; margin: 0 auto; background: #fff; border-radius: 14px;
  box-shadow: 0 20px 40px rgba(15,23,42,.2); padding: 16px 18px;
  display: none; align-items: center; gap: 12px;
}
#pwaInstallBanner.show { display: flex; }
html.dark #pwaInstallBanner { background: #111827; }

/* ---- Fil d'ariane générique pour pages secondaires ---- */
.subpage-hero { padding-top: 128px; padding-bottom: 48px; }
