:root {
  --paper: #ffffff;
  --page: #ececed;
  --ink: #16161a;
  --ink-soft: #4c4c55;
  --line: #e2e2e6;
  --field: #ffffff;
  --field-line: #d5d5db;
  --accent: #ffce00;
  --accent-ink: #16161a;
  --danger: #b0231a;
  --radius: 14px;
  --shadow: 0 24px 70px rgba(22, 22, 26, .10);
  --sans: "Figtree", ui-sans-serif, system-ui, -apple-system, sans-serif;
  --display: "Archivo", "Figtree", ui-sans-serif, system-ui, sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #17171b;
    --page: #0e0e11;
    --ink: #f4f4f6;
    --ink-soft: #a5a5b0;
    --line: #2b2b32;
    --field: #202027;
    --field-line: #3a3a44;
    --shadow: 0 24px 70px rgba(0, 0, 0, .45);
  }
}

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

/* l'attribut hidden doit l'emporter sur les display des classes */
[hidden] { display: none !important; }

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

body {
  margin: 0;
  padding: clamp(0px, 4vw, 56px) clamp(0px, 3vw, 40px);
  background: var(--page);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

.sheet {
  position: relative;
  isolation: isolate;
  max-width: 940px;
  margin: 0 auto;
  padding: clamp(40px, 7vw, 72px) clamp(20px, 5vw, 72px) clamp(32px, 5vw, 48px);
  background: var(--paper);
  border-radius: clamp(0px, 2vw, 22px);
  box-shadow: var(--shadow);
}

/* texture papier froissé: bruit fractal éclairé en lumière rasante */
.sheet::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 0;
  border-radius: inherit;
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='900' height='900'%3E%3Cfilter id='f' x='0' y='0' width='100%25' height='100%25'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.0042 0.0058' numOctaves='4' seed='9' stitchTiles='stitch' result='n'/%3E%3CfeDiffuseLighting in='n' lighting-color='%23ffffff' surfaceScale='5.5' diffuseConstant='1'%3E%3CfeDistantLight azimuth='128' elevation='40'/%3E%3C/feDiffuseLighting%3E%3CfeComponentTransfer%3E%3CfeFuncR type='linear' slope='1.3' intercept='-.1'/%3E%3CfeFuncG type='linear' slope='1.3' intercept='-.1'/%3E%3CfeFuncB type='linear' slope='1.3' intercept='-.1'/%3E%3C/feComponentTransfer%3E%3C/filter%3E%3Crect width='900' height='900' filter='url(%23f)'/%3E%3C/svg%3E"),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='g' x='0' y='0' width='100%25' height='100%25'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.75' numOctaves='2' seed='4' stitchTiles='stitch' result='n'/%3E%3CfeDiffuseLighting in='n' lighting-color='%23ffffff' surfaceScale='1.1'%3E%3CfeDistantLight azimuth='128' elevation='58'/%3E%3C/feDiffuseLighting%3E%3C/filter%3E%3Crect width='300' height='300' filter='url(%23g)'/%3E%3C/svg%3E");
  background-size: 900px 900px, 300px 300px;
  mix-blend-mode: multiply;
  opacity: .3;
  pointer-events: none;
}

@media (prefers-color-scheme: dark) {
  .sheet::before { mix-blend-mode: screen; opacity: .07; }
}

/* ---------- brand ---------- */

.brand {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  margin-bottom: clamp(40px, 6vw, 64px);
}

.brand__logo {
  display: block;
  width: clamp(184px, 26.4vw, 248px);
  height: auto;
}

/* ---------- hero ---------- */

.hero { text-align: center; }

.hero__title {
  margin: 0 auto;
  font-family: var(--display);
  font-weight: 900;
  font-size: clamp(25px, 7.5vw, 70px);
  font-stretch: 87%;
  line-height: 1.04;
  letter-spacing: -.028em;
  text-transform: uppercase;
  white-space: nowrap;
}

/* stabilo: deux passages de feutre légèrement décalés */
.mark {
  position: relative;
  z-index: 0;
  display: block;
  width: fit-content;
  margin: .12em auto 0;
  padding: 0 .16em;
  color: var(--accent-ink);
}

.mark::before,
.mark::after {
  content: "";
  position: absolute;
  z-index: -1;
  pointer-events: none;
}

.mark::before {
  inset: 1% -.16em -2% -.15em;
  background: linear-gradient(97deg,
    rgba(255, 206, 0, .35) 0%,
    rgba(255, 206, 0, .96) 3.5%,
    rgba(255, 206, 0, .96) 96%,
    rgba(255, 206, 0, .32) 100%);
  border-radius: .55em .95em .7em 1.1em / 1.2em .65em 1.15em .6em;
  transform: rotate(-.85deg);
}

.mark::after {
  inset: 34% .1em -6% -.06em;
  background: linear-gradient(93deg,
    rgba(255, 190, 0, .0) 0%,
    rgba(255, 190, 0, .55) 8%,
    rgba(255, 190, 0, .5) 88%,
    rgba(255, 190, 0, .0) 100%);
  border-radius: .9em .5em 1.1em .6em / .7em 1.1em .6em 1.2em;
  transform: rotate(.7deg);
}

.hero__sub {
  max-width: 48ch;
  margin: clamp(22px, 3.5vw, 32px) auto 0;
  padding: 0 clamp(0px, 1vw, 12px);
  color: var(--ink-soft);
  font-size: clamp(17px, 2.4vw, 22px);
  text-wrap: balance;
}

.hero__sub strong { color: var(--ink); font-weight: 800; }

/* ---------- proof row ---------- */

.proof {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  margin: clamp(44px, 6vw, 66px) 0 clamp(44px, 6vw, 64px);
}

.proof__item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  padding: 0 clamp(6px, 1.1vw, 12px);
  text-align: center;
}

.proof__item + .proof__item { border-left: 1px solid var(--line); }

.proof__item i {
  font-size: clamp(34px, 4.6vw, 44px);
  line-height: 1;
}

.proof__item p {
  margin: 0;
  color: var(--ink-soft);
  font-size: clamp(12.5px, 1.6vw, 14.5px);
  line-height: 1.4;
}

.proof__item strong { color: var(--ink); font-weight: 800; }

/* ---------- signup ---------- */

.signup {
  padding: clamp(28px, 4.5vw, 44px) clamp(20px, 4vw, 52px) clamp(26px, 4vw, 38px);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
}

.signup__title {
  margin: 0 0 clamp(24px, 3.5vw, 34px);
  font-family: var(--display);
  font-weight: 900;
  font-size: clamp(24px, 4.2vw, 34px);
  line-height: 1.12;
  letter-spacing: -.02em;
  text-transform: uppercase;
  text-align: center;
  text-wrap: balance;
}

.signup__accent {
  position: relative;
  display: block;
  width: fit-content;
  margin: 0 auto;
  padding-bottom: .32em;
  color: #b98d00;
}

@media (prefers-color-scheme: dark) {
  .signup__accent { color: var(--accent); }
}

/* soulignage au feutre: deux passages qui se rejoignent à droite */
.signup__stroke {
  position: absolute;
  left: -.04em;
  right: -.05em;
  bottom: -.1em;
  width: calc(100% + .09em);
  height: .44em;
  overflow: visible;
  color: var(--accent);
  pointer-events: none;
}

/* ---------- form ---------- */

.form { display: grid; gap: 18px; }

.field { display: grid; gap: 8px; }

.field label {
  font-weight: 800;
  font-size: 15px;
}

.field input {
  width: 100%;
  padding: 15px 18px;
  border: 1px solid var(--field-line);
  border-radius: 10px;
  background: var(--field);
  color: var(--ink);
  font-family: inherit;
  font-size: 16px;
  transition: border-color .18s ease, box-shadow .18s ease;
}

.field input::placeholder { color: #7b7b86; }

.field input:hover { border-color: #b4b4bd; }

.field input:focus-visible {
  outline: none;
  border-color: var(--ink);
  box-shadow: 0 0 0 3px rgba(255, 206, 0, .55);
}

.field input[aria-invalid="true"] { border-color: var(--danger); }

.error {
  margin: 0;
  color: var(--danger);
  font-size: 13.5px;
  font-weight: 600;
}

.error--form { margin-top: -6px; text-align: center; }

.cta {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  min-height: 62px;
  margin-top: 4px;
  padding: 18px 24px;
  border: 0;
  border-radius: 10px;
  background: var(--accent);
  color: var(--accent-ink);
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(15px, 2.2vw, 18px);
  letter-spacing: -.005em;
  text-transform: uppercase;
  white-space: nowrap;
  cursor: pointer;
  transition: transform .16s ease, filter .16s ease, box-shadow .16s ease;
}

.cta:hover { filter: brightness(1.06); box-shadow: 0 10px 26px rgba(255, 206, 0, .38); }
.cta:active { transform: translateY(1px) scale(.995); }
.cta:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; }
.cta[disabled] { cursor: progress; filter: saturate(.6); }

.cta__spinner {
  display: none;
  width: 17px;
  height: 17px;
  border: 2.5px solid rgba(22, 22, 26, .25);
  border-top-color: var(--accent-ink);
  border-radius: 50%;
  animation: spin .7s linear infinite;
}

.cta.is-loading .cta__spinner { display: block; }

@keyframes spin { to { transform: rotate(360deg); } }

.legal {
  margin: 6px 0 0;
  color: var(--ink-soft);
  font-size: 14px;
  line-height: 1.5;
  text-align: center;
}

.legal i { vertical-align: -2px; margin-right: 5px; font-size: 15px; }

/* ---------- success ---------- */

.done { text-align: center; padding: 10px 0 6px; }

.done i { font-size: 46px; color: #1f7a44; }

@media (prefers-color-scheme: dark) { .done i { color: #4ecb84; } }

.done__title {
  margin: 12px 0 6px;
  font-family: var(--display);
  font-weight: 900;
  font-size: 26px;
  text-transform: uppercase;
}

.done__body {
  margin: 0 auto;
  max-width: 40ch;
  color: var(--ink-soft);
  font-size: 15.5px;
}

/* ---------- footer ---------- */

.foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: clamp(28px, 4vw, 40px);
  padding-top: 20px;
  border-top: 1px solid var(--line);
  color: var(--ink-soft);
  font-size: 13.5px;
}

.foot p { margin: 0; }
.foot nav { display: flex; gap: 20px; }
.foot a { color: inherit; text-decoration: none; border-bottom: 1px solid var(--line); }
.foot a:hover { color: var(--ink); border-bottom-color: currentColor; }

/* ---------- responsive ---------- */

@media (max-width: 860px) {
  .proof { grid-template-columns: repeat(2, 1fr); row-gap: 34px; }
  .proof__item:nth-child(odd) { border-left: 0; }
  .proof__item:nth-child(n + 3) { padding-top: 34px; border-top: 1px solid var(--line); }
}

@media (max-width: 560px) {
  body { padding: 0; }
  .sheet { border-radius: 0; box-shadow: none; }
  .proof__item:nth-child(n + 3) { padding-top: 30px; }
  .cta { white-space: normal; line-height: 1.25; }
  .foot { justify-content: center; text-align: center; }
}

/* ---------- motion ---------- */

.reveal {
  animation: rise .7s cubic-bezier(.16, 1, .3, 1) both;
}

.reveal--d1 { animation-delay: .08s; }
.reveal--d2 { animation-delay: .16s; }
.reveal--d3 { animation-delay: .24s; }

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

@media (prefers-reduced-motion: reduce) {
  .reveal { animation: none; }
  .cta { transition: none; }
  .cta__spinner { animation-duration: 2s; }
  * { scroll-behavior: auto !important; }
}
