/* Tokens repris du Design System (DESIGN-descript.md).
   Brett → Fraunces, Booton → Inter (substituts documentés). */
:root {
  --primary: #f73b3b;
  --primary-press: #e02f2f;
  --primary-soft: #ff5340;
  --ink: #1a1a1a;
  --body: #26171d;
  --canvas: #fff7fa;
  --surface-dark: #390a1a;
  --surface-warm: #fff8f4;
  --surface-warm-alt: #faf8f7;
  --surface-muted: #f1eaed;
  --hairline: #d1c7cb;
  --muted: #8b6f7a;
  --muted-strong: #583f4a;
  --on-primary: #ffffff;
  --on-dark: #fff8f4;
  --on-dark-soft: #e8ccd5;
  --white: #ffffff;

  --serif: "Fraunces", Georgia, serif;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  --r-sm: 4px;
  --r-md: 8px;
  --r-lg: 12px;
  --r-pill: 100px;

  --gutter: 16px;
  --shadow: rgba(0, 0, 0, 0.16) 0 2px 4px 0;
  --ease: cubic-bezier(.2, .7, .2, 1);
  --ease-out: cubic-bezier(.16, 1, .3, 1);
  --fast: .18s;
  --mid: .45s;
}

/* Police du logo (Nunito Black, licence OFL, hébergée sur le site) */
@font-face {
  font-family: "Nunito";
  font-weight: 900;
  font-display: swap;
  src: url("../assets/fonts/nunito-900.woff2") format("woff2");
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }

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

body {
  margin: 0;
  background: var(--canvas);
  color: var(--body);
  font: 600 17px/1.5 var(--sans);
  -webkit-font-smoothing: antialiased;
}
body.flow-open { overflow: hidden; }

img { display: block; max-width: 100%; }
button { font: inherit; color: inherit; }
a { color: inherit; }

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

h1, h2, .screen__title, .section__title, .final__title { text-wrap: balance; }

.visually-hidden {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}

:focus-visible { outline: 3px solid var(--primary-soft); outline-offset: 3px; }

/* ---------- Boutons ---------- */

.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 12px 22px;
  border: 0;
  border-radius: var(--r-md);
  font-weight: 700;
  font-size: 17px;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: transform var(--fast) var(--ease), background-color .2s, opacity .2s, box-shadow .2s;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
}
.btn:active { transform: scale(.97); }
.btn:disabled { opacity: .38; cursor: not-allowed; transform: none; }

.btn--primary { background: var(--primary); color: var(--on-primary); }
.btn--primary:active { background: var(--primary-press); }
.btn--ghost { background: var(--surface-muted); color: var(--ink); }
.btn--pill { min-height: 40px; padding: 8px 18px; font-size: 15px; background: var(--surface-muted); color: var(--ink); border-radius: var(--r-pill); }
.btn--big { min-height: 58px; padding: 16px 24px; font-size: 18px; }
.btn--block { width: 100%; }

@media (hover: hover) {
  .btn--primary:hover:not(:disabled) { background: var(--primary-press); box-shadow: 0 6px 18px rgba(247, 59, 59, .28); }
  .btn--ghost:hover { background: #e9dfe3; }
  .btn--pill:hover { background: #fff; }
}

.link-btn {
  display: inline-block;
  min-height: 44px;
  padding: 12px 4px;
  background: none;
  border: 0;
  color: var(--muted-strong);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
}
.link-btn--center { display: block; margin: 4px auto 0; text-align: center; }

/* ---------- Header ---------- */

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px var(--gutter);
  padding-top: max(8px, env(safe-area-inset-top));
  background: var(--surface-dark);
  color: var(--on-dark);
}
/* Logo : icône + « Armo » (clair sur le bandeau foncé) + « nik » (rouge) */
.logo { display: inline-flex; align-items: center; gap: 8px; text-decoration: none; -webkit-tap-highlight-color: transparent; }
.logo__icon { width: 32px; height: 32px; margin-top: -3px; }
.logo__text { font: 900 25px/1 "Nunito", var(--sans); letter-spacing: -.01em; color: var(--on-dark); }
.logo__accent { color: #ff5a4a; }
.topbar .btn--pill { white-space: nowrap; }
/* Petits écrans : logo et bouton d'en-tête un peu plus compacts pour tenir sur une ligne */
@media (max-width: 420px) {
  .logo { gap: 6px; }
  .logo__icon { width: 26px; height: 26px; }
  .logo__text { font-size: 21px; }
  .topbar .btn--pill { padding: 8px 14px; font-size: 14px; }
}
@media (max-width: 340px) {
  .logo__text { font-size: 19px; }
  .topbar .btn--pill { padding: 8px 11px; font-size: 13px; }
}
/* Boutons principaux : le texte « … gratuitement » tient sur une ligne dès 340 px */
@media (max-width: 480px) {
  .btn--big { padding-left: 12px; padding-right: 12px; font-size: clamp(15px, 4.6vw, 18px); }
}

/* ---------- Bandes & titres ---------- */

.band-dark { background: var(--surface-dark); color: var(--on-dark); }

.eyebrow {
  margin: 0 0 10px;
  font-family: var(--serif);
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--primary-soft);
}
.band-dark .eyebrow { color: #ff8a7a; }

.section { padding: 56px 0; }
.section--warm { background: var(--surface-warm); }

.section__title {
  margin: 0 0 24px;
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(30px, 8vw, 46px);
  line-height: 1.08;
  letter-spacing: -.015em;
  color: var(--ink);
}
.band-dark .section__title { color: var(--on-dark); }

/* ---------- Apparition au défilement ---------- */

.appear {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity .55s var(--ease-out) var(--delay, 0ms), transform .55s var(--ease-out) var(--delay, 0ms);
}
.appear.is-visible { opacity: 1; transform: none; }

/* ---------- Hero ---------- */

.hero { padding: 18px 0 28px; overflow: hidden; }
.hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
  grid-template-areas: "text" "demo" "cta";
}
.hero__text { grid-area: text; }
.hero__demo { grid-area: demo; margin: 0; }
.hero__cta { grid-area: cta; }

.hero__title {
  margin: 0 0 8px;
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(32px, 9vw, 64px);
  line-height: 1.04;
  letter-spacing: -.02em;
  animation: rise .7s var(--ease-out) both;
}
.hero__lead {
  margin: 0;
  font-size: 17px;
  font-weight: 500;
  line-height: 1.4;
  color: var(--on-dark-soft);
  max-width: 34ch;
  animation: rise .7s var(--ease-out) .08s both;
}
.hero__demo { animation: rise .8s var(--ease-out) .14s both; }
.hero__cta { animation: rise .7s var(--ease-out) .22s both; }
.hero__cta .btn { width: 100%; }
.hero__note { margin: 10px 0 0; font-size: 14px; font-weight: 500; color: #d9b9c3; text-align: center; }

@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }

/* Le hero tient dans l'écran du téléphone : l'image s'adapte à la hauteur restante. */
/* Hauteur fixe pour que rien ne bouge quand l'exemple change ;
   l'avant et l'après sont recadrés exactement de la même façon. */
.compare--hero {
  width: 100%;
  height: clamp(280px, 100svh - 400px, 520px);
  margin: 0 auto;
}
.compare.compare--hero img { object-fit: cover; object-position: center 30%; }

@media (min-width: 860px) {
  .hero { padding: 64px 0 80px; }
  .hero__grid {
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
    grid-template-areas: "text demo" "cta demo";
    grid-template-rows: auto 1fr;
    column-gap: 56px;
    row-gap: 28px;
  }
  .hero__text { align-self: end; }
  .hero__lead { font-size: 20px; }
  .hero__cta .btn { width: auto; }
  .hero__note { text-align: left; }
  .hero__demo { width: 100%; max-width: 440px; justify-self: end; }
  .compare--hero { height: 540px; }
}

/* Onglets des exemples du hero */
.switch {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
  margin-top: 10px;
}
.switch__tab {
  position: relative;
  min-height: 40px;
  padding: 8px 4px 10px;
  border: 0;
  border-radius: var(--r-md);
  background: rgba(255, 248, 244, .08);
  color: var(--on-dark-soft);
  font-size: 13px;
  font-weight: 600;
  line-height: 1.15;
  cursor: pointer;
  overflow: hidden;
  transition: background-color .25s, color .25s, transform var(--fast) var(--ease);
  -webkit-tap-highlight-color: transparent;
}
.switch__tab:active { transform: scale(.96); }
.switch__tab[aria-pressed="true"] { background: var(--on-dark); color: var(--surface-dark); }
/* Fine barre qui montre quand l'exemple suivant arrive */
.switch__tab i {
  position: absolute;
  left: 0; bottom: 0;
  height: 3px;
  width: 100%;
  background: var(--primary);
  transform: scaleX(0);
  transform-origin: left;
}
.switch__tab.is-timing i { animation: timing 5.2s linear forwards; }
.switch.is-manual .switch__tab i { display: none; }
@keyframes timing { to { transform: scaleX(1); } }
@media (hover: hover) { .switch__tab:hover:not([aria-pressed="true"]) { background: rgba(255, 248, 244, .16); } }

/* ---------- Comparateur avant / après ---------- */

.compare {
  --pos: 50%;
  position: relative;
  aspect-ratio: 4 / 5;
  border-radius: var(--r-lg);
  overflow: hidden;
  background: var(--surface-muted);
  box-shadow: var(--shadow);
  touch-action: pan-y pinch-zoom;
  user-select: none;
  -webkit-user-select: none;
  -webkit-touch-callout: none;
  cursor: ew-resize;
  isolation: isolate;
}
.compare img {
  width: 100%;
  height: 100%;
  object-fit: contain; /* jamais déformée ; le cadre prend le ratio de l'image */
  pointer-events: none;
  -webkit-user-drag: none;
}
.compare__after, .compare__before { transition: opacity .2s; }
.compare__after { position: absolute; inset: 0; }
.compare__before { position: absolute; inset: 0; clip-path: inset(0 calc(100% - var(--pos)) 0 0); }
.compare.is-swapping .compare__after,
.compare.is-swapping .compare__before { opacity: 0; }

.compare__line {
  position: absolute;
  top: 0; bottom: 0;
  left: var(--pos);
  width: 3px;
  margin-left: -1.5px;
  background: var(--white);
  box-shadow: 0 0 0 1px rgba(0, 0, 0, .08);
  z-index: 2;
}
.compare__handle {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 48px;
  height: 48px;
  margin: -24px 0 0 -24px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: var(--white);
  box-shadow: 0 2px 10px rgba(0, 0, 0, .25);
  cursor: ew-resize;
  transition: transform .2s var(--ease);
}
/* zone tactile plus large que le rond visible */
.compare__handle::after { content: ""; position: absolute; inset: -14px; }
.compare__handle::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    no-repeat center / 22px 14px
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 22 14'%3E%3Cpath d='M7 1L1 7l6 6M15 1l6 6-6 6' fill='none' stroke='%23390a1a' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
}
.compare.is-dragging .compare__handle { transform: scale(1.12); }
.compare.is-nudging .compare__handle { animation: nudge 1.1s var(--ease) 2; }
@keyframes nudge {
  0%, 100% { transform: translateX(0); }
  30% { transform: translateX(-7px); }
  65% { transform: translateX(7px); }
}

.tag {
  position: absolute;
  top: 10px;
  z-index: 3;
  padding: 4px 10px;
  border-radius: var(--r-pill);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .02em;
  pointer-events: none;
  transition: opacity .25s;
}
.tag--before { left: 10px; background: rgba(26, 26, 26, .72); color: var(--white); }
.tag--after { right: 10px; background: var(--white); color: var(--ink); }
.compare.hide-before .tag--before,
.compare.hide-after .tag--after { opacity: 0; }

.hint { margin: 10px 0 0; text-align: center; font-size: 14px; font-weight: 500; color: var(--muted); }

/* ---------- Les 4 transformations ---------- */

.options {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
@media (min-width: 860px) { .options { grid-template-columns: repeat(4, 1fr); gap: 20px; } }

.option {
  display: flex;
  flex-direction: column;
  width: 100%;
  height: 100%;
  padding: 0;
  border: 0;
  border-radius: var(--r-lg);
  background: var(--surface-warm);
  text-align: left;
  cursor: pointer;
  overflow: hidden;
  box-shadow: inset 0 0 0 1px #f0e2e6;
  transition: transform .2s var(--ease), box-shadow .25s;
  -webkit-tap-highlight-color: transparent;
}
.option:active { transform: scale(.97); box-shadow: inset 0 0 0 2px var(--primary); }

/* Vignettes : recadrées au centre (jamais déformées). */
.flip { position: relative; display: block; aspect-ratio: 4 / 5; overflow: hidden; }
.flip img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .5s var(--ease-out); }
.flip__after { clip-path: inset(0 0 0 100%); transition: clip-path .9s var(--ease), transform .5s var(--ease-out); }
.flip.is-after .flip__after { clip-path: inset(0 0 0 0); }
.flip .tag { top: 8px; font-size: 12px; padding: 3px 8px; }
.flip .tag--before { left: 8px; }
.flip .tag--after { right: 8px; opacity: 0; }
.flip.is-after .tag--before { opacity: 0; }
.flip.is-after .tag--after { opacity: 1; }

.option__body { display: flex; flex-direction: column; gap: 4px; padding: 12px 12px 14px; flex: 1; }
.option__title { font-size: 17px; font-weight: 700; line-height: 1.25; color: var(--ink); }
.option__text { font-size: 14px; font-weight: 500; line-height: 1.4; color: var(--muted-strong); }
.option__go { margin-top: auto; padding-top: 8px; font-size: 15px; font-weight: 700; color: var(--primary); }
.option__go .arrow { display: inline-block; transition: transform .25s var(--ease); }

@media (hover: hover) {
  .option:hover { transform: translateY(-4px); box-shadow: inset 0 0 0 1px #ead6dc, 0 10px 24px rgba(57, 10, 26, .1); }
  .option:hover .flip img { transform: scale(1.03); }
  .option:hover .arrow { transform: translateX(4px); }
}

/* ---------- Comment ça marche ---------- */

.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
@media (min-width: 860px) { .steps { grid-template-columns: repeat(3, 1fr); gap: 20px; } }

.step {
  display: grid;
  grid-template-columns: 52px 1fr;
  column-gap: 14px;
  align-items: center;
  padding: 18px;
  border-radius: var(--r-lg);
  background: var(--white);
}
.step__num {
  grid-row: span 2;
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--surface-dark);
  color: var(--on-dark);
  font-family: var(--serif);
  font-size: 26px;
}
.step.is-visible .step__num { animation: pop .5s var(--ease-out) calc(var(--delay, 0ms) + 120ms) both; }
@keyframes pop { from { transform: scale(.6); opacity: 0; } to { transform: none; opacity: 1; } }
.step__title { font-family: var(--serif); font-size: 24px; font-weight: 400; line-height: 1.15; color: var(--ink); }
.step__text { font-size: 15px; font-weight: 500; color: var(--muted-strong); }

/* ---------- Galerie ---------- */

.gallery {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 80%;
  gap: 14px;
  align-items: start;
  padding: 0 var(--gutter) 6px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-padding: 0 var(--gutter);
  scrollbar-width: none;
  overscroll-behavior-x: contain;
}
.gallery::-webkit-scrollbar { display: none; }
.gallery__item { margin: 0; min-width: 0; scroll-snap-align: start; }
.gallery__item figcaption { margin-top: 12px; font-size: 16px; color: var(--on-dark-soft); }

@media (min-width: 860px) {
  .gallery {
    grid-auto-flow: row;
    grid-template-columns: repeat(3, 1fr);
    max-width: 1080px;
    margin: 0 auto;
    gap: 24px;
    overflow: visible;
  }
}

/* ---------- CTA final & pied de page ---------- */

.final { padding: 72px 0 64px; }
.final__inner { text-align: center; display: grid; justify-items: center; gap: 20px; }
.final__title {
  margin: 0;
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(34px, 10vw, 56px);
  line-height: 1.05;
  color: var(--ink);
}
.final .btn { width: 100%; max-width: 380px; }
.final__note { margin: 0; font-size: 15px; font-weight: 500; color: var(--muted-strong); }

.footer {
  padding: 24px 0 calc(96px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--hairline);
  font-size: 14px;
  font-weight: 500;
  color: var(--muted-strong);
  text-align: center;
}
.footer p { margin: 4px 0; }
.footer__brand { display: inline-flex; align-items: center; gap: 6px; margin-bottom: 8px !important; font: 900 17px/1 "Nunito", var(--sans); color: var(--surface-dark); }
.footer__brand .logo__accent { color: var(--primary); }
.illustrative { color: var(--muted); }
.footer__social { margin: 6px 0 14px !important; }
.fb-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  padding: 8px 16px;
  border-radius: var(--r-pill);
  background: var(--white);
  box-shadow: inset 0 0 0 1px var(--hairline);
  color: var(--ink);
  font-size: 15px;
  font-weight: 700;
  text-decoration: none;
  transition: transform var(--fast) var(--ease), box-shadow .2s;
}
.fb-link:active { transform: scale(.97); }
@media (hover: hover) { .fb-link:hover { box-shadow: inset 0 0 0 1px #0866FF; } }
@media (min-width: 860px) { .footer { padding-bottom: 32px; } }

/* ---------- Bouton fixe (mobile) ---------- */

.dock {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  z-index: 20;
  padding: 12px var(--gutter) calc(12px + env(safe-area-inset-bottom));
  background: linear-gradient(to top, var(--canvas) 70%, rgba(255, 247, 250, 0));
  transform: translateY(110%);
  transition: transform .35s var(--ease-out);
  pointer-events: none;
}
.dock.is-shown { transform: none; pointer-events: auto; }
@media (min-width: 860px) { .dock { display: none; } }

/* =====================================================================
   PARCOURS
   ===================================================================== */

.flow {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: 100dvh;
  z-index: 50;
  display: flex;
  flex-direction: column;
  background: var(--canvas);
  animation: flow-in .35s var(--ease-out);
}
@keyframes flow-in { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: none; } }

.flow__bar {
  flex: none;
  display: grid;
  grid-template-columns: 48px 1fr 48px;
  align-items: center;
  padding: 4px 6px;
  padding-top: max(4px, env(safe-area-inset-top));
}
.icon-btn {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  transition: background-color .2s;
}
.icon-btn:active { background: var(--surface-muted); }
.flow[data-screen="choose"] [data-back] { visibility: hidden; }
.flow[data-screen="loading"] [data-back] { visibility: hidden; }

.flow__dots { display: flex; justify-content: center; gap: 6px; margin: 0; padding: 0; list-style: none; }
.flow__dots li {
  width: 28px;
  height: 4px;
  border-radius: 2px;
  background: var(--hairline);
  overflow: hidden;
  position: relative;
}
.flow__dots li::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--primary);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .4s var(--ease-out);
}
.flow__dots li.is-on::after { transform: none; }

.demo-badge {
  flex: none;
  margin: 0 var(--gutter) 6px;
  padding: 6px 12px;
  border-radius: var(--r-sm);
  background: #fff1c2;
  color: #5a4300;
  font-size: 13px;
  text-align: center;
}

/* Chaque écran : contenu qui défile + actions collées en bas, à portée de pouce. */
.screen {
  display: none;
  flex: 1;
  min-height: 0;
  flex-direction: column;
  width: 100%;
  max-width: 480px;
  margin: 0 auto;
}
.screen.is-active { display: flex; }
.screen__body {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 8px var(--gutter) 16px;
  animation: screen-in .35s var(--ease-out);
}
.screen.from-left .screen__body { animation-name: screen-in-back; }
.screen--center .screen__body { text-align: center; display: flex; flex-direction: column; justify-content: center; }

@keyframes screen-in { from { opacity: 0; transform: translateX(28px); } to { opacity: 1; transform: none; } }
@keyframes screen-in-back { from { opacity: 0; transform: translateX(-28px); } to { opacity: 1; transform: none; } }

.actions {
  flex: none;
  display: grid;
  gap: 8px;
  padding: 10px var(--gutter) calc(12px + env(safe-area-inset-bottom));
  background: var(--canvas);
  box-shadow: 0 -1px 0 rgba(57, 10, 26, .06);
  animation: rise .4s var(--ease-out) .06s both;
}
.actions > div { display: grid; gap: 8px; }
.actions--row { grid-template-columns: 1fr 1fr; }
.actions--row .span-all { grid-column: 1 / -1; }
.actions--row .result__love { grid-column: 1 / -1; }

.screen__title {
  margin: 4px 0 6px;
  font-family: var(--serif);
  font-weight: 400;
  font-size: 30px;
  line-height: 1.12;
  color: var(--ink);
  outline: none;
}
.screen__sub { margin: 0 0 16px; font-size: 16px; font-weight: 500; color: var(--muted-strong); }

.inline-error {
  margin: 0 0 12px;
  padding: 10px 12px;
  border-radius: var(--r-sm);
  background: #ffe3df;
  color: #8a1b12;
  font-size: 15px;
  animation: shake .35s var(--ease);
}
@keyframes shake { 25% { transform: translateX(-4px); } 75% { transform: translateX(4px); } }

/* 1. Choix */
.pick { display: grid; gap: 10px; margin-top: 14px; }
.pick__item {
  display: grid;
  grid-template-columns: 76px 1fr 20px;
  gap: 14px;
  align-items: center;
  width: 100%;
  padding: 10px 12px 10px 10px;
  border: 0;
  border-radius: var(--r-lg);
  background: var(--white);
  box-shadow: inset 0 0 0 1px #efe3e7;
  text-align: left;
  cursor: pointer;
  transition: transform var(--fast) var(--ease), box-shadow .2s;
  -webkit-tap-highlight-color: transparent;
}
.pick__item:active, .pick__item.is-picked { transform: scale(.98); box-shadow: inset 0 0 0 2px var(--primary); }
.pick__item img { width: 76px; height: 95px; object-fit: cover; border-radius: var(--r-md); }
.pick__item span { font-size: 15px; font-weight: 500; color: var(--muted-strong); line-height: 1.35; }
.pick__item strong { display: block; margin-bottom: 3px; font-size: 18px; font-weight: 700; color: var(--ink); line-height: 1.25; }
.pick__chev { color: var(--muted); transition: transform .2s var(--ease); }
.screen.is-active .pick__item { animation: rise .4s var(--ease-out) both; }
.pick__item:nth-child(2) { animation-delay: .04s !important; }
.pick__item:nth-child(3) { animation-delay: .08s !important; }
.pick__item:nth-child(4) { animation-delay: .12s !important; }
@media (hover: hover) {
  .pick__item:hover { box-shadow: inset 0 0 0 1px var(--hairline), 0 6px 16px rgba(57, 10, 26, .08); }
  .pick__item:hover .pick__chev { transform: translateX(3px); }
}

/* 2. Photo */
.drop {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 240px;
  height: calc(100% - 90px);
  max-height: 60vh;
  border: 2px dashed var(--hairline);
  border-radius: var(--r-lg);
  background: var(--white);
  color: var(--muted);
  cursor: pointer;
  overflow: hidden;
  transition: border-color .2s, background-color .2s;
}
.drop:active { background: var(--surface-warm); }
.drop__empty { display: grid; justify-items: center; gap: 10px; font-size: 16px; font-weight: 600; }
.drop.has-photo { border-style: solid; border-color: transparent; background: var(--surface-muted); }
.drop__img { width: 100%; height: 100%; object-fit: contain; }
.drop__img.is-new { animation: develop .7s var(--ease-out); }
@keyframes develop {
  from { opacity: 0; transform: scale(.94); filter: blur(6px); }
  to { opacity: 1; transform: none; filter: none; }
}
.drop.is-loading::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, .6), transparent);
  animation: sweep 1s linear infinite;
}
@keyframes sweep { from { transform: translateX(-100%); } to { transform: translateX(100%); } }
.drop__ok {
  position: absolute;
  bottom: 12px;
  left: 50%;
  padding: 6px 14px;
  border-radius: var(--r-pill);
  background: var(--surface-dark);
  color: var(--on-dark);
  font-size: 14px;
  transform: translateX(-50%);
  opacity: 0;
}
.drop__ok.is-new { animation: ok 2.2s var(--ease-out) both; }
@keyframes ok {
  0% { opacity: 0; transform: translate(-50%, 10px); }
  15%, 75% { opacity: 1; transform: translate(-50%, 0); }
  100% { opacity: 0; transform: translate(-50%, 0); }
}

/* 3. Demande */
.field { display: block; margin-bottom: 14px; }
.field__label { display: block; margin-bottom: 8px; font-size: 15px; font-weight: 600; color: var(--muted-strong); }
.field__input {
  display: block;
  width: 100%;
  min-height: 64px;
  padding: 14px 16px;
  border: 2px solid var(--hairline);
  border-radius: var(--r-md);
  background: var(--white);
  font: 600 18px/1.4 var(--sans); /* ≥ 16px : pas de zoom auto sur iPhone */
  color: var(--ink);
  resize: none;
  overflow: hidden;
  transition: border-color .2s, box-shadow .2s;
}
.field__input:focus { outline: none; border-color: var(--surface-dark); box-shadow: 0 0 0 4px rgba(57, 10, 26, .08); }
.field__input::placeholder { color: #a8909a; font-weight: 500; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 22px; }
.chip {
  min-height: 44px;
  padding: 10px 16px;
  border: 1px solid var(--hairline);
  border-radius: var(--r-pill);
  background: transparent;
  font-size: 15px;
  cursor: pointer;
  transition: background-color .2s, color .2s, border-color .2s, transform var(--fast) var(--ease);
  -webkit-tap-highlight-color: transparent;
}
.chip:active { transform: scale(.95); }
.chip.is-on { background: var(--surface-dark); border-color: var(--surface-dark); color: var(--on-dark); }
.chip.is-tapped { animation: pop .3s var(--ease-out); }
@media (hover: hover) { .chip:hover:not(.is-on) { border-color: var(--muted); } }

.ref { margin-top: 6px; }
.ref__q { margin: 0 0 8px; font-size: 16px; color: var(--ink); }
.ref__box {
  display: grid;
  place-items: center;
  gap: 10px;
  min-height: 72px;
  padding: 12px;
  border: 2px dashed var(--hairline);
  border-radius: var(--r-lg);
  background: var(--white);
  color: var(--ink);
  font-weight: 700;
  cursor: pointer;
}
.ref__box.has-image { border-style: solid; }
.ref__img { max-height: 180px; border-radius: var(--r-md); animation: develop .6s var(--ease-out); }

/* 4. Confirmation */
.recap { margin: 12px 0 0; border-radius: var(--r-lg); background: var(--white); box-shadow: var(--shadow); overflow: hidden; }
.recap__photo { position: relative; background: var(--surface-muted); view-transition-name: photo; }
.recap__img { width: 100%; max-height: 44vh; object-fit: contain; }
.recap__change {
  position: absolute;
  right: 10px;
  bottom: 10px;
  min-height: 36px;
  padding: 6px 12px;
  border: 0;
  border-radius: var(--r-pill);
  background: rgba(255, 255, 255, .92);
  font-size: 14px;
  cursor: pointer;
}
.recap__body { padding: 14px 16px 6px; }
.recap__type { margin: 0; font-size: 14px; font-weight: 600; text-transform: uppercase; letter-spacing: .04em; color: var(--primary-soft); }
.recap__ask { margin: 6px 0 0; font-family: var(--serif); font-size: 22px; font-weight: 400; line-height: 1.25; color: var(--ink); }
.recap__more { margin: 6px 0 0; font-size: 16px; font-weight: 500; color: var(--muted-strong); }
.recap__ref { max-height: 120px; margin-top: 10px; border-radius: var(--r-md); }

/* 5. Création */
.working {
  position: relative;
  width: min(66vw, 280px);
  margin: 0 auto 24px;
  border-radius: var(--r-lg);
  overflow: hidden;
  background: var(--surface-muted);
  view-transition-name: photo;
}
.working__img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; animation: breathe 3s ease-in-out infinite; }
@keyframes breathe { 50% { transform: scale(1.025); } }
/* Une lumière douce passe sur la photo : quelque chose se passe. */
.working__light {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 35%, rgba(255, 248, 244, .55) 50%, transparent 65%);
  background-size: 100% 260%;
  animation: light 2.6s ease-in-out infinite;
}
@keyframes light { from { background-position: 0 100%; } to { background-position: 0 0; } }

.working__msg {
  min-height: 1.4em;
  margin: 0 0 16px;
  font-family: var(--serif);
  font-size: 26px;
  font-weight: 400;
  color: var(--ink);
}
.working__msg.is-in { animation: rise .5s var(--ease-out); }

/* Barre sans pourcentage : on ne promet pas de durée. */
.working__bar { display: block; width: 160px; height: 4px; margin: 0 auto; border-radius: 2px; background: var(--surface-muted); overflow: hidden; }
.working__bar span { display: block; width: 40%; height: 100%; border-radius: 2px; background: var(--primary); animation: indeterminate 1.4s ease-in-out infinite; }
@keyframes indeterminate { from { transform: translateX(-100%); } to { transform: translateX(250%); } }

/* Erreur */
.error__icon {
  display: grid;
  place-items: center;
  width: 64px;
  height: 64px;
  margin: 0 auto 10px;
  border-radius: 50%;
  background: #ffe3df;
  color: #b3261e;
  font-family: var(--serif);
  font-size: 34px;
  animation: pop .45s var(--ease-out);
}

/* Photo offerte déjà utilisée */
.used__icon { margin: 0 0 8px; font-size: 44px; animation: pop .45s var(--ease-out); }
.used__love { margin-top: 18px; }

/* 6. Résultat */
.compare--result { width: min(100%, 56dvh * var(--ratio, .8)); margin: 10px auto 0; view-transition-name: photo; }
.result__more { margin-top: 18px; }
.result-in .result__more,
.result-in [data-result-hint] { animation: rise .5s var(--ease-out) 1.4s both; }
.result-in .screen__title { animation: rise .5s var(--ease-out) both; }

.result__love { text-align: center; font-size: 14px; font-weight: 500; line-height: 1.4; color: var(--muted-strong); }
.result__love p { margin: 0 0 4px; }
.result__love strong { display: block; font-size: 15px; color: var(--ink); }
.result__fb {
  display: inline-block;
  padding: 6px 4px;
  font-weight: 700;
  color: var(--surface-dark);
  text-decoration: underline;
  text-underline-offset: 3px;
}

[data-download].is-done { background: var(--surface-dark); }
[data-download].is-done span { display: none; }
[data-download].is-done::after { content: "✓ Enregistrée"; animation: pop .3s var(--ease-out); }

.card-soft { display: grid; gap: 10px; margin-bottom: 12px; padding: 16px; border-radius: var(--r-lg); background: var(--surface-warm); }
.card-soft__title { margin: 0; font-size: 17px; font-weight: 700; color: var(--ink); }
.consent__btns { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.consent__done { margin: 0; color: var(--muted-strong); font-weight: 500; animation: rise .35s var(--ease-out); }

/* Fondu enchaîné natif entre la photo de la confirmation, l'attente et le résultat */
::view-transition-group(photo) { animation-duration: .5s; animation-timing-function: var(--ease-out); }
::view-transition-old(root), ::view-transition-new(root) { animation-duration: .25s; }

/* Toast */
.toast {
  position: fixed;
  left: 50%;
  bottom: calc(96px + env(safe-area-inset-bottom));
  z-index: 100;
  transform: translateX(-50%);
  padding: 12px 20px;
  border-radius: var(--r-pill);
  background: var(--surface-dark);
  color: var(--on-dark);
  font-size: 16px;
  white-space: nowrap;
  box-shadow: 0 6px 20px rgba(57, 10, 26, .3);
}
.toast.is-in { animation: toast-in .35s var(--ease-out); }
.toast.is-out { opacity: 0; transition: opacity .25s; }
@keyframes toast-in { from { opacity: 0; transform: translate(-50%, 12px); } to { opacity: 1; transform: translate(-50%, 0); } }

/* ---------- Mouvement réduit ---------- */

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
    scroll-behavior: auto !important;
  }
  .flip__after { clip-path: none; opacity: 0; transition: opacity .3s !important; }
  .flip.is-after .flip__after { opacity: 1; }
  .working__light { display: none; }
}
