/* ───────────────────────────────────────────────────────────────────────────
   Pulp-e — landing page
   Les couleurs, rayons et ombres viennent du design system de l'application
   (apps/frontend/src/_shared/ui/styles/design-tokens.css) : la page doit
   ressembler au produit qu'elle vend.
   ─────────────────────────────────────────────────────────────────────────── */

:root {
  --em-50: #ecfdf5;
  --em-100: #d1fae5;
  --em-200: #a7f3d0;
  --em-300: #6ee7b7;
  --em-400: #34d399;
  --em-500: #10b981;
  --em-600: #059669;
  --em-700: #047857;
  --em-800: #065f46;
  --em-900: #022c22;

  --am-300: #fcd34d;
  --am-400: #fbbf24;
  --am-500: #f59e0b;

  --page: #f0fdf7;
  --surface: #ffffff;
  --text-heading: #022c22;
  --text-body: #1f3d33;
  --text-muted: #6b9e7a;
  --border-primary: #a7f3d0;
  --border-divider: #e5f7f0;

  --radius-btn: 12px;
  --radius-card: 18px;
  --radius-pill: 999px;

  --shadow-card: 0 1px 3px rgba(0, 0, 0, 0.06), 0 4px 16px rgba(0, 0, 0, 0.04);
  --shadow-card-hover: 0 4px 24px rgba(5, 150, 105, 0.13);
  --shadow-btn: 0 2px 10px rgba(16, 185, 129, 0.3);

  --max-width: 1120px;
}

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

body {
  margin: 0;
  font-family: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI",
    sans-serif;
  color: var(--text-body);
  background: var(--surface);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3 {
  color: var(--text-heading);
  line-height: 1.15;
  margin: 0;
  letter-spacing: -0.02em;
}

p {
  margin: 0;
}

a {
  color: inherit;
  text-decoration: none;
}

img,
svg {
  max-width: 100%;
}

.wrap {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

.section {
  padding: 96px 0;
}

.section--tint {
  background: var(--page);
}

.section__head {
  max-width: 640px;
  margin: 0 auto 56px;
  text-align: center;
}

.section__head h2 {
  font-size: clamp(1.75rem, 3.5vw, 2.5rem);
  margin-bottom: 16px;
}

.section__head p {
  color: var(--text-muted);
  font-size: 1.0625rem;
}

.eyebrow {
  display: inline-block;
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  background: var(--em-100);
  color: var(--em-700);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  margin-bottom: 20px;
}

/* ─── Boutons ────────────────────────────────────────────────────────────── */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 26px;
  border: 1px solid transparent;
  border-radius: var(--radius-btn);
  font: inherit;
  font-weight: 700;
  font-size: 0.9375rem;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease,
    background-color 0.15s ease;
}

.btn--primary {
  background: var(--em-600);
  color: #fff;
  box-shadow: var(--shadow-btn);
}

.btn--primary:hover {
  background: var(--em-700);
  transform: translateY(-1px);
}

.btn--ghost {
  background: var(--surface);
  color: var(--em-800);
  border-color: var(--border-primary);
}

.btn--ghost:hover {
  background: var(--em-50);
}

.btn--block {
  width: 100%;
}

/* ─── En-tête ────────────────────────────────────────────────────────────── */

.header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border-divider);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  height: 72px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 1.25rem;
  color: var(--text-heading);
  letter-spacing: -0.03em;
}

.logo__mark {
  height: 34px;
  width: auto;
}

.nav {
  display: flex;
  align-items: center;
  gap: 28px;
}

.nav a {
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--text-muted);
}

.nav a:hover {
  color: var(--em-700);
}

/* ─── Hero ───────────────────────────────────────────────────────────────── */

.hero {
  position: relative;
  overflow: hidden;
  background: linear-gradient(180deg, var(--page), var(--surface));
  padding: 88px 0 96px;
}

.hero__grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 56px;
  align-items: center;
}

.hero h1 {
  font-size: clamp(2.25rem, 5vw, 3.5rem);
  margin-bottom: 20px;
}

.hero__lead {
  font-size: 1.125rem;
  color: var(--text-muted);
  max-width: 34em;
  margin-bottom: 32px;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 28px;
}

.hero__note {
  font-size: 0.875rem;
  color: var(--text-muted);
}

/* Aperçu de l'application : une carte qui rappelle l'écran de suivi des cuves,
   sans prétendre être une capture d'écran réelle. */
.preview {
  background: var(--surface);
  border: 1px solid var(--border-divider);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card-hover);
  overflow: hidden;
}

.preview__bar {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 14px 18px;
  background: var(--em-50);
  border-bottom: 1px solid var(--border-divider);
}

.preview__dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--em-200);
}

.preview__title {
  margin-left: 8px;
  font-size: 0.8125rem;
  font-weight: 700;
  color: var(--em-700);
}

.preview__body {
  padding: 22px;
  display: grid;
  gap: 14px;
}

.stat-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.stat {
  background: var(--page);
  border: 1px solid var(--border-divider);
  border-radius: 12px;
  padding: 14px;
}

.stat__label {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 600;
}

.stat__value {
  font-size: 1.375rem;
  font-weight: 800;
  color: var(--text-heading);
  letter-spacing: -0.02em;
}

.vat {
  display: grid;
  gap: 8px;
  padding: 14px;
  border: 1px solid var(--border-divider);
  border-radius: 12px;
}

.vat__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--text-heading);
}

.badge {
  font-size: 0.6875rem;
  font-weight: 800;
  padding: 3px 10px;
  border-radius: var(--radius-pill);
  background: var(--em-100);
  color: var(--em-700);
  letter-spacing: 0.02em;
}

.badge--amber {
  background: #fef3c7;
  color: #92400e;
}

.bar {
  height: 8px;
  border-radius: var(--radius-pill);
  background: var(--em-50);
  overflow: hidden;
}

.bar__fill {
  height: 100%;
  border-radius: var(--radius-pill);
  background: linear-gradient(90deg, var(--em-400), var(--em-600));
}

.vat__meta {
  font-size: 0.75rem;
  color: var(--text-muted);
}

/* ─── Bandeau de confiance ───────────────────────────────────────────────── */

.trust {
  border-top: 1px solid var(--border-divider);
  border-bottom: 1px solid var(--border-divider);
  background: var(--surface);
  padding: 28px 0;
}

.trust__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-muted);
}

.trust__item {
  display: flex;
  align-items: center;
  gap: 8px;
}

.trust__item span[aria-hidden] {
  color: var(--em-500);
}

/* ─── Fonctionnalités ────────────────────────────────────────────────────── */

.cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border-divider);
  border-radius: var(--radius-card);
  padding: 28px;
  box-shadow: var(--shadow-card);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-card-hover);
}

.card__icon {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: var(--em-50);
  font-size: 1.25rem;
  margin-bottom: 18px;
}

.card h3 {
  font-size: 1.0625rem;
  margin-bottom: 10px;
}

.card p {
  font-size: 0.9375rem;
  color: var(--text-muted);
}

/* ─── Déroulé ────────────────────────────────────────────────────────────── */

.steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  counter-reset: step;
}

.step {
  position: relative;
  padding-top: 20px;
  border-top: 2px solid var(--border-primary);
}

.step__num {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--em-600);
  color: #fff;
  font-size: 0.8125rem;
  font-weight: 800;
  margin-bottom: 14px;
}

.step h3 {
  font-size: 1rem;
  margin-bottom: 8px;
}

.step p {
  font-size: 0.9375rem;
  color: var(--text-muted);
}

/* ─── Tarifs ─────────────────────────────────────────────────────────────── */

.plans {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  align-items: start;
}

.plan {
  background: var(--surface);
  border: 1px solid var(--border-divider);
  border-radius: var(--radius-card);
  padding: 32px 28px;
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.plan--featured {
  border-color: var(--em-400);
  box-shadow: var(--shadow-card-hover);
  position: relative;
}

.plan__flag {
  position: absolute;
  top: -13px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--em-600);
  color: #fff;
  font-size: 0.6875rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  padding: 5px 14px;
  border-radius: var(--radius-pill);
  white-space: nowrap;
}

.plan__name {
  font-size: 1.125rem;
  font-weight: 800;
  color: var(--text-heading);
}

.plan__pitch {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin-top: 4px;
}

.plan__price {
  display: flex;
  align-items: baseline;
  gap: 6px;
}

.plan__amount {
  font-size: 2.75rem;
  font-weight: 800;
  color: var(--text-heading);
  letter-spacing: -0.03em;
}

.plan__period {
  font-size: 0.9375rem;
  color: var(--text-muted);
  font-weight: 600;
}

.plan__billing {
  font-size: 0.8125rem;
  color: var(--text-muted);
}

.plan__features {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 11px;
  font-size: 0.9375rem;
}

.plan__features li {
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.plan__features li::before {
  content: "✓";
  color: var(--em-600);
  font-weight: 800;
  flex: none;
}

.plan__features li.is-off {
  color: var(--text-muted);
}

.plan__features li.is-off::before {
  content: "—";
  color: var(--border-primary);
}

.plan .btn {
  margin-top: auto;
}

.pricing-note {
  margin-top: 32px;
  text-align: center;
  font-size: 0.875rem;
  color: var(--text-muted);
}

/* Un prix en mots n a pas a peser comme un montant : il se lit, il ne se
   compare pas chiffre a chiffre. */
.plan__amount--word {
  font-size: 1.75rem;
}

/* ─── Options ────────────────────────────────────────────────────────────── */

.options__title {
  margin: 56px 0 20px;
  font-size: 1.125rem;
  font-weight: 800;
  color: var(--text-heading);
  text-align: center;
}

.options {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px 24px;
}

.option {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: baseline;
  gap: 4px 16px;
  padding: 16px 20px;
  background: var(--surface);
  border: 1px solid var(--border-divider);
  border-radius: var(--radius-card);
}

.option__label {
  font-weight: 600;
  color: var(--text-heading);
  font-size: 0.9375rem;
}

.option__price {
  font-weight: 800;
  color: var(--text-heading);
  font-size: 0.9375rem;
  white-space: nowrap;
}

/* La precision passe sous les deux colonnes : elle qualifie l option
   entiere, pas seulement son prix. */
.option__note {
  grid-column: 1 / -1;
  font-size: 0.8125rem;
  color: var(--text-muted);
}

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

/* ─── Témoignage ─────────────────────────────────────────────────────────── */

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

.quote blockquote {
  margin: 0 0 22px;
  font-size: clamp(1.125rem, 2.4vw, 1.5rem);
  line-height: 1.45;
  color: var(--text-heading);
  font-weight: 600;
}

.quote__author {
  font-size: 0.9375rem;
  color: var(--text-muted);
}

/* ─── FAQ ────────────────────────────────────────────────────────────────── */

.faq {
  max-width: 760px;
  margin: 0 auto;
  display: grid;
  gap: 12px;
}

.faq details {
  background: var(--surface);
  border: 1px solid var(--border-divider);
  border-radius: 14px;
  padding: 18px 22px;
}

.faq details[open] {
  border-color: var(--border-primary);
}

.faq summary {
  cursor: pointer;
  font-weight: 700;
  color: var(--text-heading);
  list-style: none;
  display: flex;
  justify-content: space-between;
  gap: 16px;
}

.faq summary::-webkit-details-marker {
  display: none;
}

.faq summary::after {
  content: "+";
  color: var(--em-600);
  font-weight: 800;
}

.faq details[open] summary::after {
  content: "–";
}

.faq p {
  margin-top: 12px;
  font-size: 0.9375rem;
  color: var(--text-muted);
}

/* ─── Appel final ────────────────────────────────────────────────────────── */

.cta {
  background: linear-gradient(140deg, var(--em-700), var(--em-900));
  color: #fff;
  border-radius: var(--radius-card);
  padding: 56px 40px;
  text-align: center;
}

.cta h2 {
  color: #fff;
  font-size: clamp(1.625rem, 3.2vw, 2.25rem);
  margin-bottom: 14px;
}

.cta p {
  color: var(--em-200);
  margin-bottom: 28px;
}

.cta .btn--primary {
  background: #fff;
  color: var(--em-800);
  box-shadow: none;
}

.cta .btn--primary:hover {
  background: var(--em-50);
}

/* ─── Pied de page ───────────────────────────────────────────────────────── */

.footer {
  border-top: 1px solid var(--border-divider);
  padding: 40px 0;
  font-size: 0.875rem;
  color: var(--text-muted);
}

.footer__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.footer nav {
  display: flex;
  gap: 22px;
}

.footer a:hover {
  color: var(--em-700);
}

/* ─── Adaptation aux petits écrans ───────────────────────────────────────── */

@media (max-width: 900px) {
  .section {
    padding: 72px 0;
  }

  .hero__grid {
    grid-template-columns: 1fr;
    gap: 44px;
  }

  .cards,
  .steps,
  .plans {
    grid-template-columns: 1fr;
  }

  .nav {
    display: none;
  }

  .plan--featured {
    order: -1;
  }
}

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

  .hero__actions .btn {
    width: 100%;
  }
}

/* ─── Encart ERP ─────────────────────────────────────────────────────────── */

.erp {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 48px;
  align-items: center;
  padding: 44px;
  background: var(--surface);
  border: 1px solid var(--border-primary);
  border-radius: var(--radius-card);
}

.erp__text h2 {
  font-size: clamp(1.5rem, 3vw, 2.125rem);
  margin-bottom: 16px;
}

.erp__text p {
  color: var(--text-muted);
  font-size: 1rem;
  margin-bottom: 14px;
}

.erp__lead strong {
  color: var(--em-700);
}

.erp__text .btn {
  margin-top: 10px;
}

.erp__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

.erp__item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 18px;
  background: var(--surface);
  border: 1px solid var(--border-divider);
  border-radius: 12px;
  box-shadow: var(--shadow-card);
}

/* Le connecteur en préparation se distingue de ceux qui ne sont qu'à l'étude :
   promettre au même niveau ce qui existe et ce qui est envisagé serait
   trompeur. */
.erp__item--next {
  border-color: var(--em-400);
}

.erp__name {
  font-weight: 700;
  color: var(--text-heading);
  font-size: 0.9375rem;
}

@media (max-width: 900px) {
  .erp {
    grid-template-columns: 1fr;
    gap: 32px;
    padding: 32px 24px;
  }
}

/* ─── Reprise des données ────────────────────────────────────────────────── */

.migration {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 32px;
  align-items: center;
  background: var(--surface);
  border: 1px solid var(--border-divider);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
  padding: 36px;
}

.migration__label {
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.migration__software {
  list-style: none;
  margin: 0 0 16px;
  padding: 0;
  display: grid;
  gap: 10px;
}

.migration__software li {
  padding: 14px 18px;
  border: 1px solid var(--border-primary);
  border-radius: 12px;
  background: var(--page);
}

/* « Autre chose » n'est pas un logiciel identifié : on le distingue des deux
   qu'on sait reprendre. */
.migration__software li.is-other {
  border-style: dashed;
  border-color: var(--border-divider);
  background: var(--surface);
}

.migration__name {
  font-weight: 700;
  color: var(--text-heading);
  font-size: 0.9375rem;
}

.migration__software li.is-other .migration__name {
  font-weight: 600;
  color: var(--text-muted);
}

.migration__note {
  font-size: 0.8125rem;
  color: var(--text-muted);
}

.migration__arrow {
  font-size: 1.75rem;
  color: var(--em-500);
  font-weight: 700;
}

.migration__items {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 11px;
  font-size: 0.9375rem;
}

.migration__items li {
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.migration__items li::before {
  content: "✓";
  color: var(--em-600);
  font-weight: 800;
  flex: none;
}

.migration__steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin-top: 28px;
}

.migration__step {
  display: flex;
  gap: 14px;
  align-items: flex-start;
}

.migration__step p {
  font-size: 0.9375rem;
  color: var(--text-muted);
}

.migration__step strong {
  color: var(--text-heading);
}

.migration__step .step__num {
  margin-bottom: 0;
}

/* Ce qui existe aujourd'hui et ce qui est en développement : le dire ici plutôt
   que de laisser croire à un import en un clic. */
.migration__legal {
  margin-top: 28px;
  text-align: center;
  font-size: 0.875rem;
  color: var(--text-muted);
}

@media (max-width: 900px) {
  .migration {
    grid-template-columns: 1fr;
    gap: 24px;
    padding: 28px 22px;
  }

  .migration__arrow {
    transform: rotate(90deg);
    justify-self: center;
  }

  .migration__steps {
    grid-template-columns: 1fr;
  }
}

/* ─── Appellations et bio ────────────────────────────────────────────────── */

/* Panneau sombre : le moment fort de la page, et il se détache de ses voisines
   sans dépendre de l'alternance des fonds clairs. */
.quality {
  background: linear-gradient(140deg, var(--em-700), var(--em-900));
  border-radius: var(--radius-card);
  padding: 52px 44px;
  color: #fff;
  display: grid;
  gap: 40px;
}

.quality__intro {
  max-width: 640px;
}

.quality__intro h2 {
  color: #fff;
  font-size: clamp(1.5rem, 3vw, 2.125rem);
  margin-bottom: 16px;
}

.quality__intro p {
  color: var(--em-200);
  font-size: 1.0625rem;
}

.eyebrow--dark {
  background: rgba(255, 255, 255, 0.12);
  color: var(--em-200);
}

.quality__cards {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.quality__card {
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 16px;
  padding: 28px;
}

.quality__icon {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.12);
  color: var(--am-400);
  margin-bottom: 18px;
}

.quality__icon--leaf {
  color: var(--em-300);
}

.quality__icon svg {
  width: 26px;
  height: 26px;
}

.quality__card h3 {
  color: #fff;
  font-size: 1.125rem;
  margin-bottom: 10px;
}

.quality__card > p {
  color: var(--em-200);
  font-size: 0.9375rem;
  margin-bottom: 16px;
}

.quality__points {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 9px;
  font-size: 0.9375rem;
  color: #fff;
}

.quality__points li {
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.quality__points li::before {
  content: "✓";
  color: var(--em-300);
  font-weight: 800;
  flex: none;
}

@media (max-width: 900px) {
  .quality {
    padding: 36px 24px;
    gap: 28px;
  }

  .quality__cards {
    grid-template-columns: 1fr;
  }
}
