/* =============================================================
   CHANTE-MOI — Landing
   Palette pastel aquarelle · univers livre pour enfants
   ============================================================= */

:root {
  /* Palette */
  --cream:        #FBF4EA;
  --cream-deep:   #F5EADB;
  --sage:         #9DB39A;
  --sage-soft:    #C7D6C2;
  --peach:        #EFA987;
  --peach-soft:   #F6CDB6;
  --blue-powder:  #A9C3D1;
  --blue-soft:    #CFE0E7;

  /* Texte */
  --ink:          #463C33;   /* brun chaud profond */
  --ink-soft:     #6E6256;
  --white:        #FFFFFF;

  /* CTA */
  --cta:          #E78A60;   /* pêche chaude saturée mais douce */
  --cta-hover:    #D9744A;

  /* Système */
  --radius:       22px;
  --radius-lg:    34px;
  --shadow-sm:    0 6px 20px rgba(90, 70, 50, 0.07);
  --shadow-md:    0 14px 40px rgba(90, 70, 50, 0.10);
  --shadow-cta:   0 12px 28px rgba(216, 116, 74, 0.32);

  --maxw:         1120px;
  --maxw-narrow:  680px;

  --font-display: 'Caveat', 'Brush Script MT', cursive;
  --font-body:    'Nunito', system-ui, -apple-system, 'Segoe UI', sans-serif;
}

/* ---------- Reset léger ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--cream);
  line-height: 1.65;
  font-size: 1.0625rem;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }

/* ---------- Layout ---------- */
.container {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: 24px;
}
.container--narrow { max-width: var(--maxw-narrow); }

.section { padding-block: clamp(56px, 9vw, 110px); }

.section__title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2.4rem, 6vw, 3.6rem);
  line-height: 1.05;
  text-align: center;
  color: var(--ink);
  letter-spacing: 0.5px;
}
.section__title--left { text-align: left; }

.section__lead {
  text-align: center;
  color: var(--ink-soft);
  font-size: 1.15rem;
  margin-top: 12px;
  margin-bottom: clamp(36px, 5vw, 56px);
}

/* ---------- Boutons / CTA ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-family: var(--font-body);
  font-weight: 800;
  text-decoration: none;
  border: none;
  cursor: pointer;
  border-radius: 999px;
  transition: transform .2s ease, box-shadow .25s ease, background-color .25s ease;
  line-height: 1;
}
.btn--primary {
  background: var(--cta);
  color: var(--white);
  box-shadow: var(--shadow-cta);
}
.btn--primary:hover,
.btn--primary:focus-visible {
  background: var(--cta-hover);
  transform: translateY(-3px);
  box-shadow: 0 18px 36px rgba(216, 116, 74, 0.4);
}
.btn--primary:active { transform: translateY(-1px); }
.btn--lg {
  font-size: 1.2rem;
  padding: 20px 38px;
  min-height: 60px;           /* cible tactile confortable */
}
.btn:focus-visible {
  outline: 3px solid var(--blue-powder);
  outline-offset: 3px;
}

/* =============================================================
   HERO
   ============================================================= */
.hero {
  position: relative;
  background:
    radial-gradient(120% 80% at 85% 0%, var(--blue-soft) 0%, transparent 55%),
    var(--cream);
  overflow: hidden;
}

/* L'image et le panneau de texte partagent la même cellule de grille :
   le texte est en surimpression de l'image en grand écran (overlay),
   et passe sous l'image en mobile (empilé) via la media query. */
.hero__inner {
  display: grid;
  grid-template-areas: "stack";
  grid-template-columns: minmax(0, 1fr);   /* empêche la piste de dépasser le viewport */
}
.hero__media {
  grid-area: stack;
  margin: 0;
}
.hero__media img {
  width: 100%;
  height: clamp(540px, 60vh, 720px);
  object-fit: cover;
  object-position: 72% center;   /* recadre vers les personnages, à droite du panneau */
}
.hero__content {
  grid-area: stack;
  position: relative;
  z-index: 1;
  align-self: center;
  justify-self: start;
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: 24px;
}
/* Voile blanc semi-transparent pour garantir la lisibilité par-dessus l'image */
.hero__panel {
  max-width: 540px;
  background: rgba(255, 255, 255, 0.86);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: var(--radius-lg);
  padding: clamp(28px, 4vw, 48px);
  box-shadow: var(--shadow-md);
}

.brand {
  font-family: var(--font-display);
  font-size: 1.9rem;
  font-weight: 600;
  color: var(--sage);
  margin-bottom: 6px;
}

.hero__title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2.9rem, 7vw, 4.6rem);
  line-height: 1.02;
  letter-spacing: 0.5px;
  color: var(--ink);
  margin-bottom: 22px;
}
.hero__title em { color: var(--peach); font-style: italic; }
.hero__subtitle {
  font-size: clamp(1.1rem, 2.3vw, 1.3rem);
  color: var(--ink-soft);
  max-width: 30ch;
  margin-bottom: 34px;
}
.hero__subtitle em { color: var(--peach); font-style: italic; font-weight: 700; }

.hero__note {
  margin-top: 18px;
  font-size: .95rem;
  color: var(--ink-soft);
  letter-spacing: .3px;
}

/* =============================================================
   ÉMOTION
   ============================================================= */
.section--emotion {
  background: var(--cream-deep);
  text-align: center;
}
.emotion__text {
  font-family: var(--font-display);
  font-size: clamp(1.7rem, 4vw, 2.5rem);
  line-height: 1.35;
  color: var(--ink);
  font-weight: 500;
}
.emotion__text strong { color: var(--peach); font-weight: 700; }

/* =============================================================
   COMMENT ÇA MARCHE — 3 étapes
   ============================================================= */
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 26px;
}
.card {
  background: var(--white);
  border-radius: var(--radius);
  padding: 40px 28px 34px;
  box-shadow: var(--shadow-sm);
  transition: transform .3s ease, box-shadow .3s ease;
}
.card:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); }

.step { position: relative; text-align: center; }
.step__num {
  position: absolute;
  top: -16px; left: 50%;
  transform: translateX(-50%);
  width: 40px; height: 40px;
  display: grid; place-items: center;
  background: var(--sage);
  color: var(--white);
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  border-radius: 50%;
  box-shadow: var(--shadow-sm);
}
.step__icon {
  width: 76px; height: 76px;
  margin: 12px auto 20px;
  display: grid; place-items: center;
  background: var(--blue-soft);
  color: var(--ink);
  border-radius: 50%;
}
.step__icon svg { width: 42px; height: 42px; }
.step__title {
  font-size: 1.25rem;
  font-weight: 800;
  margin-bottom: 10px;
}
.step__text { color: var(--ink-soft); font-size: 1rem; }

/* tons alternés des icônes pour la chaleur */
.step:nth-child(2) .step__icon { background: var(--peach-soft); }
.step:nth-child(3) .step__icon { background: var(--sage-soft); }

/* =============================================================
   SHOWCASE (page + QR)
   ============================================================= */
.showcase {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(32px, 5vw, 64px);
  align-items: center;
}
.showcase__media img {
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  width: 100%;
}
.showcase__text p {
  color: var(--ink-soft);
  font-size: 1.12rem;
  margin-top: 18px;
}
.showcase__text strong { color: var(--ink); font-weight: 800; }

/* variante image à droite, texte à gauche */
.showcase--reverse .showcase__media { order: 2; }
.showcase--reverse .showcase__text { order: 1; }
.section--contenu { background: var(--cream-deep); }

/* =============================================================
   VISUEL "Comment ça marche" — livre + smartphone
   (même emplacement / cadre que l'ancien placeholder, centré)
   ============================================================= */
.step-demo {
  margin: clamp(32px, 5vw, 48px) auto 0;
  max-width: 600px;
}
.step-demo img {
  width: 100%;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
}

/* =============================================================
   CE QUE CONTIENT LE LIVRE — liste de specs
   ============================================================= */
.specs {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 14px;
  max-width: 600px;
  margin-inline: auto;
}
.spec {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  background: var(--white);
  border-radius: var(--radius);
  padding: 18px 22px;
  box-shadow: var(--shadow-sm);
  color: var(--ink-soft);
  font-size: 1.05rem;
}
.spec strong { color: var(--ink); font-weight: 800; }
/* liste alignée à gauche dans un bloc showcase (pas centrée) */
.specs--inline { margin-inline: 0; max-width: none; margin-top: 24px; }
.spec__check {
  flex: 0 0 auto;
  width: 28px; height: 28px;
  display: grid; place-items: center;
  background: var(--sage-soft);
  color: var(--ink);
  border-radius: 50%;
  font-weight: 800;
  font-size: .95rem;
  margin-top: 1px;
}

/* =============================================================
   POURQUOI C'EST UNIQUE — "Bien plus qu'un livre"
   ============================================================= */
.section--unique { text-align: center; }
.unique__media {
  margin: clamp(24px, 4vw, 36px) auto 0;
  max-width: 560px;
}
.unique__media img {
  width: 100%;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
}
.unique__text {
  font-size: clamp(1.15rem, 2.4vw, 1.4rem);
  color: var(--ink-soft);
  line-height: 1.6;
  margin-top: clamp(24px, 4vw, 36px);
}
.unique__text strong { color: var(--ink); font-weight: 800; }
.unique__signature {
  font-family: var(--font-display);
  font-size: clamp(1.7rem, 4vw, 2.3rem);
  color: var(--peach);
  line-height: 1.25;
  margin-top: 24px;
}
.cta-inline { margin-top: clamp(30px, 5vw, 42px); }

/* =============================================================
   RÉASSURANCE
   ============================================================= */
.section--reassurance { background: var(--cream-deep); }
.reassure {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
}
.reassure__item { text-align: center; }
.reassure__icon {
  width: 70px; height: 70px;
  margin: 0 auto 18px;
  display: grid; place-items: center;
  background: var(--white);
  color: var(--peach);
  border-radius: 50%;
  box-shadow: var(--shadow-sm);
}
.reassure__icon svg { width: 38px; height: 38px; }
.reassure__item:nth-child(2) .reassure__icon { color: var(--sage); }
.reassure__item:nth-child(3) .reassure__icon { color: var(--blue-powder); }
.reassure__item h3 { font-size: 1.2rem; font-weight: 800; margin-bottom: 8px; }
.reassure__item p { color: var(--ink-soft); font-size: 1rem; max-width: 30ch; margin-inline: auto; }

/* =============================================================
   CTA FINAL + FORMULAIRE
   ============================================================= */
.section--cta {
  position: relative;
  background:
    radial-gradient(100% 100% at 50% 0%, var(--blue-soft) 0%, transparent 60%),
    var(--cream);
  overflow: hidden;
}
.cta-block__blob {
  position: absolute;
  width: 420px; height: 420px;
  background: var(--peach-soft);
  border-radius: 50%;
  filter: blur(70px);
  opacity: .4;
  bottom: -160px; right: -120px;
  pointer-events: none;
}
.cta-block {
  position: relative;
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: clamp(34px, 5vw, 56px);
  box-shadow: var(--shadow-md);
  text-align: center;
}
.cta-block__title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2.2rem, 5.5vw, 3.2rem);
  line-height: 1.05;
  margin-bottom: 14px;
}
.cta-block__lead {
  color: var(--ink-soft);
  max-width: 46ch;
  margin: 0 auto 32px;
}

/* ---------- Formulaire ---------- */
.form { text-align: left; }
.form__row { margin-bottom: 20px; }
.form__label {
  display: block;
  font-weight: 700;
  font-size: .98rem;
  margin-bottom: 8px;
  color: var(--ink);
}
.form__optional { font-weight: 400; color: var(--ink-soft); font-size: .9rem; }

.form__input {
  width: 100%;
  font-family: var(--font-body);
  font-size: 1.05rem;
  color: var(--ink);
  background: var(--cream);
  border: 2px solid var(--cream-deep);
  border-radius: 14px;
  padding: 15px 18px;
  transition: border-color .2s ease, box-shadow .2s ease, background-color .2s ease;
}
.form__input::placeholder { color: #b3a99c; }
.form__input:focus {
  outline: none;
  background: var(--white);
  border-color: var(--sage);
  box-shadow: 0 0 0 4px rgba(157, 179, 154, 0.18);
}
.form__select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%236E6256' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 18px center;
  padding-right: 46px;
  cursor: pointer;
}
.form .btn--lg { width: 100%; margin-top: 6px; }
.form__reassure {
  text-align: center;
  font-size: .9rem;
  color: var(--ink-soft);
  margin-top: 16px;
}

/* honeypot */
.hidden { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* =============================================================
   FOOTER
   ============================================================= */
.footer {
  background: var(--ink);
  color: var(--cream);
  padding-block: 48px;
  text-align: center;
}
.footer__brand {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 600;
  margin-bottom: 8px;
}
.footer__legal { color: rgba(251, 244, 234, 0.6); font-size: .92rem; margin-bottom: 6px; }
.footer__contact a { color: var(--peach-soft); text-decoration: none; font-weight: 600; }
.footer__contact a:hover { text-decoration: underline; }

/* =============================================================
   ANIMATIONS AU SCROLL
   ============================================================= */
.reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity .7s ease, transform .7s ease;
}
.reveal.is-visible { opacity: 1; transform: none; }

/* délai en cascade pour les grilles */
.steps .reveal:nth-child(2),
.reassure .reveal:nth-child(2) { transition-delay: .12s; }
.steps .reveal:nth-child(3),
.reassure .reveal:nth-child(3) { transition-delay: .24s; }

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .hero__media img { animation: none; }
  html { scroll-behavior: auto; }
}

/* =============================================================
   RESPONSIVE — mobile first ajustements
   ============================================================= */
/* HERO empilé : l'image devient une bannière, le texte passe dessous sur
   fond crème — lisibilité parfaite sans voile sur mobile/petite tablette. */
@media (max-width: 760px) {
  .hero__inner { grid-template-areas: "media" "content"; }
  .hero__media { grid-area: media; }
  .hero__media img {
    height: auto;
    aspect-ratio: 1408 / 768;
    object-position: center;
  }
  .hero__content {
    grid-area: content;
    align-self: start;
    justify-self: stretch;
    text-align: center;
    padding-block: clamp(28px, 6vw, 40px) 8px;
  }
  .hero__panel {
    max-width: none;
    background: transparent;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
    border: none;
    box-shadow: none;
    padding: 0;
  }
  .hero__subtitle { margin-inline: auto; }
}

@media (max-width: 900px) {
  .showcase { grid-template-columns: 1fr; }
  .showcase__media { order: -1; max-width: 440px; margin-inline: auto; }
  .section__title--left { text-align: center; }
  .showcase__text { text-align: center; }
  .showcase__text p { margin-inline: auto; max-width: 50ch; }

  /* section "contenu" : on garde le titre + la liste au-dessus du visuel */
  .showcase--reverse .showcase__media { order: 0; }
  .showcase--reverse .showcase__text { order: 0; }
  .specs--inline { max-width: 600px; margin-inline: auto; text-align: left; }
}

@media (max-width: 680px) {
  .steps, .reassure { grid-template-columns: 1fr; gap: 28px; }
  .steps { margin-top: 8px; }
  .card { padding: 36px 24px 30px; }
  .btn--lg { width: 100%; }            /* CTA pleine largeur sur mobile */
  .hero__title { font-size: clamp(2rem, 8.5vw, 3rem); }
}
