/* Ostau V2 — premium, motion-first, « simple & efficace » pour propriétaires pressés.
   Tokens de motion issus de la skill motion-design (easing + durées). */

:root {
  /* couleurs */
  --bg: #f3ede2;
  --bg-soft: #ece3d4;
  --card: #fffdf9;
  --ink: #20201c;
  --ink-soft: #5b5648;
  --line: #ddd3c0;
  --accent: #b5572e;
  --accent-deep: #8d4221;
  --green: #2c4434;
  --green-deep: #21342a;

  /* motion — durées */
  --dur-1: 120ms; --dur-2: 180ms; --dur-3: 240ms; --dur-4: 300ms; --dur-5: 500ms;
  /* motion — easing */
  --ease-out-quart: cubic-bezier(.165,.84,.44,1);
  --ease-out-quint: cubic-bezier(.23,1,.32,1);
  --ease-out-expo: cubic-bezier(.19,1,.22,1);
  --ease-in-out-cubic: cubic-bezier(.645,.045,.355,1);

  --maxw: 1180px; --gutter: 28px; --radius: 20px;
  --shadow: 0 24px 70px -28px rgba(48,36,22,.34);
  --shadow-sm: 0 10px 30px -16px rgba(48,36,22,.28);
  --serif: "Iowan Old Style","Palatino Linotype",Palatino,Georgia,"Times New Roman",serif;
  --sans: "Helvetica Neue",-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Arial,sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; font-family: var(--sans); color: var(--ink); background: var(--bg); line-height: 1.6; -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; overflow-x: hidden; }
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
h1,h2,h3 { font-family: var(--serif); font-weight: 600; line-height: 1.06; letter-spacing: -.018em; margin: 0; }
h1 { font-size: clamp(2.7rem, 7vw, 5.4rem); }
h2 { font-size: clamp(2rem, 4.6vw, 3.4rem); }
h3 { font-size: clamp(1.2rem, 2vw, 1.5rem); letter-spacing: -.01em; }
p { margin: 0 0 1rem; }
.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 var(--gutter); }
.muted { color: var(--ink-soft); }
.eyebrow { text-transform: uppercase; letter-spacing: .2em; font-size: .74rem; font-weight: 600; color: var(--accent); margin: 0 0 1.2rem; }

/* ---------- Boutons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: .6rem;
  padding: 1.05rem 1.9rem; border-radius: 100px; font-weight: 600; font-size: .98rem;
  border: 1px solid var(--ink); background: var(--ink); color: var(--bg); cursor: pointer;
  transition: transform var(--dur-1) var(--ease-out-quart), background var(--dur-2) ease, color var(--dur-2) ease, box-shadow var(--dur-2) ease;
}
@media (hover:hover){ .btn:hover { background: var(--accent); border-color: var(--accent); color: #fff; box-shadow: var(--shadow-sm); } }
.btn:active { transform: scale(.98); }
.btn-light { background: var(--card); color: var(--ink); border-color: var(--card); }
.btn-ghost { background: transparent; color: var(--ink); }
@media (hover:hover){ .btn-ghost:hover { background: var(--ink); color: var(--bg); } }
.btn-lg { padding: 1.2rem 2.2rem; font-size: 1.05rem; }
.btn .ar { transition: transform var(--dur-3) var(--ease-out-quart); }
@media (hover:hover){ .btn:hover .ar { transform: translateX(4px); } }

/* ---------- Header ---------- */
.hdr { position: fixed; top: 0; left: 0; right: 0; z-index: 60; transition: background var(--dur-3) ease, box-shadow var(--dur-3) ease, border-color var(--dur-3) ease; border-bottom: 1px solid transparent; }
.hdr.scrolled { background: rgba(243,237,226,.9); backdrop-filter: saturate(150%) blur(12px); border-bottom-color: var(--line); }
.nav { display: flex; align-items: center; justify-content: space-between; height: 78px; transition: height var(--dur-3) ease; }
.hdr.scrolled .nav { height: 64px; }
.brand { display: flex; align-items: center; gap: .55rem; font-family: var(--serif); font-size: 1.5rem; color: #fff; transition: color var(--dur-3) ease; }
.hdr.scrolled .brand { color: var(--ink); }
.brand .mk { width: 26px; height: 26px; flex: 0 0 auto; }
.brand .bk { display: flex; flex-direction: column; line-height: 1; font-family: var(--serif); font-size: 1.45rem; }
.brand .bk small { font-family: var(--sans); font-size: .5rem; letter-spacing: .24em; text-transform: uppercase; font-weight: 600; margin-bottom: 3px; opacity: .9; }
.nav-links { display: flex; align-items: center; gap: 2rem; }
.nav-links a { font-size: .86rem; font-weight: 500; color: #fff; transition: color var(--dur-2) ease, opacity var(--dur-2) ease; }
.hdr.scrolled .nav-links a { color: var(--ink); }
.nav-links a:not(.cta) { opacity: .9; }
@media (hover:hover){ .nav-links a:not(.cta):hover { opacity: 1; color: #fff; } .hdr.scrolled .nav-links a:not(.cta):hover { color: var(--accent); } }
.nav-links a.cta { border: 1px solid rgba(255,255,255,.6); border-radius: 100px; padding: .6rem 1.2rem; }
.hdr.scrolled .nav-links a.cta { border-color: var(--ink); }
@media (hover:hover){ .nav-links a.cta:hover { background: #fff; color: var(--ink); } }
.burger { display: none; background: none; border: 0; cursor: pointer; padding: 8px; }
.burger span { display: block; width: 24px; height: 2px; background: #fff; margin: 5px 0; transition: background var(--dur-3) ease; }
.hdr.scrolled .burger span { background: var(--ink); }

/* ---------- Hero ---------- */
.hero { position: relative; isolation: isolate; min-height: min(100svh, 940px); display: flex; align-items: center; color: #fff; overflow: hidden; }
.hero-bg { position: absolute; inset: -8% 0 0 0; z-index: -2; background: url("/assets/ossau.webp") center 32% / cover no-repeat; will-change: transform; transform: scale(1.12); animation: heroIn 1.6s var(--ease-out-expo) forwards; }
@keyframes heroIn { to { transform: scale(1.04); } }
.hero::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(16,18,14,.42) 0%, rgba(16,18,14,.15) 38%, rgba(16,18,14,.78) 100%), linear-gradient(90deg, rgba(16,18,14,.5) 0%, rgba(16,18,14,.05) 60%, transparent 100%); }
.hero-inner { max-width: 60ch; padding-top: 60px; }
.hero .eyebrow { color: #e9c8a6; }
.hero h1 { color: #fff; max-width: 16ch; text-shadow: 0 2px 40px rgba(0,0,0,.4); }
.hero .lede { font-size: clamp(1.1rem,1.7vw,1.4rem); color: #efeae0; max-width: 40ch; margin-top: 1.4rem; text-shadow: 0 1px 24px rgba(0,0,0,.45); }
.hero-cta { display: flex; gap: 1rem; flex-wrap: wrap; margin-top: 2.2rem; }
.hero .btn { background: var(--card); color: var(--ink); border-color: var(--card); }
@media (hover:hover){ .hero .btn:hover { background: var(--accent); border-color: var(--accent); color: #fff; } }
.hero .btn-ghost { background: rgba(255,255,255,.08); color: #fff; border-color: rgba(255,255,255,.5); }
@media (hover:hover){ .hero .btn-ghost:hover { background: rgba(255,255,255,.18); } }
/* anim d'entrée du contenu */
.hero-inner > * { animation: up 1s var(--ease-out-quart) both; }
@keyframes up { from { opacity: 0; transform: translateY(26px); } to { opacity: 1; transform: none; } }
.scrollcue { position: absolute; left: 50%; bottom: 26px; transform: translateX(-50%); z-index: 1; color: rgba(255,255,255,.8); font-size: .72rem; letter-spacing: .2em; text-transform: uppercase; display: flex; flex-direction: column; align-items: center; gap: 8px; opacity: 0; animation: up .8s var(--ease-out-quart) 1s forwards; }
.scrollcue i { width: 1px; height: 34px; background: rgba(255,255,255,.6); display: block; transform-origin: top; animation: cue 1.8s var(--ease-in-out-cubic) infinite; }
@keyframes cue { 0%,100% { transform: scaleY(.4); opacity: .4; } 50% { transform: scaleY(1); opacity: 1; } }

/* ---------- Sections ---------- */
section { padding: clamp(72px, 11vw, 150px) 0; }
.head { max-width: 60ch; margin-bottom: clamp(40px, 6vw, 80px); }
.head h2 { margin-bottom: 1.2rem; }
.head p { font-size: 1.15rem; color: var(--ink-soft); max-width: 50ch; }
.center { text-align: center; margin-left: auto; margin-right: auto; }

/* ---------- Promesse / 3 étapes ---------- */
.promise { background: var(--card); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.flow { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(28px, 4vw, 64px); }
.fl { position: relative; }
.fl .n { font-family: var(--serif); font-size: 3.4rem; color: var(--bg-soft); line-height: 1; display: block; margin-bottom: 1rem; transition: color var(--dur-4) var(--ease-out-quart); }
.fl:hover .n { color: var(--accent); }
.fl h3 { margin-bottom: .6rem; }
.fl p { color: var(--ink-soft); margin: 0; }

/* ---------- On s'occupe de tout (checklist auto-cochée) ---------- */
.gere { background: var(--bg-soft); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.gere-grid { display: grid; grid-template-columns: 1fr 1.05fr; gap: clamp(40px, 6vw, 90px); align-items: center; }
.gere-head h2 { margin-bottom: 1.2rem; max-width: 16ch; }
.gere-punch { font-family: var(--serif); font-size: clamp(1.3rem, 2.2vw, 1.7rem); margin: 1.8rem 0 0; transition: opacity .6s var(--ease-out-quart), transform .6s var(--ease-out-quart); }
.gere.armed .gere-punch.in { opacity: 1; transform: none; }
.gere-punch b { color: var(--accent); }
.tasks { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: clamp(18px, 3vw, 30px) clamp(22px, 3vw, 36px); }
.task { display: flex; align-items: center; gap: 16px; padding: 17px 0; border-top: 1px solid var(--line); transition: opacity .55s var(--ease-out-quart), transform .55s var(--ease-out-quart); }
.task:first-child { border-top: 0; }
.tick { width: 30px; height: 30px; flex: 0 0 auto; }
.tick circle { fill: none; stroke: var(--accent); stroke-width: 2.4; stroke-dasharray: 101; stroke-dashoffset: 0; transition: stroke-dashoffset .55s var(--ease-out-quart); }
.tick path { fill: none; stroke: var(--accent); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 26; stroke-dashoffset: 0; transition: stroke-dashoffset .35s var(--ease-out-quart) .28s; }
.tlabel { flex: 1; font-weight: 500; }
.tby { font-size: .68rem; text-transform: uppercase; letter-spacing: .1em; color: var(--accent); border: 1px solid var(--line); border-radius: 100px; padding: .28rem .7rem; transition: opacity .45s ease .3s; }

/* état « armé » par le JS : caché tant que la section n'est pas vue (sans flash car hors écran) */
.gere.armed .task { opacity: 0; transform: translateX(-12px); }
.gere.armed .task .tick circle { stroke-dashoffset: 101; }
.gere.armed .task .tick path { stroke-dashoffset: 26; }
.gere.armed .task .tby { opacity: 0; }
.gere.armed .gere-punch { opacity: 0; transform: translateY(12px); }
.gere.armed .task.in { opacity: 1; transform: none; }
.gere.armed .task.in .tick circle, .gere.armed .task.in .tick path { stroke-dashoffset: 0; }
.gere.armed .task.in .tby { opacity: 1; }

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

/* ---------- Stats animées ---------- */
.stats { background: var(--green-deep); color: #eef1ea; }
.stats-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px; }
.st { text-align: center; }
.st .v { font-family: var(--serif); font-size: clamp(2.8rem, 6vw, 4.4rem); color: #fff; line-height: 1; display: block; }
.st .l { color: #b6c5b2; font-size: 1rem; margin-top: .8rem; }

/* ---------- Simulateur ---------- */
.sim-card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; display: grid; grid-template-columns: 1fr 1fr; }
.sim-l { padding: clamp(28px, 4vw, 48px); }
.sim-r { padding: clamp(28px, 4vw, 48px); background: var(--green); color: #eef1ea; display: flex; flex-direction: column; justify-content: center; }
.field { margin-bottom: 30px; }
.field:last-child { margin-bottom: 0; }
.field label { display: block; font-weight: 600; margin-bottom: .9rem; }
.field .hint { display: block; font-weight: 400; color: var(--ink-soft); font-size: .85rem; margin-top: .3rem; }
.seg { display: inline-flex; background: var(--bg); border-radius: 100px; padding: 4px; }
.seg button { border: 0; background: transparent; padding: .6rem 1.2rem; border-radius: 100px; font-weight: 600; cursor: pointer; color: var(--ink-soft); font-family: var(--sans); transition: background var(--dur-2) var(--ease-out-quart), color var(--dur-2) ease; }
.seg button.on { background: var(--ink); color: var(--bg); }
input[type=range] { width: 100%; accent-color: var(--accent); }
.fieldval { font-family: var(--serif); font-size: 1.6rem; margin-top: .7rem; }
.sim-r .lab { text-transform: uppercase; letter-spacing: .14em; font-size: .76rem; color: #aebfac; margin: 0; }
.sim-r .big { font-family: var(--serif); font-size: clamp(2.8rem, 6vw, 4rem); color: #fff; line-height: 1; margin: .5rem 0 1.6rem; }
.sim-row { display: flex; justify-content: space-between; padding: .8rem 0; border-top: 1px solid rgba(255,255,255,.16); font-size: .98rem; }
.sim-row b { color: #fff; }
.sim-r .big-u { font-size: 1rem; color: #aebfac; }
.sim-row.net { border-top: 2px solid rgba(255,255,255,.45); margin-top: .4rem; padding-top: 1rem; }
.sim-row.net span { font-weight: 600; }
.sim-row.net b { font-size: 1.25rem; }
.vs { margin: 1.1rem 0 0; font-size: .92rem; color: #cfe0cc; }
.vs span { display: inline-block; background: rgba(233,200,166,.18); color: #e9c8a6; font-weight: 700; padding: .22rem .65rem; border-radius: 100px; margin-right: .35rem; }
.sim-note { font-size: .8rem; color: #a6baa3; margin: 1rem 0 1.4rem; }

/* ---------- Réassurance (photo + promesses) ---------- */
.reassure { position: relative; isolation: isolate; color: #f1ede4; }
.reassure::before { content: ""; position: absolute; inset: 0; z-index: -2; background: url("/assets/boulevard.webp") center / cover no-repeat; }
.reassure::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(20,24,18,.9) 0%, rgba(20,24,18,.66) 55%, rgba(20,24,18,.4) 100%); }
.reassure .eyebrow { color: #e9c8a6; }
.reassure h2 { color: #fff; max-width: 18ch; }
.rl { list-style: none; padding: 0; margin: 2rem 0 0; max-width: 46ch; }
.rl li { display: flex; gap: 14px; align-items: baseline; padding: 16px 0; border-top: 1px solid rgba(255,255,255,.2); font-size: 1.08rem; }
.rl .chk { color: #e9c8a6; flex: 0 0 auto; }

/* ---------- Qui je suis (encart fondateur) ---------- */
.ap-grid { display: grid; grid-template-columns: minmax(0, .82fr) 1fr; gap: clamp(36px, 6vw, 80px); align-items: center; }
.ap-photo { max-width: 420px; }
.ap-ph, .ap-photo img { width: 100%; aspect-ratio: 4 / 5; border-radius: var(--radius); box-shadow: var(--shadow); }
.ap-ph { background: linear-gradient(150deg, var(--green) 0%, var(--green-deep) 100%); display: grid; place-items: center; font-family: var(--serif); font-size: clamp(3rem, 7vw, 5rem); color: #fff; letter-spacing: .04em; }
.ap-photo img { object-fit: cover; display: block; }
.ap-txt h2 { margin-bottom: 1.2rem; max-width: 18ch; }
.ap-txt p { color: var(--ink-soft); font-size: 1.08rem; }
.ap-txt p b { color: var(--ink); }
.ap-sign { font-family: var(--serif); font-style: italic; color: var(--accent); margin-top: 1.4rem !important; }
@media (max-width: 900px) { .ap-grid { grid-template-columns: 1fr; } .ap-photo { max-width: 320px; } }

/* ---------- Tarifs simples ---------- */
.duo { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.tier { background: var(--card); border-radius: var(--radius); padding: clamp(28px,4vw,46px); box-shadow: var(--shadow-sm); transition: transform var(--dur-3) var(--ease-out-quart), box-shadow var(--dur-3) ease; }
@media (hover:hover){ .tier:hover { transform: translateY(-6px); box-shadow: var(--shadow); } }
.tier.dark { background: var(--ink); color: var(--bg); }
.tier .tag { text-transform: uppercase; letter-spacing: .14em; font-size: .74rem; color: var(--accent); font-weight: 600; }
.tier.dark .tag { color: #e9c8a6; }
.tier .amt { font-family: var(--serif); font-size: clamp(2.6rem,5vw,3.6rem); line-height: 1; margin: .8rem 0 .3rem; }
.tier .sub { color: var(--ink-soft); margin: 0 0 1.4rem; }
.tier.dark .sub { color: #b6b0a3; }
.tier ul { list-style: none; padding: 0; margin: 0; }
.tier li { display: flex; gap: .6rem; padding: .55rem 0; font-size: .98rem; border-top: 1px solid var(--line); }
.tier.dark li { border-color: rgba(255,255,255,.16); }
.tier .chk { color: var(--accent); flex: 0 0 auto; }
.tier.dark .chk { color: #e9c8a6; }

/* ---------- CTA final ---------- */
.cta-final { background: var(--card); border-top: 1px solid var(--line); text-align: center; }
.cta-final h2 { max-width: 20ch; margin: 0 auto 1.2rem; }
.cta-final p { color: var(--ink-soft); max-width: 44ch; margin: 0 auto 2rem; font-size: 1.1rem; }
.cta-btns { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }

/* ---------- Footer ---------- */
.ft { background: var(--ink); color: #c8c2b4; padding: 64px 0 32px; }
.ft a:hover { color: #e9c8a6; }
.ft-top { display: flex; justify-content: space-between; gap: 40px; flex-wrap: wrap; padding-bottom: 36px; border-bottom: 1px solid rgba(255,255,255,.14); }
.ft-brand { font-family: var(--serif); font-size: 1.8rem; color: #fff; line-height: 1; }
.ft-brand small { display: block; font-family: var(--sans); font-size: .58rem; letter-spacing: .24em; text-transform: uppercase; font-weight: 600; opacity: .8; margin-bottom: 4px; }
.ft-tag { color: #8f897b; font-size: .88rem; max-width: 40ch; margin: .7rem 0 0; }
.ft-links { display: flex; gap: 40px; flex-wrap: wrap; }
.ft-links a { font-size: .95rem; }
.ft-bot { padding-top: 22px; font-size: .8rem; color: #8f897b; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; }

/* ---------- Motion : reveal au scroll ---------- */
.reveal { opacity: 0; transform: translateY(30px); transition: opacity .8s var(--ease-out-quart), transform .8s var(--ease-out-quart); }
.reveal.in { opacity: 1; transform: none; }
.flow > .reveal:nth-child(2), .stats-grid > .reveal:nth-child(2) { transition-delay: .1s; }
.flow > .reveal:nth-child(3), .stats-grid > .reveal:nth-child(3) { transition-delay: .2s; }
.rl li.reveal:nth-child(2){transition-delay:.06s} .rl li.reveal:nth-child(3){transition-delay:.12s} .rl li.reveal:nth-child(4){transition-delay:.18s}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .sim-card { grid-template-columns: 1fr; }
  .flow { grid-template-columns: 1fr; gap: 36px; }
  .stats-grid { grid-template-columns: 1fr; gap: 36px; }
  .duo { grid-template-columns: 1fr; }
}
@media (max-width: 820px) {
  .nav-links { position: fixed; inset: 78px 0 auto 0; flex-direction: column; align-items: stretch; gap: 0; background: var(--bg); border-bottom: 1px solid var(--line); padding: 10px 28px 22px; display: none; }
  .nav-links.open { display: flex; }
  .nav-links a { color: var(--ink); padding: 14px 0; border-bottom: 1px solid var(--line); opacity: 1; }
  .nav-links a.cta { border: 1px solid var(--ink); margin-top: 12px; text-align: center; justify-content: center; }
  .burger { display: block; }
  .scrollcue { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  *,*::before,*::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
  .reveal { opacity: 1 !important; transform: none !important; }
  .hero-bg { transform: scale(1.04); }
}
a:focus-visible, button:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
