/* =============================================================
   Tokens
   ============================================================= */
:root {
  --paper: #f2eee5;
  --paper-2: #e9e3d6;
  --ink: #141210;
  --ink-2: #3a3530;
  --muted: #6b645b;
  --line: rgba(20, 18, 16, 0.14);
  --ember: #d9481f;
  --ticket: #fbf9f4;

  --serif: "Instrument Serif", "Times New Roman", serif;
  --sans: "Inter Tight", system-ui, -apple-system, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;

  --pad: clamp(1rem, 4vw, 3.5rem);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-io: cubic-bezier(0.65, 0, 0.35, 1);
}

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

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

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

::selection { background: var(--ink); color: var(--paper); }

a { color: inherit; text-decoration: none; }
img, svg { display: block; }
h1, h2, h3 { margin: 0; font-weight: 400; }
p { margin: 0; }
em { font-style: italic; }

.mono {
  font-family: var(--mono);
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

:focus-visible { outline: 2px solid var(--ember); outline-offset: 4px; border-radius: 2px; }

/* Grain texture */
.grain {
  position: fixed;
  inset: -50%;
  z-index: 100;
  pointer-events: none;
  opacity: 0.06;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grain 1.2s steps(6) infinite;
}
@keyframes grain {
  0% { transform: translate(0, 0); }
  20% { transform: translate(-3%, 2%); }
  40% { transform: translate(2%, -3%); }
  60% { transform: translate(-1%, 3%); }
  80% { transform: translate(3%, 1%); }
  100% { transform: translate(0, 0); }
}

/* Custom cursor (souris uniquement) */
.cursor { display: none; }
@media (pointer: fine) {
  .cursor {
    display: block;
    position: fixed;
    top: 0; left: 0;
    width: 10px; height: 10px;
    margin: -5px 0 0 -5px;
    border-radius: 50%;
    background: var(--ember);
    pointer-events: none;
    z-index: 200;
    transition: width .35s var(--ease), height .35s var(--ease), margin .35s var(--ease), background .35s, opacity .3s;
    mix-blend-mode: multiply;
    opacity: 0;
  }
  .cursor.is-visible { opacity: 1; }
  .cursor.is-hover {
    width: 56px; height: 56px; margin: -28px 0 0 -28px;
    background: rgba(217, 72, 31, 0.18);
  }
}

/* =============================================================
   Nav
   ============================================================= */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.1rem var(--pad);
  transition: transform .6s var(--ease), background .4s;
}
.nav.is-scrolled {
  background: rgba(242, 238, 229, 0.82);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.nav.is-hidden { transform: translateY(-100%); }

.nav__brand {
  display: inline-flex; align-items: center; gap: .55rem;
  font-weight: 600;
  letter-spacing: -0.01em;
}
.nav__brand .dot {
  width: 9px; height: 9px; border-radius: 50%;
  background: var(--ember);
  animation: pulse 2.4s var(--ease-io) infinite;
}
@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(.55); }
}

.nav__links { display: flex; gap: 2rem; font-size: .9375rem; }
.nav__links a { position: relative; padding: .2rem 0; }
.nav__links a::after {
  content: "";
  position: absolute; left: 0; right: 0; bottom: 0;
  height: 1px; background: currentColor;
  transform: scaleX(0); transform-origin: right;
  transition: transform .5s var(--ease);
}
.nav__links a:hover::after { transform: scaleX(1); transform-origin: left; }

.nav__status { display: flex; align-items: center; gap: .45rem; color: var(--muted); }
.status-dot { width: 6px; height: 6px; border-radius: 50%; background: #3f9b5a; }
.status-dot.is-closed { background: var(--muted); }

@media (max-width: 860px) {
  .nav__links { display: none; }
}

/* =============================================================
   Buttons
   ============================================================= */
.btn {
  --bg: var(--ink);
  position: relative;
  display: inline-flex; align-items: center; justify-content: center; gap: .75rem;
  padding: 1rem 1.6rem;
  border: 0;
  border-radius: 999px;
  background: var(--bg);
  color: var(--paper);
  font: 500 .9375rem/1 var(--sans);
  cursor: pointer;
  overflow: hidden;
  isolation: isolate;
  transition: transform .4s var(--ease);
}
.btn::before {
  content: "";
  position: absolute; inset: 0;
  z-index: -1;
  background: var(--ember);
  border-radius: inherit;
  transform: translateY(101%);
  transition: transform .55s var(--ease);
}
.btn:hover::before { transform: translateY(0); }
.btn svg {
  width: 18px; height: 18px;
  fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round;
  transition: transform .5s var(--ease);
}
.btn:hover svg { transform: translateX(4px); }
.btn[disabled] { opacity: .6; cursor: progress; }
.btn--full { width: 100%; }

/* =============================================================
   Hero
   ============================================================= */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex; flex-direction: column; justify-content: flex-end;
  padding: 7rem var(--pad) 3.5rem;
  overflow: hidden;
}

.eyebrow { color: var(--muted); margin-bottom: 1.5rem; }

.hero__title {
  font-family: var(--serif);
  font-size: clamp(3.4rem, 12.5vw, 13rem);
  line-height: .9;
  letter-spacing: -0.035em;
  position: relative;
  z-index: 2;
}
.hero__title .line { display: block; }
.hero__title em { color: var(--ember); }

.maison { position: relative; display: inline-block; }
/* La vapeur s'élève au-dessus du mot « maison » */
.steam {
  position: absolute;
  left: 18%;
  bottom: 78%;
  width: 46%;
  height: auto;
  overflow: visible;
}
.steam path {
  fill: none;
  stroke: var(--ink);
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-dasharray: 90;
  stroke-dashoffset: 90;
  opacity: 0;
  animation: steam 3.6s var(--ease-io) infinite;
  animation-delay: calc(1.8s + var(--d, 0s));
}
.steam path:nth-child(2) { --d: .5s; }
.steam path:nth-child(3) { --d: 1s; }
@keyframes steam {
  0% { stroke-dashoffset: 90; opacity: 0; transform: translateY(8px); }
  25% { opacity: .55; }
  60% { stroke-dashoffset: 0; opacity: .35; }
  100% { stroke-dashoffset: -90; opacity: 0; transform: translateY(-14px); }
}

/* Split characters */
.split .ch {
  display: inline-block;
  transform: translateY(140%) rotate(6deg);
  opacity: 0;
  animation: chIn 1.1s var(--ease) forwards;
  animation-delay: calc(.6s + var(--i) * 0.035s);
}
.split .sp { display: inline; }
.split .wd, .nw { display: inline-block; white-space: nowrap; }
.nw { display: inline; }
/* Masque des lignes animées : agrandi (marges négatives compensées) pour ne couper
   ni les accents (é, à), ni les jambages (p, q, j, ç), ni l'inclinaison de l'italique */
.hero__title .line,
.page-hero__title .line { overflow: hidden; padding: .14em .16em .26em; margin: -.14em -.16em -.26em; }
.hero__title .line:has(.maison) { overflow: visible; }
@keyframes chIn {
  to { transform: translateY(0) rotate(0); opacity: 1; }
}

.hero__bottom {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 2rem; flex-wrap: wrap;
  margin-top: 2.5rem;
  max-width: 62rem;
  position: relative; z-index: 2;
}
.hero__lead { max-width: 30rem; color: var(--ink-2); font-size: 1.125rem; }
.hero__lead strong { font-weight: 500; color: var(--ink); }

/* Printer + ticket */
.printer {
  position: absolute;
  top: 6.5rem;
  right: var(--pad);
  width: clamp(220px, 21vw, 290px);
  z-index: 1;
}
.printer__slot {
  height: 14px;
  border-radius: 8px;
  background: var(--ink);
  position: relative; z-index: 2;
  box-shadow: 0 4px 0 -2px rgba(0,0,0,.2);
}
.printer .ticket {
  margin: -6px 10px 0;
  transform-origin: top center;
  clip-path: inset(0 0 100% 0);
  animation: print 2.6s steps(26, end) .9s forwards, sway 6s var(--ease-io) 3.6s infinite;
}
@keyframes print { to { clip-path: inset(0 0 -20px 0); } }
@keyframes sway {
  0%, 100% { transform: rotate(0deg); }
  50% { transform: rotate(1.4deg); }
}

.ticket {
  position: relative;
  background: var(--ticket);
  color: var(--ink);
  font-family: var(--mono);
  font-size: .75rem;
  line-height: 1.5;
  box-shadow: 0 1px 0 var(--line), 0 18px 40px -22px rgba(20, 18, 16, .35);
}
.ticket::after {
  content: "";
  position: absolute; left: 0; right: 0; bottom: -10px;
  height: 10px;
  background:
    linear-gradient(135deg, var(--ticket) 50%, transparent 50%) 0 0 / 12px 10px repeat-x,
    linear-gradient(225deg, var(--ticket) 50%, transparent 50%) 0 0 / 12px 10px repeat-x;
}
.ticket__inner { padding: 1.25rem 1.1rem 1.4rem; position: relative; }
.t-row { display: flex; justify-content: space-between; gap: 1rem; text-transform: uppercase; }
.t-head { font-weight: 500; }
.t-dash { height: 1px; margin: .7rem 0; background: repeating-linear-gradient(90deg, var(--ink) 0 4px, transparent 4px 8px); opacity: .5; }
.t-note { display: block; color: var(--muted); margin-top: .2rem; }
.t-stamp {
  display: inline-block;
  margin-top: 1rem;
  padding: .3rem .7rem;
  border: 2px solid var(--ember);
  color: var(--ember);
  border-radius: 4px;
  font-weight: 500;
  letter-spacing: .2em;
  transform: rotate(-8deg) scale(1.6);
  opacity: 0;
}
.printer .t-stamp { animation: stamp .45s var(--ease) 3.7s forwards; }
@keyframes stamp {
  to { transform: rotate(-8deg) scale(1); opacity: .9; }
}

.scroll-hint {
  position: absolute; right: var(--pad); bottom: 3.5rem;
  display: flex; align-items: center; gap: .75rem;
  color: var(--muted);
  z-index: 2;
}
.scroll-hint__bar { width: 48px; height: 1px; background: var(--line); position: relative; overflow: hidden; }
.scroll-hint__bar::after {
  content: ""; position: absolute; inset: 0; background: var(--ink);
  animation: bar 2s var(--ease-io) infinite;
}
@keyframes bar {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}

/* Tablette & téléphone : le ticket s'imprime en haut de l'écran, au lieu de laisser un vide */
@media (max-width: 1000px) {
  .scroll-hint { display: none; }
  .printer {
    position: relative;
    top: auto; right: auto;
    order: -1;                 /* avant le titre */
    align-self: flex-end;      /* calé à droite, composition asymétrique */
    width: min(230px, 58vw);
    margin: 0 .25rem auto 0;   /* « auto » pousse le titre et le texte vers le bas */
    padding-bottom: 1.5rem;
    rotate: -2.5deg;
  }
  .printer .ticket { font-size: .66rem; }
}
@media (min-width: 641px) and (max-width: 1000px) and (min-height: 901px) {
  /* Tablettes : plus de place, ticket plus grand */
  .printer { width: 300px; margin-right: 1.5rem; }
  .printer .ticket { font-size: .78rem; }
}
@media (max-width: 1000px) and (max-height: 900px) {
  /* Téléphones : ticket compact pour que tout le haut de page tienne dans l'écran */
  .hero { padding-top: 5.25rem; padding-bottom: 2rem; }
  .printer { width: min(205px, 54vw); padding-bottom: 1rem; }
  .printer .ticket { font-size: .6rem; }
  .printer .ticket__inner { padding: 1rem .9rem 1.1rem; }
  .printer .t-note { display: none; }
  .printer .t-stamp { margin-top: .6rem; }
  .hero__bottom { margin-top: 1.75rem; }
}
@media (max-width: 1000px) and (max-height: 700px) {
  /* Très petits écrans (iPhone SE…) : le ticket laisse la place au titre */
  .printer { display: none; }
}

/* =============================================================
   Marquee
   ============================================================= */
.marquee {
  border-block: 1px solid var(--line);
  overflow: hidden;
  padding: 1.1rem 0;
  background: var(--ink);
  color: var(--paper);
}
.marquee__track {
  display: flex; width: max-content;
  font-family: var(--serif);
  font-size: clamp(1.6rem, 3.2vw, 2.6rem);
  line-height: 1;
  white-space: nowrap;
  animation: marquee var(--marquee-duration, 40s) linear infinite;
  will-change: transform;
}
/* L'espace après le dernier mot (padding) est inclus dans le groupe :
   les deux groupes font exactement la même largeur, la boucle est invisible */
.marquee__group { display: flex; flex: none; gap: 2.5rem; padding-right: 2.5rem; }
.marquee__track i { font-style: normal; color: var(--ember); font-size: .7em; align-self: center; }
@keyframes marquee { to { transform: translate3d(-50%, 0, 0); } }

/* =============================================================
   Sections
   ============================================================= */
.section { padding: clamp(5rem, 12vw, 10rem) var(--pad); position: relative; }

.section__label {
  display: flex; align-items: center; gap: .9rem;
  color: var(--muted);
  margin-bottom: 2.5rem;
}
.section__label span {
  display: inline-grid; place-items: center;
  width: 2rem; height: 2rem;
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--ink);
  font-size: .6875rem;
}

.section h2 {
  font-family: var(--serif);
  font-size: clamp(2.4rem, 6vw, 5.5rem);
  line-height: 1;
  letter-spacing: -0.025em;
  max-width: 18ch;
}
.section h2 em { color: var(--ember); }

/* Reveal helpers — cachés seulement si JavaScript tourne (classe .js posée dans head.ejs) :
   sans JS, main.js n'ajoute jamais .is-in et tout le contenu, formulaire compris, resterait invisible */
.reveal-up { transition: opacity 1s var(--ease), transform 1s var(--ease); transition-delay: var(--delay, 0s); }
.js .reveal-up:not(.is-in) { opacity: 0; transform: translateY(28px); }

.reveal-lines .w { display: inline-block; overflow: hidden; vertical-align: top; padding: .12em .14em .26em; margin: -.12em -.14em -.26em; }
.reveal-lines .w > span {
  display: inline-block;
  transform: translateY(140%);
  transition: transform 1.1s var(--ease);
  transition-delay: calc(var(--i) * 0.045s);
}
.reveal-lines.is-in .w > span { transform: none; }

/* Story */
.story__grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: clamp(2rem, 6vw, 6rem);
  align-items: start;
}
.story__lead {
  font-family: var(--serif);
  font-size: clamp(2.4rem, 5.4vw, 5rem) !important;
  line-height: 1.02 !important;
  position: sticky; top: 7rem;
}
.story__body { display: grid; gap: 1.4rem; color: var(--ink-2); max-width: 34rem; padding-top: .6rem; }
.story__body p:first-child::first-letter {
  font-family: var(--serif);
  float: left;
  font-size: 4.2em;
  line-height: .8;
  padding: .08em .1em 0 0;
  color: var(--ember);
}

.duo {
  margin-top: clamp(4rem, 9vw, 7rem);
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  border-block: 1px solid var(--line);
}
.duo__side { padding: 2.2rem 0; }
.duo__side:last-child { padding-left: clamp(1rem, 4vw, 3rem); }
.duo__side .mono { color: var(--muted); }
.duo ul { list-style: none; margin: 1rem 0 0; padding: 0; }
.duo li {
  font-family: var(--serif);
  font-size: clamp(1.4rem, 2.6vw, 2.1rem);
  line-height: 1.25;
  transition: transform .5s var(--ease), color .3s;
}
.duo li:hover { transform: translateX(8px); color: var(--ember); }
.duo__plus {
  font-family: var(--serif);
  font-size: clamp(3rem, 7vw, 6rem);
  color: var(--ember);
  padding: 0 clamp(1rem, 4vw, 3rem);
  animation: spin 14s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.facts {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  margin-top: clamp(3rem, 7vw, 5rem);
}
.fact { display: grid; gap: .4rem; border-top: 1px solid var(--ink); padding-top: 1.1rem; }
.fact:nth-child(2) { --delay: .1s; }
.fact:nth-child(3) { --delay: .2s; }
.fact__value { font-family: var(--serif); font-size: clamp(2.8rem, 5vw, 4.4rem); line-height: 1; }
.fact__label { color: var(--muted); font-size: .9375rem; max-width: 22ch; }

/* =============================================================
   La carte
   ============================================================= */
.carte { background: var(--paper-2); }
.carte__head {
  display: flex; justify-content: space-between; align-items: flex-end;
  gap: 2rem; flex-wrap: wrap;
  margin-bottom: clamp(3rem, 7vw, 5rem);
}
.carte__head p { max-width: 26rem; color: var(--ink-2); }

.menu {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(2rem, 4vw, 3.5rem);
}
.menu__course-title {
  display: flex; align-items: baseline; gap: .8rem;
  font-family: var(--serif);
  font-size: 2rem;
  font-style: italic;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--ink);
  margin-bottom: .5rem;
}
.menu__course-title .mono { font-style: normal; color: var(--ember); }
.menu ul { list-style: none; margin: 0; padding: 0; }

.dish {
  position: relative;
  padding: 1.4rem 0;
  border-bottom: 1px solid var(--line);
  cursor: default;
}
.dish::before {
  content: "";
  position: absolute; left: -.9rem; top: 2.05rem;
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--ember);
  transform: scale(0);
  transition: transform .4s var(--ease);
}
.dish:hover::before, .dish:focus-visible::before { transform: scale(1); }
.dish__row { display: flex; align-items: baseline; gap: .6rem; }
.dish__name {
  font-weight: 500; font-size: 1.125rem; letter-spacing: -0.01em;
  transition: transform .5s var(--ease);
}
.dish:hover .dish__name { transform: translateX(4px); }
.dish__dots {
  flex: 1;
  min-width: 1rem;
  height: 1px;
  background: radial-gradient(circle, var(--muted) 1px, transparent 1.2px) 0 0 / 6px 2px repeat-x;
  transform: translateY(-3px);
}
.dish__note { color: var(--muted); font-size: .6875rem; white-space: nowrap; }
.dish__desc {
  color: var(--ink-2);
  font-size: .9375rem;
  margin-top: .5rem;
  max-width: 34ch;
}
.carte__foot { margin-top: 3rem; color: var(--muted); text-align: center; }

/* =============================================================
   Optimisation
   ============================================================= */
.optim h2 { margin-bottom: clamp(2.5rem, 6vw, 4.5rem); max-width: 20ch; }
.optim__rows { border-top: 1px solid var(--ink); }
.optim__row {
  display: grid;
  grid-template-columns: 1.3fr 1fr 80px 1fr;
  align-items: center;
  gap: 1.5rem;
  padding: 1.6rem 0;
  border-bottom: 1px solid var(--line);
  transition: background .4s, padding .5s var(--ease);
}
.optim__row:hover { background: var(--paper-2); padding-inline: 1rem; }
.optim__task { font-family: var(--serif); font-size: clamp(1.4rem, 2.4vw, 2rem); line-height: 1.1; }
.optim__before { color: var(--muted); text-decoration: line-through; text-decoration-color: var(--ember); text-decoration-thickness: 1.5px; text-transform: none; font-size: .875rem; }
.optim__after { color: var(--ink); font-weight: 500; text-transform: none; font-size: .875rem; }
.optim__arrow { position: relative; height: 1px; background: var(--line); overflow: visible; }
.optim__arrow::before {
  content: "";
  position: absolute; inset: 0;
  background: var(--ember);
  transform: scaleX(0); transform-origin: left;
  transition: transform 1.1s var(--ease) .35s;
}
.optim__arrow::after {
  content: "";
  position: absolute; right: -1px; top: -4px;
  width: 8px; height: 8px;
  border-top: 1px solid var(--ember); border-right: 1px solid var(--ember);
  transform: rotate(45deg);
  opacity: 0;
  transition: opacity .3s 1.2s;
}
.optim__row.is-in .optim__arrow::before { transform: scaleX(1); }
.optim__row.is-in .optim__arrow::after { opacity: 1; }
.optim__disclaimer { margin-top: 1.5rem; color: var(--muted); text-transform: none; }

/* =============================================================
   Méthode
   ============================================================= */
.method { background: var(--ink); color: var(--paper); }
.method .section__label { color: rgba(242, 238, 229, .55); }
.method .section__label span { border-color: rgba(242, 238, 229, .2); color: var(--paper); }
.method h2 { max-width: 16ch; }

.steps {
  --p: 0;
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2rem;
  margin-top: clamp(3rem, 8vw, 6rem);
  padding-top: 3rem;
}
.steps__line { position: absolute; top: 0; left: 0; right: 0; height: 1px; background: rgba(242, 238, 229, .18); }
.steps__fill {
  position: absolute; inset: 0;
  background: var(--ember);
  transform: scaleX(var(--p)); transform-origin: left;
}
.step { position: relative; }
.step::before {
  content: "";
  position: absolute; top: calc(-3rem - 5px); left: 0;
  width: 11px; height: 11px; border-radius: 50%;
  background: var(--ink);
  border: 1px solid rgba(242, 238, 229, .4);
  transition: background .4s, border-color .4s;
}
.step.is-lit::before { background: var(--ember); border-color: var(--ember); }
.step:nth-of-type(2) { --delay: .1s; }
.step:nth-of-type(3) { --delay: .2s; }
.step:nth-of-type(4) { --delay: .3s; }
.step__num { font-family: var(--mono); font-size: .75rem; color: var(--ember); }
.step h3 { font-family: var(--serif); font-size: clamp(1.8rem, 2.6vw, 2.4rem); margin: .6rem 0 .8rem; }
.step p { color: rgba(242, 238, 229, .7); font-size: .9375rem; max-width: 28ch; }

/* =============================================================
   Contact
   ============================================================= */
.contact__grid {
  display: grid;
  grid-template-columns: 1fr minmax(0, 460px);
  gap: clamp(3rem, 8vw, 8rem);
  align-items: start;
}
.contact__intro > p { color: var(--ink-2); max-width: 30rem; margin-top: 2rem; }
.contact__direct { list-style: none; padding: 0; margin: 2.5rem 0 0; border-top: 1px solid var(--line); }
.contact__direct li {
  display: flex; justify-content: space-between; gap: 1rem;
  padding: 1rem 0;
  border-bottom: 1px solid var(--line);
}
.contact__direct .mono { color: var(--muted); }
.contact__direct a { position: relative; }
.contact__direct a:hover { color: var(--ember); }

.ticket--form { font-size: .8125rem; transform: rotate(1.2deg); transition: transform .8s var(--ease), opacity 1s var(--ease); }
.ticket--form.is-in { transform: rotate(1.2deg); }
.ticket--form:focus-within { transform: rotate(0deg); }
.ticket--form .ticket__inner { padding: 1.8rem 1.6rem 2rem; }

.field { display: block; margin: 0 0 1.1rem; border: 0; padding: 0; }
.field > span, .field legend {
  display: block;
  font-size: .6875rem;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--muted);
  margin-bottom: .35rem;
  padding: 0;
}
.field em { text-transform: none; }
.field input, .field textarea {
  width: 100%;
  border: 0;
  border-bottom: 1px dashed rgba(20, 18, 16, .35);
  background: transparent;
  padding: .4rem 0 .5rem;
  font: 400 1rem/1.4 var(--sans);
  color: var(--ink);
  border-radius: 0;
  resize: vertical;
  transition: border-color .3s;
}
.field input:focus, .field textarea:focus { outline: none; border-bottom: 1px solid var(--ember); }
.field .is-invalid, .field input.is-invalid, .field textarea.is-invalid { border-bottom-color: var(--ember); }

.chips { display: flex; flex-wrap: wrap; gap: .45rem; }
.chips label { position: relative; cursor: pointer; }
.chips input { position: absolute; opacity: 0; pointer-events: none; }
.chips span {
  display: inline-block;
  padding: .45rem .8rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-family: var(--sans);
  font-size: .8125rem;
  transition: background .3s, color .3s, border-color .3s;
}
.chips label:hover span { border-color: var(--ink); }
.chips input:checked + span { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.chips input:focus-visible + span { outline: 2px solid var(--ember); outline-offset: 2px; }

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

.form-status { min-height: 1.2em; margin-top: .9rem; text-transform: none; color: var(--ink-2); }
.form-status.is-error { color: var(--ember); }

.t-stamp--form {
  display: none; /* absent tant que le bon n'est pas envoyé : agrandi et invisible, il dépassait de l'écran sur mobile */
  position: absolute;
  right: 1.4rem; bottom: 4.2rem;
  font-size: 1.4rem;
  pointer-events: none;
}
.ticket--form.is-sent .t-stamp--form { display: inline-block; animation: stamp .5s var(--ease) forwards; }

/* =============================================================
   Footer
   ============================================================= */
.footer {
  padding: 4rem var(--pad) 2rem;
  border-top: 1px solid var(--line);
  overflow: hidden;
}
/* Logo officiel en grand, en bas de page */
.footer__logo { display: block; width: 100%; max-width: 1100px; }
.lockup { display: block; width: 100%; height: auto; overflow: visible; }
.lockup__e { stroke: var(--ink); }
.lockup__word { fill: var(--ink); }
.lockup__sub { fill: var(--muted); }
.lockup__dot { fill: var(--ember); transform-box: fill-box; transform-origin: center; }
/* À l'apparition : le « e » se dessine, le nom monte, le point tombe en dernier */
.footer__logo.is-armed .lockup__e { stroke-dasharray: 1; stroke-dashoffset: 1; }
.footer__logo.is-armed .lockup__word,
.footer__logo.is-armed .lockup__sub { opacity: 0; transform: translateY(14px); }
.footer__logo.is-armed .lockup__dot { transform: scale(0); }
.footer__logo.is-in .lockup__e { stroke-dashoffset: 0; transition: stroke-dashoffset 1.4s var(--ease); }
.footer__logo.is-in .lockup__word { opacity: 1; transform: none; transition: opacity .9s var(--ease) .35s, transform .9s var(--ease) .35s; }
.footer__logo.is-in .lockup__sub { opacity: 1; transform: none; transition: opacity .9s var(--ease) .55s, transform .9s var(--ease) .55s; }
.footer__logo.is-in .lockup__dot { transform: scale(1); transition: transform .6s cubic-bezier(.34, 1.56, .64, 1) 1.1s; }
.footer__logo:hover .lockup__dot { animation: dotBounce .7s var(--ease); }
@keyframes dotBounce { 40% { transform: translateY(-18%) scale(1.15); } }
.footer__row {
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 1rem;
  margin-top: 2.5rem;
  color: var(--muted);
  text-transform: none;
}
.footer__row a:hover { color: var(--ember); }

/* =============================================================
   404
   ============================================================= */
.notfound {
  min-height: 100svh;
  display: grid; place-content: center; justify-items: start;
  gap: 1.5rem;
  padding: 6rem var(--pad) 3rem; /* en haut : la place de la barre de navigation fixe */
  max-width: 900px; margin: 0 auto;
}
.notfound h1 { font-family: var(--serif); font-size: clamp(3rem, 9vw, 7rem); line-height: .95; letter-spacing: -0.03em; }
.notfound h1 em { color: var(--ember); }
.notfound .mono { color: var(--muted); }

/* =============================================================
   Responsive
   ============================================================= */
@media (max-width: 960px) {
  .story__grid, .contact__grid { grid-template-columns: 1fr; }
  .story__lead { position: static; }
  .menu { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr 1fr; row-gap: 3.5rem; }
  .steps__line { display: none; }
  .step::before { display: none; }
  .optim__row { grid-template-columns: 1fr 1fr; row-gap: .6rem; }
  .optim__task { grid-column: 1 / -1; }
  .optim__arrow { display: none; }
}
@media (max-width: 640px) {
  .duo { grid-template-columns: 1fr; }
  .duo__side:last-child { padding-left: 0; border-top: 1px solid var(--line); }
  .duo__plus { display: none; }
  .facts { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; }
  .nav__status { display: none; }
  .hero__bottom .btn { width: 100%; }
  .ticket--form { transform: none !important; }
  .ticket--form .ticket__inner { padding: 1.5rem 1.2rem 1.8rem; }
}

/* =============================================================
   Mouvement réduit
   ============================================================= */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
    scroll-behavior: auto !important;
  }
  .grain, .steam { display: none; }
  .split .ch, .reveal-lines .w > span { transform: none !important; opacity: 1 !important; }
  .js .reveal-up:not(.is-in) { opacity: 1; transform: none; }
}

/* =============================================================
   Logo
   ============================================================= */
.logo-mark { width: 26px; height: 26px; overflow: visible; }
.logo-mark__e {
  fill: none; stroke: currentColor; stroke-width: 6; stroke-linecap: round;
  stroke-dasharray: 150; stroke-dashoffset: 150;
  animation: drawE 1.4s var(--ease) .2s forwards;
}
.logo-mark__dot {
  fill: var(--ember);
  transform-box: fill-box; transform-origin: center;
  transform: scale(0);
  animation: dotIn .6s var(--ease) 1.2s forwards, pulse 2.4s var(--ease-io) 2s infinite;
}
@keyframes drawE { to { stroke-dashoffset: 0; } }
@keyframes dotIn { to { transform: scale(1); } }
.nav__brand:hover .logo-mark__e { animation: drawE 1s var(--ease) forwards; stroke-dashoffset: 150; }
.logo-word { font-family: var(--serif); font-size: 1.45rem; font-weight: 400; letter-spacing: -0.01em; line-height: 1; }
.logo-word em { font-family: var(--mono); font-style: normal; font-size: .62rem; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin-left: .15rem; vertical-align: .2em; }

/* =============================================================
   Réalisations
   ============================================================= */
.work h2 { margin-bottom: clamp(3rem, 8vw, 6rem); }
.work__list { display: grid; gap: clamp(4rem, 10vw, 8rem); }

.project {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: clamp(2rem, 6vw, 6rem);
  align-items: center;
}
.project--alt .project__stage { order: 2; }

.project__stage {
  position: relative;
  display: grid; place-items: center;
  padding: clamp(2.5rem, 6vw, 4.5rem) 1rem;
  background: var(--tone);
  border-radius: 28px;
  overflow: hidden;
  perspective: 1200px;
}
.project__ghost {
  position: absolute;
  left: 50%; top: 50%;
  translate: -50% -50%;
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(5rem, 13vw, 12rem);
  line-height: 1;
  white-space: nowrap;
  color: transparent;
  -webkit-text-stroke: 1px rgba(20, 18, 16, .18);
  pointer-events: none;
  animation: ghost 18s linear infinite alternate;
}
.project--alt .project__ghost { -webkit-text-stroke-color: rgba(242, 238, 229, .14); }
@keyframes ghost { from { transform: translateX(-12%); } to { transform: translateX(12%); } }

.phone {
  position: relative;
  display: block;
  width: clamp(200px, 22vw, 290px);
  aspect-ratio: 375 / 812;
  padding: 9px;
  border-radius: 40px;
  background: var(--ink);
  box-shadow: 0 40px 60px -30px rgba(0, 0, 0, .45), inset 0 0 0 1.5px #3a3530;
  transform-style: preserve-3d;
  transition: transform .6s var(--ease);
  animation: float 6s var(--ease-io) infinite;
}
.project--alt .phone { animation-delay: -3s; }
@keyframes float { 0%, 100% { translate: 0 0; } 50% { translate: 0 -10px; } }
.phone__screen {
  display: flex; flex-direction: column;
  width: 100%; height: 100%;
  border-radius: 32px; overflow: hidden;
  background: var(--screen-bg, #fff);
}
/* Barre d'état : l'encoche s'y loge, sans masquer le site */
.phone__status {
  flex: none;
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center;
  height: 34px; padding: 0 18px 0 22px;
  color: var(--screen-ink, #141210);
  font: 600 11px/1 var(--sans);
  letter-spacing: .01em;
}
.phone__island { width: 64px; height: 18px; border-radius: 20px; background: #000; }
.phone__icons { display: flex; justify-content: flex-end; align-items: center; gap: 5px; }
.phone__icons svg { height: 9px; width: auto; fill: currentColor; }
.phone__screen img {
  flex: 1; min-height: 0;
  width: 100%;
  object-fit: cover; object-position: top;
  transform-origin: top center;
  transition: transform 1.2s var(--ease);
}
.phone:hover .phone__screen img { transform: scale(1.03); }

.project__meta { display: flex; align-items: center; gap: .8rem; color: var(--muted); }
.project__meta span { color: var(--ember); }
.project__name {
  font-family: var(--serif);
  font-size: clamp(2.8rem, 6vw, 5rem);
  line-height: 1;
  letter-spacing: -0.02em;
  margin: .8rem 0 .4rem;
}
.project__client { color: var(--muted); }
.project__desc { color: var(--ink-2); margin-top: 1.4rem; max-width: 30rem; }
.project__tags { display: flex; flex-wrap: wrap; gap: .45rem; list-style: none; padding: 0; margin: 1.6rem 0 0; }
.project__tags li { padding: .4rem .75rem; border: 1px solid var(--line); border-radius: 999px; font-size: .6875rem; text-transform: none; }
.project__link {
  display: inline-flex; align-items: center; gap: .6rem;
  margin-top: 2rem;
  padding-bottom: .3rem;
  border-bottom: 1px solid var(--ink);
  font-weight: 500;
  transition: color .3s, border-color .3s, gap .4s var(--ease);
}
.project__link svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; transition: transform .4s var(--ease); }
.project__link:hover { color: var(--ember); border-color: var(--ember); gap: .9rem; }
.project__link:hover svg { transform: translate(2px, -2px); }

@media (max-width: 860px) {
  .project { grid-template-columns: 1fr; }
  .project--alt .project__stage { order: 0; }
}
