/* Better-Business — système visuel partagé */
:root {
  --canvas: #f8f9fb; --white: #fff; --well: #eceae3; --ink: #0b0b0c; --grey: #1b1d1c; --faint: #9a9ea7; --text: #3d4046; --mute: #6c7078;
  --line: rgba(12, 16, 28, .08); --night: #0e0e10; --night-2: #19191c; --green-hi: #36c267; --wave: #3fe8a4; --or: #1d9e4b; --or-bg: #dcefe2;
  --sans: "Google Sans Flex", -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
  --serif: "Newsreader", Georgia, "Times New Roman", serif;
  --gut: clamp(20px, 4vw, 56px); --max: clamp(1200px, 82vw, 1560px);
  --ease: cubic-bezier(.625, .05, 0, 1); --ease-out: cubic-bezier(.2, .715, .205, .99);
  --t-h: clamp(2.1rem, 3.5vw + .4rem, 4rem);
  --glow: 61, 220, 132;
  --halo: 0 0 0 6px rgba(255, 255, 255, .72), 0 0 0 7px rgba(27, 29, 28, .06), 0 44px 80px -52px rgba(27, 29, 28, .45);
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; background: var(--canvas); }
body { margin: 0; background: var(--canvas); color: var(--ink); font-family: var(--sans); font-size: 15.75px; line-height: 1.45; letter-spacing: -.01em; -webkit-font-smoothing: antialiased; overflow-x: clip; }
img { display: block; max-width: 100%; }
button, input { font: inherit; color: inherit; }
button { border: 0; background: none; padding: 0; cursor: pointer; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, p { margin: 0; font-weight: 400; }
:focus-visible { outline: 2px solid var(--green-hi); outline-offset: 3px; }
.skip { position: fixed; top: 12px; left: 50%; z-index: 120; transform: translate(-50%, -200%); padding: 10px 18px; border-radius: 999px; background: var(--ink); color: #fff; transition: transform .36s var(--ease); }
.skip:focus { transform: translate(-50%, 0); }

/* Chargement et rideau */
.loader { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; background: var(--canvas); transition: opacity .6s var(--ease-out), visibility 0s linear .6s; }
.loader.gone { opacity: 0; visibility: hidden; }
.loader__n { display: block; min-width: 3ch; text-align: center; font-family: var(--serif); font-size: 3rem; line-height: 1; font-variant-numeric: tabular-nums; }
.loader__bar { display: block; width: 140px; height: 2px; margin-top: 16px; overflow: hidden; border-radius: 2px; background: rgba(12, 16, 28, .1); }
.loader__bar b { display: block; height: 100%; width: 0; background: var(--ink); }
.pt { position: fixed; inset: 0; z-index: 95; background: var(--night); clip-path: circle(0 at 50% 50%); pointer-events: none; transition: clip-path .46s cubic-bezier(.45, 0, .55, 1); }

/* Langue */
.lang { position: fixed; top: 16px; right: 16px; z-index: 55; display: flex; gap: 2px; padding: 3px; border-radius: 999px; background: rgba(21, 21, 23, .92); color: rgba(255, 255, 255, .6); font-size: .75rem; font-weight: 600; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .08); }
.lang a { min-width: 32px; padding: 5px 8px; text-align: center; border-radius: 999px; transition: background .18s, color .18s; }
.lang a.on { background: #fff; color: var(--ink); }
.brand-link { position: fixed; top: 18px; left: 20px; z-index: 55; font-size: 1.05rem; letter-spacing: -.04em; mix-blend-mode: difference; color: #fff; font-weight: 600; }

/* Dock */
.dock { position: fixed; left: 50%; bottom: max(16px, env(safe-area-inset-bottom)); z-index: 50; display: flex; align-items: center; gap: 6px; padding: 6px; border-radius: 20px; background: rgba(21, 21, 23, .92); backdrop-filter: blur(16px) saturate(1.3); -webkit-backdrop-filter: blur(16px) saturate(1.3); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .08), 0 18px 40px -18px rgba(0, 0, 0, .5); color: #fff; transform: translate(-50%, 170%); transition: transform .8s var(--ease-out); }
.dock.in { transform: translate(-50%, 0); }
.start { position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 9px; height: 50px; min-width: 210px; padding: 0 1.5rem; overflow: hidden; isolation: isolate; border-radius: 15px; background: linear-gradient(180deg, #2d3030, #151616); color: #fff; font-size: 1rem; box-shadow: inset 0 1px 0 rgba(255, 255, 255, .22), inset 0 -2px 0 rgba(0, 0, 0, .3); transition: transform .25s var(--ease-out), box-shadow .5s var(--ease-out); }
.start::after { content: ""; position: absolute; inset: 0; z-index: -1; background: radial-gradient(60% 120% at var(--mx, 50%) 110%, rgba(61, 220, 132, .5), transparent 70%); opacity: 0; transition: opacity .4s; }
.start:hover { transform: translateY(-1px); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .28), 0 10px 26px -10px rgba(61, 220, 132, .7); }
.start:hover::after { opacity: 1; }
.start:active { transform: scale(.98); }
.start svg { width: 11px; height: 12px; fill: currentColor; }
.dock__key { position: relative; display: grid; place-items: center; width: 50px; height: 50px; gap: 5px; place-content: center; border-radius: 15px; background: #fff; color: var(--ink); transition: transform .14s var(--ease-out); }
.dock__key:active { transform: scale(.94); }
.dock__key--h { font-family: var(--serif); font-size: 1.5rem; }
.dock__key i { display: block; width: 16px; height: 1.6px; background: currentColor; transition: transform .3s var(--ease-out); }
[aria-expanded="true"] > i:first-child { transform: translateY(3.3px) rotate(45deg); }
[aria-expanded="true"] > i:last-child { transform: translateY(-3.3px) rotate(-45deg); }

/* Panneaux du dock */
.sheet, .help { position: fixed; left: 50%; z-index: 60; opacity: 0; visibility: hidden; pointer-events: none; transform: translate(-50%, 16px) scale(.97); transform-origin: 50% 100%; transition: transform .32s var(--ease-out), opacity .2s var(--ease-out), visibility 0s linear .32s; background: rgba(250, 250, 250, .78); -webkit-backdrop-filter: blur(26px) saturate(1.6); backdrop-filter: blur(26px) saturate(1.6); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .75), 0 24px 54px -22px rgba(15, 15, 15, .42), 0 0 0 .5px rgba(15, 15, 15, .08); color: var(--ink); }
.sheet.open, .help.open { opacity: 1; visibility: visible; pointer-events: auto; transform: translate(-50%, 0) scale(1); transition: transform .32s var(--ease-out), opacity .2s var(--ease-out), visibility 0s; }
.sheet { bottom: calc(max(16px, env(safe-area-inset-bottom)) + 76px); width: min(320px, calc(100vw - 24px)); padding: 6px; border-radius: 24px; }
.sheet a { display: block; padding: 13px; text-align: center; font-size: 1.1rem; letter-spacing: -.025em; border-radius: 16px; transition: background .18s; }
.sheet a:hover { background: rgba(12, 16, 28, .06); }
.help { bottom: calc(max(16px, env(safe-area-inset-bottom)) + 78px); width: min(420px, calc(100vw - 24px)); height: min(540px, calc(100svh - 124px)); display: grid; grid-template-rows: auto minmax(0, 1fr) auto auto; gap: 12px; padding: 14px; border-radius: 28px; }
.help__head { display: flex; align-items: center; gap: 9px; font-weight: 600; font-size: .875rem; }
.help__head i { width: 22px; height: 22px; border-radius: 50%; background: var(--ink); }
.help__x { margin-left: auto; width: 28px; height: 28px; border-radius: 50%; color: var(--mute); }
.help__x:hover { background: rgba(12, 16, 28, .06); }
.help__log { display: flex; flex-direction: column; gap: 8px; overflow: auto; font-size: .875rem; }
.msg { max-width: 86%; padding: 9px 13px; border-radius: 16px; background: #fff; animation: msg .34s var(--ease-out) both; }
.msg.me { align-self: flex-end; background: var(--ink); color: #fff; }
.help__chips { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; }
.help__chips button { flex: none; padding: 7px 12px; border-radius: 999px; background: #fff; font-size: .8125rem; box-shadow: 0 0 0 1px var(--line); }
.help form { display: flex; gap: 6px; }
.help input { flex: 1; min-width: 0; height: 42px; padding: 0 15px; border: 0; border-radius: 999px; background: #fff; box-shadow: 0 0 0 1px var(--line); outline: 0; font-size: .875rem; }
.help form button { width: 42px; height: 42px; border-radius: 50%; background: var(--ink); color: #fff; }
@keyframes msg { from { opacity: 0; transform: translateY(8px); } }

/* Pastille vivante (remplace l'avatar parlant) */
.nv { position: relative; display: inline-grid; place-items: center; width: .84em; height: .84em; margin-left: .22em; vertical-align: -.08em; border-radius: 50%; background: #111 center/cover; cursor: pointer; }
.nv::before, .nv::after { content: ""; position: absolute; inset: 0; border-radius: 50%; animation: rip 3.2s cubic-bezier(.22, .61, .36, 1) infinite; pointer-events: none; }
.nv::after { animation-delay: .34s; }
@keyframes rip { 0% { transform: scale(.92); opacity: 0; box-shadow: inset 0 0 7px 3px rgba(var(--glow), .95), 0 0 10px 1px rgba(var(--glow), .55); } 5% { opacity: 1; } 53%, 100% { transform: scale(2.1); opacity: 0; box-shadow: inset 0 0 1px .5px rgba(var(--glow), .9), 0 0 2px 0 rgba(var(--glow), 0); } }

/* Mot-mark « Better » chromé */
.mark { display: inline-block; padding-right: .04em; font-weight: 800; letter-spacing: -.055em; background: linear-gradient(180deg, #55585c 0%, #0b0b0c 42%, #2c2e31 62%, #8d9196 78%, #17181a 100%); background-size: 100% 220%; -webkit-background-clip: text; background-clip: text; color: transparent; animation: chrome 5s ease-in-out infinite alternate; }
@keyframes chrome { to { background-position: 0 100%; } }

/* Mouvements réduits */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
