/* FaceDiag : la charte de Klip (rose #F7CACD, encre, Poppins et Fraunces), en grand format tactile. */
:root {
  --pink: #F7CACD;
  --pink-100: #fef8f9;
  --pink-200: #fbe8e9;
  --pink-300: #f9dcde;
  --pink-800: #e8737c;
  --rose-text: #c9404d;
  --red: #e03e4b;
  --ink: #111111;
  --ink-2: #272727;
  --grey: #61666a;
  --grey-2: #8a8a8d;
  --line: #ececec;
  --bg: #ffffff;
  --ok: #2f9e5b;
  --radius: 20px;
  --radius-sm: 12px;
  --pill: 100px;
  --shadow: 0 10px 40px rgba(17, 17, 17, .06);
  --font: 'Poppins', system-ui, -apple-system, 'Segoe UI', Arial, sans-serif;
  --serif: 'Fraunces', Georgia, serif;
  --lv-zoom: .5;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; height: 100%; }
body { padding-left: env(safe-area-inset-left); padding-right: env(safe-area-inset-right); }
body { margin: 0; min-height: 100%; background: var(--pink-100); color: var(--ink); font-family: var(--font); font-size: 16px; line-height: 1.55; -webkit-font-smoothing: antialiased; -webkit-tap-highlight-color: transparent; overscroll-behavior-y: none; }
#app { min-height: 100dvh; display: flex; flex-direction: column; }
img, video, canvas { max-width: 100%; display: block; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3 { margin: 0; line-height: 1.08; letter-spacing: -.03em; font-weight: 700; }
:focus-visible { outline: 3px solid var(--pink-800); outline-offset: 3px; }
.hidden { display: none !important; }
.muted { color: var(--grey); }
.big-title { font-family: var(--serif); font-style: italic; font-weight: 500; font-size: clamp(34px, 5.4vw, 60px); letter-spacing: -.025em; line-height: 1.06; }
.step-title { font-family: var(--serif); font-style: italic; font-weight: 500; font-size: clamp(30px, 4.4vw, 48px); letter-spacing: -.025em; line-height: 1.08; text-align: center; }
.step-sub { color: var(--grey); text-align: center; font-size: 17px; margin: 10px auto 0; max-width: 560px; }

/* Boutons : grands, pour le doigt */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 58px; border: 1.5px solid var(--pink); background: var(--pink); color: var(--ink); padding: 14px 34px; border-radius: var(--pill); font-weight: 600; font-size: 17px; text-decoration: none; cursor: pointer; transition: transform .12s, background .15s, opacity .15s; white-space: nowrap; }
.btn:hover { background: var(--pink-300); }
.btn:active { transform: scale(.97); }
.btn[disabled] { opacity: .45; cursor: not-allowed; }
.btn.ghost { background: transparent; border-color: var(--ink); }
.btn.ghost:hover { background: var(--pink-200); }
.btn.quiet { background: transparent; border-color: transparent; color: var(--grey); font-weight: 500; }
.btn.quiet:hover { background: var(--pink-200); }
.btn.sm { min-height: 44px; padding: 8px 20px; font-size: 15px; }
.btn.danger { color: #a3202b; border-color: #e7b9bd; background: #fff; }
.btn svg { width: 22px; height: 22px; flex: none; }

/* Champs */
label.lbl { display: block; font-weight: 600; font-size: 15px; margin: 0 0 8px; }
.input { width: 100%; min-height: 58px; border: 1.5px solid #e6d6d7; background: #fff; border-radius: 16px; padding: 14px 18px; font-size: 18px; outline: none; transition: border-color .15s, box-shadow .15s; }
.pw-wrap { position: relative; display: block; }
.pw-wrap .input { padding-right: 58px; }
.pw-eye { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); width: 46px; height: 46px; display: flex; align-items: center; justify-content: center; border: 0; border-radius: 12px; background: none; color: var(--ink); opacity: .6; cursor: pointer; padding: 0; min-height: 0; box-shadow: none; }
.pw-eye:hover, .pw-eye:focus-visible { opacity: 1; background: var(--pink-200); }
.input:focus { border-color: var(--ink); box-shadow: 0 0 0 4px var(--pink-200); }
.field { margin-bottom: 20px; }
.hint { font-size: 13.5px; color: var(--grey); margin-top: 6px; }
.err { background: #fde2e4; color: #8f1d27; padding: 12px 16px; border-radius: 14px; font-size: 15px; margin-bottom: 16px; }
.ok-note { background: #dff3e7; color: #1d5b35; padding: 12px 16px; border-radius: 14px; font-size: 15px; margin-bottom: 16px; }
.check { display: flex; gap: 12px; align-items: flex-start; font-size: 15px; cursor: pointer; padding: 6px 0; }
.check input { margin-top: 3px; accent-color: var(--ink); width: 22px; height: 22px; flex: none; }
.seg { display: inline-flex; background: var(--pink-200); border-radius: var(--pill); padding: 4px; gap: 2px; flex-wrap: wrap; }
.seg button { border: 0; background: transparent; min-height: 46px; padding: 8px 20px; border-radius: var(--pill); font-weight: 600; font-size: 15px; cursor: pointer; white-space: nowrap; }
.seg button.on { background: var(--ink); color: #fff; }

/* ── Accueil : le fauteuil ───────────────────────────── */
.home { flex: 1; display: grid; grid-template-rows: auto 1fr auto; min-height: 100dvh; background: radial-gradient(100% 70% at 50% 62%, #fff 0, #fff 38%, var(--pink-100) 72%, var(--pink-200) 100%); overflow: hidden; }
.home-top { display: flex; justify-content: center; align-items: center; padding: 22px 20px 0; flex-direction: column; text-align: center; gap: 4px; }
.home-top img { height: 40px; margin-bottom: 14px; }
.home-top p { margin: 6px 0 0; color: var(--grey); font-size: 18px; }
.chair-stage { position: relative; min-height: 300px; cursor: pointer; }
.chair-stage canvas { position: absolute; inset: 0; width: 100% !important; height: 100% !important; }
.chair-hint { position: absolute; left: 50%; bottom: 4%; transform: translateX(-50%); z-index: 2; pointer-events: auto; }
.chair-fallback { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; background: none; border: 0; cursor: pointer; }
.chair-fallback svg { height: 90%; }
.home-nav { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; padding: 8px 16px max(16px, env(safe-area-inset-bottom)); max-width: 720px; width: 100%; margin: 0 auto; }
.home-nav button { display: flex; align-items: center; justify-content: center; gap: 10px; min-height: 64px; background: rgba(255, 255, 255, .85); border: 1px solid var(--pink-200); border-radius: 22px; font-weight: 600; font-size: 15px; cursor: pointer; padding: 8px; }
.home-nav button:hover { background: #fff; border-color: var(--pink); }
.home-nav svg { width: 24px; height: 24px; flex: none; }
.home-nav small { display: block; font-weight: 400; font-size: 12px; color: var(--grey); }
@media (max-width: 520px) { .home-nav button { flex-direction: column; gap: 2px; font-size: 13px; min-height: 76px; text-align: center; } }

/* ── Parcours ────────────────────────────────────────── */
.flow { flex: 1; display: flex; flex-direction: column; min-height: 100dvh; }
.flow-bar { display: flex; align-items: center; gap: 14px; padding: 14px 18px; }
.flow-bar .back { width: 48px; height: 48px; border-radius: 50%; border: 0; background: #fff; box-shadow: var(--shadow); cursor: pointer; display: grid; place-items: center; flex: none; }
.flow-bar .back svg { width: 22px; height: 22px; }
.steps { flex: 1; display: flex; justify-content: center; gap: 6px; }
.steps span { display: flex; align-items: center; gap: 8px; font-size: 14px; color: var(--grey-2); font-weight: 500; }
.steps span i { width: 28px; height: 28px; border-radius: 50%; background: #fff; border: 1.5px solid var(--pink-300); display: grid; place-items: center; font-style: normal; font-size: 13px; font-weight: 600; }
.steps span.on { color: var(--ink); font-weight: 600; }
.steps span.on i { background: var(--pink); border-color: var(--pink); color: var(--ink); }
.steps span.done i { background: var(--ink); border-color: var(--ink); color: #fff; }
.steps span + span::before { content: ''; width: 18px; height: 1.5px; background: var(--pink-300); margin-right: 2px; }
@media (max-width: 680px) { .steps span b { display: none; } }
.steps b { font-weight: inherit; }
.flow-spacer { width: 48px; flex: none; }
.flow-main { flex: 1; width: 100%; max-width: 780px; margin: 0 auto; padding: 10px 20px 28px; display: flex; flex-direction: column; }
.flow-center { justify-content: center; }
.flow-actions { display: flex; justify-content: center; gap: 12px; flex-wrap: wrap; margin-top: 24px; }
.panel { background: #fff; border: 1px solid var(--pink-200); border-radius: 28px; padding: 28px; box-shadow: var(--shadow); }
.welcome-box { width: 100%; max-width: 520px; margin: 24px auto 0; }

/* Photo */
.cam { position: relative; height: min(56dvh, 600px); aspect-ratio: 4 / 5; max-width: 100%; margin: 18px auto 0; border-radius: 34px; overflow: hidden; background: #1c1416; box-shadow: 0 20px 50px rgba(120, 50, 60, .18); }
.cam video { width: 100%; height: 100%; object-fit: cover; }
.cam > img, .cam > canvas { width: 100%; height: 100%; object-fit: contain; background: var(--pink-200); }
.cam.reading video, .cam.reading .cam-oval, .cam.reading .cam-off, .cam.reading .cam-flip { display: none; }
.cam-flip { position: absolute; top: 14px; right: 14px; width: 48px; height: 48px; padding: 12px; border: 0; border-radius: 50%; background: rgba(255, 255, 255, .94); color: var(--ink); cursor: pointer; }
.cam-flip svg { display: block; width: 100%; height: 100%; }
.cam video.mirror { transform: scaleX(-1); }
.cam-oval { position: absolute; inset: 0; pointer-events: none; }
.cam-tip { position: absolute; left: 50%; bottom: 16px; transform: translateX(-50%); background: rgba(255, 255, 255, .94); padding: 8px 18px; border-radius: var(--pill); font-weight: 600; font-size: 15px; white-space: nowrap; max-width: 92%; overflow: hidden; text-overflow: ellipsis; }
.cam-count { position: absolute; inset: 0; display: grid; place-items: center; font-family: var(--serif); font-style: italic; font-size: 130px; color: #fff; text-shadow: 0 4px 30px rgba(0, 0, 0, .35); }
.cam-flash { position: absolute; inset: 0; background: #fff; opacity: 0; pointer-events: none; }
.cam-flash.go { animation: flash .45s ease-out; }
@keyframes flash { 0% { opacity: .95; } 100% { opacity: 0; } }
.cam-off { position: absolute; inset: 0; display: flex; flex-direction: column; gap: 10px; align-items: center; justify-content: center; text-align: center; color: #fff; padding: 28px; font-size: 16px; }
.file-link { position: relative; overflow: hidden; }
.file-link input { position: absolute; inset: 0; opacity: 0; cursor: pointer; font-size: 100px; }
.file-link.off { opacity: .5; pointer-events: none; }

/* Voix */
.voice-orb { position: relative; width: min(66vw, 300px); aspect-ratio: 1; margin: 22px auto 10px; }
.voice-orb canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.voice-num { position: absolute; inset: 0; display: grid; place-items: center; font-family: var(--serif); font-style: italic; font-size: 64px; }
.voice-num small { display: block; font-family: var(--font); font-style: normal; font-size: 14px; color: var(--grey); text-align: center; }
.read-this { font-family: var(--serif); font-style: italic; font-size: clamp(21px, 3vw, 27px); line-height: 1.32; text-align: center; max-width: 620px; margin: 10px auto 0; letter-spacing: -.01em; }

/* Questions */
.q-progress { height: 8px; background: var(--pink-200); border-radius: 100px; overflow: hidden; max-width: 420px; width: 100%; margin: 0 auto 20px; }
.q-progress i { display: block; height: 100%; background: var(--pink-800); border-radius: 100px; transition: width .3s; }
.choices { display: grid; gap: 14px; margin-top: 26px; }
.choices.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 560px) { .choices.two { grid-template-columns: minmax(0, 1fr); } }
.choice { text-align: left; background: #fff; border: 2px solid var(--pink-200); border-radius: 26px; padding: 26px; cursor: pointer; min-height: 130px; transition: border-color .15s, background .15s, transform .12s; }
.choice:hover { border-color: var(--pink); }
.choice:active { transform: scale(.985); }
.choice.on { background: var(--pink); border-color: var(--pink); }
.choice b { display: block; font-size: 21px; letter-spacing: -.02em; line-height: 1.2; margin-bottom: 6px; }
.choice span { color: var(--grey); font-size: 15.5px; }
.choice.on span { color: var(--ink-2); }
.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; margin-top: 22px; }
.tile { background: #fff; border: 2px solid var(--pink-200); border-radius: 20px; min-height: 76px; padding: 12px; font-weight: 600; font-size: 15.5px; cursor: pointer; line-height: 1.25; }
.tile.on { background: var(--pink); border-color: var(--pink); }
.tile svg { display: block; margin: 0 auto 6px; height: 54px; width: auto; }
.tile small { display: block; font-weight: 400; color: var(--grey); font-size: 12.5px; margin-top: 2px; }
.block { margin-top: 24px; }
.block > h3 { font-size: 18px; letter-spacing: -.02em; margin-bottom: 10px; }
.block .tiles { margin-top: 0; }
.tiles.shapes { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.tiles.sm { grid-template-columns: repeat(auto-fill, minmax(112px, 1fr)); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { border: 1.5px solid #e6d6d7; background: #fff; min-height: 44px; padding: 8px 16px; border-radius: var(--pill); font-size: 14.5px; font-weight: 500; cursor: pointer; }
.chip.on { background: var(--ink); color: #fff; border-color: var(--ink); }
.switch-row { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--pink-200); cursor: pointer; font-weight: 500; }
.switch-row:last-child { border-bottom: 0; }
.switch-row input { position: absolute; opacity: 0; }
.track { width: 54px; height: 32px; border-radius: var(--pill); background: #ddd; position: relative; transition: background .2s; flex: none; }
.track::after { content: ''; position: absolute; top: 3px; left: 3px; width: 26px; height: 26px; border-radius: 50%; background: #fff; transition: transform .2s; box-shadow: 0 1px 3px rgba(0, 0, 0, .25); }
.switch-row input:checked + .track { background: var(--ink); }
.switch-row input:checked + .track::after { transform: translateX(22px); }
.switch-row input:focus-visible + .track { outline: 3px solid var(--pink-800); outline-offset: 2px; }
.levels { display: grid; grid-template-columns: repeat(10, minmax(0, 1fr)); gap: 4px; }
.level { aspect-ratio: 1; border-radius: 50%; border: 3px solid transparent; cursor: pointer; padding: 0; color: #fff; font-size: 13px; font-weight: 600; text-shadow: 0 1px 2px rgba(0, 0, 0, .5); }
.level.on { outline: 3px solid var(--ink); outline-offset: 1px; }
.ai-note { display: flex; gap: 10px; background: var(--pink-200); border-radius: 16px; padding: 12px 16px; font-size: 14.5px; margin-top: 14px; }
.proposed { font-size: 13px; color: var(--rose-text); font-weight: 500; font-weight: 600; margin-left: 8px; letter-spacing: 0; }

/* Analyse en cours */
.scan { position: relative; width: min(74vw, 340px); aspect-ratio: 4 / 5; margin: 24px auto; border-radius: 30px; overflow: hidden; box-shadow: 0 20px 50px rgba(120, 50, 60, .2); background: #eee; }
.scan img, .scan canvas { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.scan-line { position: absolute; left: 0; right: 0; height: 90px; top: -90px; background: linear-gradient(180deg, transparent, rgba(247, 202, 205, .65)); border-bottom: 2px solid #fff; animation: scan 2.6s ease-in-out infinite; }
@keyframes scan { 0% { top: -90px; } 100% { top: 100%; } }
.scan-steps { list-style: none; margin: 8px auto 0; padding: 0; max-width: 420px; width: 100%; }
.scan-steps li { display: flex; align-items: center; gap: 12px; padding: 7px 0; color: var(--grey-2); font-size: 16px; transition: color .25s; }
.scan-steps li i { width: 24px; height: 24px; border-radius: 50%; border: 2px solid var(--pink-300); flex: none; display: grid; place-items: center; }
.scan-steps li.on { color: var(--ink); font-weight: 600; }
.scan-steps li.on i { border-color: var(--pink-800); border-right-color: transparent; animation: spin 1s linear infinite; }
.scan-steps li.done { color: var(--ink); }
.scan-steps li.done i { background: var(--ink); border-color: var(--ink); }
.scan-steps li.done i::after { content: ''; width: 9px; height: 5px; border-left: 2px solid #fff; border-bottom: 2px solid #fff; transform: rotate(-45deg) translateY(-1px); }
@keyframes spin { to { transform: rotate(360deg); } }

/* Résultats */
.res { flex: 1; display: flex; flex-direction: column; min-height: 100dvh; }
.res-head { display: flex; align-items: center; gap: 18px; max-width: 1100px; width: 100%; margin: 0 auto; padding: 18px 20px 8px; }
.res-head img { width: 84px; height: 84px; border-radius: 50%; object-fit: cover; border: 4px solid #fff; box-shadow: var(--shadow); flex: none; }
.res-head h1 { font-family: var(--serif); font-style: italic; font-weight: 500; font-size: clamp(24px, 4vw, 42px); letter-spacing: -.02em; }
.res-meta { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.pill { background: #fff; border: 1px solid var(--pink-200); padding: 3px 12px; border-radius: var(--pill); font-size: 13.5px; font-weight: 500; }
.tabs { display: flex; gap: 4px; overflow-x: auto; padding: 8px 20px; max-width: 1100px; width: 100%; margin: 0 auto; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tabs button { flex: none; border: 0; background: transparent; min-height: 50px; padding: 8px 20px; border-radius: var(--pill); font-weight: 600; font-size: 15.5px; cursor: pointer; color: var(--grey); }
.tabs button.on { background: var(--pink); color: var(--ink); }
.res-body { flex: 1; padding: 4px 0 130px; }
.res-body .lv { padding-top: 8px; }
.res-bar { position: fixed; left: 0; right: 0; bottom: 0; background: rgba(255, 255, 255, .95); backdrop-filter: blur(10px); border-top: 1px solid var(--pink-200); padding: 12px 16px max(12px, env(safe-area-inset-bottom)); display: flex; justify-content: center; gap: 8px; flex-wrap: wrap; z-index: 20; }
.res-bar .btn { min-height: 50px; padding: 10px 22px; font-size: 15px; }
.gen-banner { max-width: 794px; margin: 8px auto; padding: 14px 18px; background: #fff; border: 1px solid var(--pink-200); border-radius: 18px; display: flex; align-items: center; gap: 14px; font-size: 15px; }
.gen-banner .btn { margin-left: auto; }
.look-board { max-width: 794px; margin: 8px auto; display: flex; flex-direction: column; align-items: flex-end; gap: 8px; }
.look-board img { width: 100%; display: block; border-radius: 18px; border: 1px solid var(--pink-200); }
.look-pick, .look-more { max-width: 794px; margin: 8px auto; padding: 18px; background: #fff; border: 1px solid var(--pink-200); border-radius: 18px; }
.look-more > summary { cursor: pointer; font-weight: 600; }
.look-more .look-pick { padding: 14px 0 0; border: 0; margin: 0; }
.look-pick-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; }
.look-pick-head h2 { margin: 0; font-size: 18px; }
.look-pick-hint { margin: 8px 0 12px; font-size: 14px; color: var(--ink-2); }
.presets { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-bottom: 14px; }
@media (min-width: 640px) { .presets { grid-template-columns: repeat(5, 1fr); } }
@media (min-width: 860px) { .presets { grid-template-columns: repeat(9, 1fr); } }
.preset { width: 100%; min-width: 0; padding: 0; background: none; border: 0; cursor: pointer; font-size: 13px; line-height: 1.25; text-align: center; }
.preset img { display: block; width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 14px; border: 3px solid transparent; }
.preset span { display: block; margin-top: 4px; }
.preset[aria-pressed="true"] img { border-color: var(--pink-800); }
.preset[aria-pressed="true"] span { font-weight: 600; }
.look-pick textarea { width: 100%; min-height: 64px; resize: vertical; }
.trial-h { margin: 14px 0 8px; font-size: 15px; }
.trial-dirs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 4px; }
.trial-high { display: flex; flex-wrap: wrap; gap: 8px 22px; margin-bottom: 12px; }
.trials { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; margin-bottom: 12px; }
.trial { margin: 0; font-size: 14px; }
.trial img { display: block; width: 100%; border-radius: 14px; }
.trial figcaption { margin: 6px 0; }
.look-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 10px; max-width: 794px; margin: 12px auto 8px; }
.dot-spin { width: 22px; height: 22px; border-radius: 50%; border: 3px solid var(--pink); border-right-color: transparent; animation: spin 1s linear infinite; flex: none; }
@media (max-width: 620px) {
  .res-head { padding-top: 12px; gap: 12px; }
  .res-head img { width: 64px; height: 64px; }
  .res-body { padding-bottom: 170px; }
  .res-bar { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); padding-top: 10px; }
  .res-bar .btn { min-height: 46px; padding: 8px 10px; font-size: 14px; white-space: normal; line-height: 1.15; }
  .res-bar #fin { grid-column: 1 / -1; }
  .client { flex-wrap: wrap; }
  .client .txt { flex-basis: calc(100% - 78px); }
  .client .btn { flex: 1; padding: 8px 6px; }
  .tiles.shapes { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* Fenêtres */
.modal-back { position: fixed; inset: 0; z-index: 50; background: rgba(40, 20, 24, .4); display: flex; align-items: center; justify-content: center; padding: 16px; }
.modal { background: #fff; border-radius: 28px; padding: 28px; width: 100%; max-width: 480px; }
.modal h2 { font-family: var(--serif); font-style: italic; font-weight: 500; font-size: 30px; margin-bottom: 12px; }

/* Pages de gestion */
.page-head { display: flex; align-items: center; gap: 14px; padding: 16px 20px; max-width: 1000px; width: 100%; margin: 0 auto; }
.page-head h1 { font-family: var(--serif); font-style: italic; font-weight: 500; font-size: clamp(28px, 4vw, 40px); }
.page-head .back { width: 48px; height: 48px; border-radius: 50%; border: 0; background: #fff; box-shadow: var(--shadow); cursor: pointer; display: grid; place-items: center; flex: none; }
.page-head .back svg { width: 22px; height: 22px; }
.page-body { max-width: 1000px; width: 100%; margin: 0 auto; padding: 0 20px calc(40px + env(safe-area-inset-bottom)); }
.client { display: flex; align-items: center; gap: 16px; width: 100%; text-align: left; background: #fff; border: 1px solid var(--pink-200); border-radius: 22px; padding: 12px 18px; margin-bottom: 10px; }
.client img { width: 62px; height: 62px; border-radius: 50%; object-fit: cover; flex: none; background: var(--pink-200); }
.client .txt { flex: 1; min-width: 0; }
.client b { display: block; font-size: 18px; letter-spacing: -.01em; }
.client small { display: block; color: var(--grey); font-size: 13.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.found-t { margin: 0 0 6px; font-size: 14px; font-weight: 600; }
.found-hit { display: block; width: 100%; text-align: left; background: #fff; border: 1px solid var(--pink-300); border-radius: 14px; padding: 10px 14px; margin-bottom: 6px; cursor: pointer; }
.found-hit:hover, .found-hit:focus-visible { background: var(--pink-200); }
.found-hit b { display: block; }
.found-hit small { color: var(--grey); font-size: 13.5px; }
.found-linked { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; background: var(--pink-200); border-radius: 14px; padding: 10px 14px; margin-bottom: 12px; font-size: 15px; }
.cf-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 10px; margin-bottom: 14px; }
.cf-actions .btn { flex: 1 1 150px; }
.cf-form { margin-bottom: 22px; }
.cf-form h2, .cf-history h2 { margin: 0 0 12px; font-size: 20px; }
.cf-form textarea { width: 100%; min-height: 130px; resize: vertical; }
.cf-two { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 0 14px; }
.cf-end { display: flex; justify-content: flex-end; margin-top: 26px; }
.loy-find { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 12px; margin-bottom: 8px; }
.loy-find .field { flex: 1 1 280px; margin: 0; }
.loy-tools { display: flex; flex-wrap: wrap; gap: 8px; }
.loy-row { display: flex; align-items: center; justify-content: space-between; gap: 14px; width: 100%; min-height: 62px; text-align: left; background: #fff; border: 1px solid var(--pink-200); border-radius: 18px; padding: 10px 18px; margin-bottom: 8px; cursor: pointer; font: inherit; color: inherit; }
.loy-row:hover, .loy-row:focus-visible { background: var(--pink-200); }
.loy-row b, .loy-row small { display: block; }
.loy-row small { color: var(--grey); font-size: 13.5px; }
.loy-row em { flex: none; font-style: normal; font-weight: 600; }
.loy-new { margin-top: 4px; }
.loy-start { margin-top: 12px; text-align: center; }
.loy-start h2 { margin: 0 0 6px; }
.loy-today { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin: 18px 0; }
.loy-today div { background: var(--pink-200); border-radius: 18px; padding: 14px 16px; }
.loy-today dt { font-size: 13.5px; color: var(--ink-2); }
.loy-today dd { margin: 2px 0 0; font-size: 30px; font-weight: 700; letter-spacing: -.02em; }
.loy-sec { margin-top: 26px; }
.loy-sec h2 { margin: 0 0 10px; font-size: 19px; }
.loy-top { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.loy-top h2 { margin: 0; font-size: 26px; letter-spacing: -.02em; }
.linkish { background: none; border: 0; padding: 4px 0; color: var(--rose-text); text-decoration: underline; cursor: pointer; font: inherit; font-size: 14.5px; }
.loy-score { text-align: right; flex: none; }
.loy-score b { display: block; font-size: 52px; line-height: 1; letter-spacing: -.03em; }
.loy-score span { font-size: 14px; color: var(--ink-2); }
.loy-bar { height: 12px; border-radius: 6px; background: var(--pink-200); overflow: hidden; margin: 14px 0 6px; }
.loy-bar i { display: block; height: 100%; background: var(--pink-800); border-radius: 6px; }
.loy-next { margin: 0 0 14px; font-size: 15px; }
.loy-done { display: flex; align-items: center; justify-content: space-between; gap: 12px; background: #dff3e7; color: #1d5b35; border-radius: 16px; padding: 12px 16px; margin-bottom: 14px; }
.loy-done span > b, .loy-done small { display: block; }
.loy-unlock { margin-top: 3px; }
.loy-earn { padding: 22px; }
.loy-amt { font-size: 24px; font-weight: 600; }
.loy-go { width: 100%; white-space: normal; }
.loy-other { margin-top: 14px; }
.loy-other > summary { cursor: pointer; font-size: 15px; font-weight: 500; }
.loy-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0; }
.loy-inline { display: flex; gap: 8px; align-items: center; }
.loy-inline .input { flex: 1; min-width: 0; }
.loy-gift { display: flex; align-items: center; gap: 14px; min-height: 58px; border-top: 1px solid var(--pink-200); padding: 8px 0; color: var(--grey); }
.loy-gift b { flex: none; width: 58px; font-size: 19px; }
.loy-gift span { flex: 1; min-width: 0; }
.loy-gift small { flex: none; }
.loy-gift.on { color: var(--ink); }
.loy-gift.on b { color: var(--rose-text); }
.loy-cardbtns { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.loy-move { display: flex; align-items: center; gap: 12px; border-top: 1px solid var(--pink-200); padding: 9px 0; }
.loy-move span { flex: 1; min-width: 0; }
.loy-move small { display: block; color: var(--grey); font-size: 13px; }
.loy-move > b { flex: none; }
.loy-move.off span, .loy-move.off > b { text-decoration: line-through; opacity: .55; }
.loy-move.off small { text-decoration: none; }
.loy-fix { margin-top: 12px; }
.loy-qr svg { display: block; width: 100%; max-width: 280px; margin: 12px auto; }
.loy-scan video { display: block; width: 100%; border-radius: 16px; background: var(--ink); margin-top: 12px; }
.loy-rw { display: grid; grid-template-columns: 96px 1fr auto; gap: 8px; align-items: center; margin-bottom: 8px; }
.loy-empty { text-align: center; padding: 12px 0 18px; }
.loy-ex { margin: 4px 0 0; font-weight: 500; }
.cf-points { flex: 1 1 100%; font-size: 16px; }
.cf-points b { font-size: 26px; letter-spacing: -.02em; }
.card-body { background: var(--pink-100); }
.fc { max-width: 460px; margin: 0 auto; padding: 32px 18px 48px; }
.fc h1 { margin: 2px 0 16px; font-size: 32px; letter-spacing: -.02em; }
.fc h2 { margin: 26px 0 8px; font-size: 19px; }
.fc-salon { margin: 0; color: var(--rose-text); font-weight: 600; }
.fc-points b { font-size: 76px; line-height: 1; letter-spacing: -.04em; }
.fc-points span { margin-left: 8px; font-size: 20px; }
.fc-next { margin: 0; }
.fc-qr { margin: 24px 0 0; background: #fff; border: 1px solid var(--pink-200); border-radius: 24px; padding: 20px; text-align: center; }
.fc-qr svg { display: block; width: 100%; max-width: 240px; margin: 0 auto 8px; }
.fc-list { list-style: none; margin: 0; padding: 0; }
.fc-list li { display: flex; align-items: center; gap: 12px; border-top: 1px solid var(--pink-300); padding: 10px 0; color: var(--grey); }
.fc-list b { flex: none; width: 52px; }
.fc-list span { flex: 1; }
.fc-list small { flex: none; }
.fc-list li.on { color: var(--ink); }
.fc-list li.on small { color: var(--rose-text); font-weight: 600; }
.pwa-tip { position: fixed; left: 12px; right: 12px; bottom: calc(104px + env(safe-area-inset-bottom)); z-index: 20; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 14px; max-width: 620px; margin: 0 auto; background: #fff; border: 1px solid var(--pink-300); border-radius: 18px; padding: 12px 16px; box-shadow: var(--shadow); font-size: 15px; }
.pwa-tip span { flex: 1 1 220px; }
.pwa-tip div { display: flex; gap: 6px; }
.pwa-help ol { margin: 12px 0; padding-left: 22px; }
.pwa-help li { margin-bottom: 8px; }
.pwa-help svg { vertical-align: -4px; }
.empty { text-align: center; padding: 60px 20px; color: var(--grey); }
.empty .btn { margin-top: 16px; }
.settings-group { margin-bottom: 18px; }
.settings-group h2 { font-size: 20px; margin-bottom: 14px; }
.grid2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 0 16px; }
.soon { text-align: center; padding: 40px 24px; max-width: 560px; margin: 20px auto; }
.soon ul { text-align: left; color: var(--ink-2); margin: 16px auto 0; padding-left: 20px; max-width: 420px; }
.auth { flex: 1; display: flex; align-items: center; justify-content: center; padding: 24px 16px; min-height: 100dvh; }
.auth-box { width: 100%; max-width: 440px; }
.auth-box img { height: 44px; margin: 0 auto 20px; }
.auth-box h1 { font-family: var(--serif); font-style: italic; font-weight: 500; font-size: 36px; text-align: center; margin-bottom: 18px; }
.toast { position: fixed; left: 50%; bottom: 96px; transform: translateX(-50%); background: var(--ink); color: #fff; padding: 12px 22px; border-radius: 18px; width: max-content; font-size: 15px; z-index: 60; max-width: 92vw; text-align: center; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
@media print { #app > *:not(.res) { display: none; } }
.auth-links { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-top: 16px; font-size: 15px; }
.auth-links:has(> :only-child) { justify-content: center; }
.link { background: none; border: 0; padding: 0; font: inherit; color: var(--rose-text); text-decoration: underline; cursor: pointer; }
.auth-links a { color: var(--rose-text); }
.sub-lines { margin: 0 0 14px; }
.sub-lines > div { display: flex; justify-content: space-between; gap: 14px; padding: 7px 0; border-bottom: 1px solid var(--pink-100); }
.sub-lines dt { color: var(--grey); }
.sub-lines dd { margin: 0; font-weight: 500; text-align: right; }
.field > span.lbl { display: block; }

/* Diagnostic : chaque étape tient sur un écran, en téléphone comme en tablette. */
.flow { flex: none; height: 100dvh; min-height: 0; overflow: hidden; }
.flow-bar { flex: none; padding: 10px 14px; }
.flow-main { min-height: 0; padding: 4px 16px 16px; }
.flow-actions { flex: none; margin-top: auto; padding-top: 12px; }
.flow-actions .btn { min-height: 50px; }
.flow-center .flow-actions { margin-top: 0; }
.flow .step-title { font-size: clamp(24px, 3.4dvh, 40px); }
.flow .step-sub { font-size: 15px; margin-top: 4px; line-height: 1.35; }
.step-tabs { flex: none; display: flex; gap: 2px; width: 100%; max-width: 620px; margin: 10px auto 0; padding: 3px; background: #fff; border: 1px solid var(--pink-200); border-radius: 100px; }
.step-tabs button { flex: 1 1 0; min-width: 0; min-height: 40px; padding: 0 2px; border: 0; border-radius: 100px; background: transparent; color: var(--ink); font: inherit; font-size: 13.5px; font-weight: 600; cursor: pointer; }
.step-tabs button.on { background: var(--ink); color: #fff; }
.pane { flex: 1; min-height: 0; padding-top: 12px; }
.pane > .block:first-child { margin-top: 0; }
.pane.hidden { display: none; }
.flow .block { margin-top: 14px; }
.flow .block > h3 { font-size: 15.5px; margin-bottom: 7px; }
.flow .tiles { margin-top: 0; gap: 8px; }
.flow .tile { min-height: 52px; padding: 8px; font-size: 14.5px; border-radius: 14px; line-height: 1.2; }
.flow .tile svg { height: 42px; margin-bottom: 3px; }
.flow .tiles.shapes { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.flow .tiles.shapes .tile { font-size: 12.5px; padding: 6px 2px; }
.flow .tiles.shapes .tile svg { height: 46px; }
.flow .chips { gap: 6px; }
.flow .chip { min-height: 38px; padding: 5px 12px; font-size: 14px; }
.flow .panel.rows { padding: 2px 16px; border-radius: 16px; }
.flow .switch-row { padding: 9px 0; font-size: 15px; }
.flow .levels { max-width: 460px; }
.flow .hint { font-size: 13.5px; margin-top: 6px; }
.flow .ai-note { font-size: 14px; margin-bottom: 10px; }
.flow .read-this { font-size: clamp(17px, 2.6dvh, 25px); margin-top: 6px; }
.flow .voice-orb { flex: 1 1 0; min-height: 0; width: auto; max-width: 100%; aspect-ratio: 1; margin: 8px auto 2px; }
.flow .cam { flex: 1 1 0; min-height: 0; height: auto; width: auto; max-width: 100%; aspect-ratio: 4 / 5; margin: 10px auto 0; border-radius: 24px; }
.flow .scan { width: auto; max-width: 100%; flex: 1 1 0; min-height: 0; margin: 12px auto; border-radius: 22px; }
.flow .scan-steps { flex: none; margin-top: 0; }
.flow .scan-steps li { padding: 3px 0; font-size: 14.5px; }
.flow .choices { gap: 10px; margin-top: 14px; }
.flow .choice { min-height: 0; padding: 14px 16px; border-radius: 18px; }
.flow .choice b { font-size: 17px; margin-bottom: 3px; }
.flow .choice span { font-size: 14px; line-height: 1.35; display: block; }
.flow .q-progress { flex: none; margin-bottom: 10px; }
.welcome-box { flex: 1; min-height: 0; max-width: 520px; margin: 0 auto; display: flex; flex-direction: column; }
.welcome-box .field { margin-bottom: 12px; }
.welcome-box .check { font-size: 14.5px; line-height: 1.4; margin-bottom: 12px; }
.welcome-box .err { margin-top: 10px; }
@media (max-height: 700px) {
  .flow-bar { padding: 6px 12px; }
  .flow-bar .back { width: 42px; height: 42px; }
  .flow .step-title { font-size: 22px; }
  .flow .step-tabs { margin-top: 7px; }
  .flow .step-tabs button { min-height: 36px; font-size: 13px; }
  .flow .pane { padding-top: 9px; }
  .flow .block { margin-top: 10px; }
  .flow .chip { min-height: 34px; padding: 3px 10px; font-size: 13.5px; }
  .flow .chips { gap: 5px; }
  .flow .flow-actions { padding-top: 8px; }
  .flow .flow-actions .btn { min-height: 46px; }
  .flow-main { padding-bottom: 10px; }
}
@media (max-width: 420px) { .flow .tiles.shapes .tile { font-size: 11.5px; } }
@media (min-width: 700px) and (min-height: 860px) {
  .step-tabs button { min-height: 50px; font-size: 16px; }
  .pane { padding-top: 26px; }
  .flow .block { margin-top: 26px; }
  .flow .block > h3 { font-size: 20px; margin-bottom: 12px; }
  .flow .chips { gap: 10px; }
  .flow .chip { min-height: 50px; padding: 8px 20px; font-size: 17px; }
  .flow .tile { min-height: 84px; font-size: 17px; border-radius: 20px; }
  .flow .tile svg { height: 64px; }
  .flow .tiles.shapes .tile { font-size: 15px; }
  .flow .tiles.shapes .tile svg { height: 76px; }
  .flow .switch-row { padding: 15px 0; font-size: 17px; }
  .flow .choice { padding: 26px; }
  .flow .choice b { font-size: 21px; }
  .flow .choice span { font-size: 16px; }
  .welcome-box .check { font-size: 16.5px; }
}

/* Validation de l'analyse */
.axes-pick { display: grid; gap: 14px; }
.axis-pick { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.axis-pick .chip { width: 100%; justify-content: center; }
.axis-pick small { grid-column: 1 / -1; color: #6d6675; font-size: 13px; }
.proposed { margin-left: 8px; font-size: 12px; font-weight: 500; color: var(--rose-text); }

/* Avis des clients : le salon filtre, le client note */
.fc-rate { margin: 18px 0 0; text-align: center; }
.fc-rate a:not(.btn) { color: var(--rose-text); }
.rev-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.rev-chip { min-height: 40px; padding: 8px 14px; border: 1px solid var(--pink-300); border-radius: var(--pill); background: #fff; color: var(--ink); font: inherit; font-size: 14px; cursor: pointer; }
.rev-chip small { color: var(--grey); }
.rev-chip.on { background: var(--ink); border-color: var(--ink); color: #fff; }
.rev-chip.on small { color: #fff; }
.rev-dates { margin-top: 14px; }
.rev-dates[hidden] { display: none; }
.rev-sum { margin: 20px 0 8px; }
.rev-avg { margin-bottom: 14px; }
.rev-avg b { font-size: 48px; line-height: 1; letter-spacing: -.03em; }
.rev-avg span { margin-left: 8px; color: var(--grey); }
.rev-live { margin: 10px 0 0; font-size: 13px; color: var(--grey); }
.rev-item { padding: 16px 0; border-top: 1px solid var(--pink-200); }
.rev-item header { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.rev-score, .rate-star { color: #b98519; }
.rev-score { font-size: 19px; letter-spacing: 1px; }
.rev-item p { margin: 8px 0; overflow-wrap: anywhere; white-space: pre-line; }
.rev-item small { color: var(--grey); }
.rev-none { margin-top: 18px; }
.rate-stars { display: flex; flex-direction: row-reverse; justify-content: center; gap: 2px; margin: 16px 0 20px; border: 0; padding: 0; }
.rate-stars input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.rate-star { display: block; padding: 2px 5px; font-size: 44px; line-height: 1; color: #dcd3cf; cursor: pointer; }
.rate-stars input:checked ~ .rate-star, .rate-star:hover, .rate-star:hover ~ .rate-star { color: #b98519; }
.rate-stars input:focus-visible + .rate-star { outline: 2px solid var(--ink); border-radius: 8px; }
.rate-note { color: var(--grey); font-size: 14px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.search-scan { display: flex; gap: 8px; }
.search-scan .input { flex: 1; min-width: 0; }
.scan-btn { flex: none; width: 58px; height: 58px; display: grid; place-items: center; border: 1.5px solid #e6d6d7; border-radius: 16px; background: #fff; color: var(--ink); cursor: pointer; }
.scan-btn:hover { border-color: var(--ink); }
.scan-btn:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.scan-btn svg { width: 26px; height: 26px; }
.fc-rate .btn { max-width: 100%; height: auto; min-height: 50px; padding-top: 10px; padding-bottom: 10px; white-space: normal; text-align: center; line-height: 1.3; }
@media (max-width: 560px) {
  .loy-rw { grid-template-columns: 84px minmax(0, 1fr); }
  .loy-rw [data-rm] { grid-column: 2; justify-self: end; }
}
body:has(.flow) #supportchat-frame, body:has(.res) #supportchat-frame, body:has(.home) #supportchat-frame, body:has(.modal-back) #supportchat-frame { display: none; }
body:has(#supportchat-frame) .page-body { padding-bottom: 110px; }
