/* Charte J&A Agency (variables reprises du site v3 en ligne, relevées le 2026-11-07) */
:root {
  --dark: #01153A;
  --dark-2: #0A2560;
  --dark-line: rgba(255, 255, 255, .12);
  --accent: #054FF5;
  --accent-deep: #0340C8;
  --accent-glow: #3D7BFF;
  --accent-soft: #E1EAFE;
  --pop: #F43392;          /* décor seulement, jamais sous du texte */
  --pop-ink: #D81E7C;      /* texte blanc sur rose : 4,78 */
  --pop-press: #B91868;
  --ink: #01153A;
  --ink-2: #48566F;
  --ink-3: #8A93A6;
  --bg: #FFFFFF;
  --bg-2: #F4F4F7;
  --line: #DDE0E6;
  --sur-sombre: rgba(255, 255, 255, .72);
  --radius: 6px;
  --ease: cubic-bezier(.22, .61, .36, 1);
  --font: "Inter", -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", sans-serif;
  --gutter: clamp(16px, 5vw, 72px);
  --maxw: 1240px;
  --dock: clamp(320px, 30vw, 420px);
  --duree: .7s;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--font); color: var(--ink); background: var(--dark); line-height: 1.5; -webkit-font-smoothing: antialiased; }
body[data-etat="site"] { background: var(--bg); }
button, textarea { font: inherit; color: inherit; }
img { max-width: 100%; height: auto; display: block; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
:focus-visible { outline: 2px solid var(--accent-glow); outline-offset: 2px; }

/* ---------- Murphy ---------- */
.murphy {
  position: fixed; z-index: 20; top: 0; right: 0; bottom: 0; width: 100%;
  display: flex; flex-direction: column; align-items: center;
  color: #fff;
  background:
    radial-gradient(120% 70% at 50% -10%, rgba(5, 79, 245, .45), transparent 60%),
    radial-gradient(60% 40% at 90% 110%, rgba(244, 51, 146, .18), transparent 70%),
    var(--dark);
  padding: max(24px, env(safe-area-inset-top)) var(--gutter) max(20px, env(safe-area-inset-bottom));
  transition: width var(--duree) var(--ease), padding var(--duree) var(--ease), height var(--duree) var(--ease);
}
.murphy > * { width: 100%; max-width: 680px; }

.murphy-tete { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.poignee { display: flex; align-items: center; gap: 12px; background: none; border: 0; padding: 0; cursor: default; text-align: left; }
.ident { display: flex; flex-direction: column; line-height: 1.25; }
.ident strong { font-weight: 700; font-size: 15px; letter-spacing: .01em; }
.ident span { font-size: 13px; color: var(--sur-sombre); }
.chevron { display: none; }
.orbe {
  width: 36px; height: 36px; border-radius: 50%; flex: none;
  background: radial-gradient(circle at 35% 30%, #fff 0 8%, var(--accent-glow) 30%, var(--accent) 60%, var(--pop) 120%);
  box-shadow: 0 0 0 1px rgba(255,255,255,.18), 0 0 24px rgba(61, 123, 255, .55);
  animation: respire 4s var(--ease) infinite;
}
@keyframes respire { 50% { transform: scale(1.06); box-shadow: 0 0 0 1px rgba(255,255,255,.25), 0 0 34px rgba(61, 123, 255, .75); } }
.badge-simulation { white-space: nowrap; flex: none; font-size: 12px; font-weight: 600; padding: 4px 10px; border-radius: 99px; background: rgba(255,255,255,.1); color: var(--sur-sombre); border: 1px solid var(--dark-line); }

.porte-logo { display: flex; justify-content: center; margin: clamp(16px, 5vh, 48px) 0 clamp(12px, 3vh, 28px); }
.porte-logo img { width: clamp(96px, 14vw, 132px); background: #fff; border-radius: var(--radius); padding: 10px 14px; }

.fil { flex: 1 1 auto; overflow-y: auto; display: flex; flex-direction: column; gap: 14px; padding: 8px 2px 16px; scroll-behavior: smooth; overscroll-behavior: contain; }
.msg { max-width: 92%; white-space: pre-line; animation: entre .45s var(--ease) both; }
.msg p { margin: 0 0 .6em; } .msg p:last-child { margin: 0; }
.msg.murphy-msg { align-self: flex-start; font-size: clamp(18px, 2.2vw, 22px); line-height: 1.45; letter-spacing: -.005em; }
.msg.murphy-msg:nth-child(-n+2) { font-size: clamp(24px, 3.4vw, 34px); line-height: 1.22; font-weight: 600; letter-spacing: -.02em; }
.msg.murphy-msg:nth-child(2) { color: #8FB0FF; }
.msg.visiteur { align-self: flex-end; background: var(--accent); color: #fff; padding: 10px 16px; border-radius: 18px 18px 4px 18px; font-size: 16px; }
.msg.note { align-self: center; font-size: 13px; color: var(--sur-sombre); border: 1px solid var(--dark-line); border-radius: 99px; padding: 4px 12px; }
.msg.note.ok { color: #fff; background: rgba(5, 79, 245, .35); border-color: transparent; }
@keyframes entre { from { opacity: 0; transform: translateY(8px); } }
.ecrit { align-self: flex-start; display: inline-flex; gap: 5px; padding: 10px 0; }
.ecrit i { width: 7px; height: 7px; border-radius: 50%; background: var(--sur-sombre); animation: point 1.2s infinite; }
.ecrit i:nth-child(2) { animation-delay: .15s; } .ecrit i:nth-child(3) { animation-delay: .3s; }
@keyframes point { 0%, 60%, 100% { opacity: .3; transform: none; } 30% { opacity: 1; transform: translateY(-3px); } }

.suggestions { display: flex; flex-wrap: wrap; gap: 8px; margin: 4px 0 14px; }
.suggestions button { background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.22); color: #fff; border-radius: 99px; padding: 9px 16px; font-size: 15px; cursor: pointer; transition: background .2s, border-color .2s; }
.suggestions button:hover { background: rgba(255,255,255,.14); border-color: rgba(255,255,255,.4); }

.saisie { display: flex; align-items: flex-end; gap: 8px; background: #fff; border-radius: 16px; padding: 8px 8px 8px 18px; box-shadow: 0 10px 40px rgba(0, 0, 0, .25); }
.saisie textarea { flex: 1; border: 0; outline: none; resize: none; background: none; color: var(--ink); font-size: 17px; line-height: 1.45; padding: 8px 0; max-height: 160px; }
.saisie textarea::placeholder { color: var(--ink-3); }
.saisie button { flex: none; width: 44px; height: 44px; border-radius: 12px; border: 0; background: var(--pop-ink); display: grid; place-items: center; cursor: pointer; transition: background .2s, transform .2s; }
.saisie button:hover { background: var(--pop-press); }
.saisie button:disabled { background: var(--ink-3); cursor: wait; }
.saisie svg { width: 22px; height: 22px; fill: none; stroke: #fff; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.mention { font-size: 12.5px; line-height: 1.5; color: var(--sur-sombre); margin: 12px 0 0; text-align: center; }
.mention a { color: #fff; }

/* Murphy en panneau, une fois le site ouvert */
body[data-etat="site"] .murphy { width: var(--dock); padding: 18px 20px max(16px, env(safe-area-inset-bottom)); border-left: 1px solid var(--dark-line); }
body[data-etat="site"] .porte-logo,
body[data-etat="site"] .suggestions { display: none; }
body[data-etat="site"] .msg.murphy-msg:nth-child(2) { color: #fff; }
body[data-etat="site"] .msg.murphy-msg,
body[data-etat="site"] .msg.murphy-msg:nth-child(-n+2) { font-size: 15.5px; line-height: 1.5; font-weight: 400; letter-spacing: 0; }
body[data-etat="site"] .msg.visiteur { font-size: 15px; }
body[data-etat="site"] .fil { margin-top: 14px; }
body[data-etat="site"] .ident span { font-size: 12px; }
body[data-etat="site"] .badge-simulation { font-size: 11px; padding: 3px 8px; }
body[data-etat="site"] .saisie textarea { font-size: 16px; }
body[data-etat="site"] .mention { font-size: 11.5px; text-align: left; }

/* ---------- Site ---------- */
.site { visibility: hidden; opacity: 0; transition: opacity .6s var(--ease) .25s; background: var(--bg); min-height: 100vh; }
.sans-transition, .sans-transition * { transition: none !important; }
body[data-etat="site"] .site { visibility: visible; opacity: 1; margin-right: var(--dock); }

.entete { position: sticky; top: 0; z-index: 5; display: flex; align-items: center; gap: 16px; padding: 10px var(--gutter); min-height: 60px; background: rgba(255,255,255,.94); backdrop-filter: saturate(1.6) blur(14px); -webkit-backdrop-filter: saturate(1.6) blur(14px); border-bottom: 1px solid var(--line); }
.logo img { width: 84px; }
.historique { flex: 1; min-width: 0; display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; justify-content: flex-end; }
.historique::-webkit-scrollbar { display: none; }
.onglet { flex: none; background: var(--bg-2); border: 1px solid transparent; border-radius: 99px; padding: 7px 14px; font-size: 14px; font-weight: 500; color: var(--ink-2); cursor: pointer; white-space: nowrap; transition: background .2s, color .2s; }
.onglet:hover { background: var(--accent-soft); color: var(--accent-deep); }
.onglet[aria-current="page"] { background: var(--ink); color: #fff; cursor: default; }
.bouton-rappel { flex: none; background: var(--pop-ink); color: #fff; border: 0; border-radius: var(--radius); padding: 9px 16px; font-weight: 600; font-size: 15px; cursor: pointer; white-space: nowrap; }
.bouton-rappel:hover { background: var(--pop-press); }

main { outline: none; }
main > section { padding: clamp(48px, 7vw, 96px) var(--gutter); }
main > section.gris { background: var(--bg-2); }
.contenu { max-width: var(--maxw); margin: 0 auto; }
.page-entre { animation: page .55s var(--ease) both; }
@keyframes page { from { opacity: 0; transform: translateY(14px); } }
main[data-type="accueil"] + .pied { display: none; }
.cadre-accueil { display: block; width: 100%; height: calc(100vh - 61px); height: calc(100dvh - 61px); border: 0; }

.hero { padding-top: clamp(56px, 9vw, 120px) !important; background: linear-gradient(180deg, var(--accent-soft), #fff 85%); }
.accroche { display: inline-flex; align-items: center; gap: 10px; margin: 0 0 28px; padding: 6px 16px 6px 6px; background: #fff; border: 1px solid var(--accent-tint); border-radius: 99px; font-size: 15px; color: var(--ink); max-width: 100%; box-shadow: 0 6px 20px rgba(5, 79, 245, .08); }
.accroche[hidden] { display: none; }
.pour-vous { flex: none; background: var(--accent); color: #fff; font-size: 11.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; border-radius: 99px; padding: 5px 10px; }
.surtitre { font-size: 13px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--accent-deep); margin: 0 0 18px; }
.hero h1 { font-size: clamp(34px, 5vw, 64px); line-height: 1.05; letter-spacing: -.035em; font-weight: 800; margin: 0 0 24px; max-width: 20ch; text-wrap: balance; }
.chapeau { font-size: clamp(18px, 1.6vw, 21px); line-height: 1.5; color: var(--ink-2); max-width: 62ch; margin: 0; }

.bloc h2, .exemple h2 { font-size: clamp(25px, 2.8vw, 38px); line-height: 1.15; letter-spacing: -.025em; font-weight: 800; margin: 0 0 clamp(28px, 3.4vw, 48px); max-width: 30ch; text-wrap: balance; }
.cartes { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); gap: clamp(12px, 1.6vw, 20px); }
.carte { background: var(--bg-2); border-radius: 12px; padding: clamp(22px, 2.4vw, 30px); display: flex; flex-direction: column; gap: 10px; }
.carte .num { font-size: 13px; font-weight: 700; color: var(--pop-ink); letter-spacing: .06em; }
.carte h3 { margin: 0; font-size: 19px; line-height: 1.3; letter-spacing: -.01em; }
.carte p { margin: 0; color: var(--ink-2); font-size: 16px; }

/* schéma en chaîne d'étapes (méthode de présentation de l'agence) */
.chaine { list-style: none; margin: 0; padding: 0; display: flex; align-items: flex-start; }
.chaine .etape { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; align-items: center; text-align: center; padding: 0 4px; }
.chaine .haut { height: 30px; display: flex; align-items: flex-end; justify-content: center; margin-bottom: 10px; }
.chaine .lien { flex: none; align-self: flex-start; margin-top: 52px; color: var(--accent); font-size: 20px; display: flex; }
.rond { width: 56px; height: 56px; border-radius: 50%; background: var(--accent); color: #fff; display: grid; place-items: center; font-size: 24px; flex: none; }
.rond.clair { background: var(--accent-soft); color: var(--accent); }
.rond.nuit { background: var(--ink); color: #fff; box-shadow: 0 0 0 4px var(--pop-tint); }
.rond i, .chaine .lien i, .bandeau i, .colonne i { display: flex; line-height: 1; }
.chaine .lib { margin: 14px 0 0; font-size: 17px; font-weight: 700; line-height: 1.25; }
.chaine .sous { margin: 6px 0 0; font-size: 14.5px; line-height: 1.4; color: var(--ink-2); max-width: 22ch; }
.pill { display: inline-block; font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; border-radius: 99px; padding: 5px 10px; white-space: nowrap; }
.pill.rose { background: var(--pop-ink); color: #fff; }
.pill.info { background: var(--accent-soft); color: var(--accent-deep); }
.bandeau { margin: clamp(28px, 3vw, 40px) 0 0; background: var(--ink); color: #fff; border-radius: 12px; padding: 18px 24px; font-size: clamp(16px, 1.4vw, 18px); font-weight: 600; line-height: 1.45; display: flex; align-items: center; gap: 14px; }
.bandeau i { font-size: 22px; color: #8FB0FF; flex: none; }

/* schéma avant / après */
.avant-apres { display: grid; grid-template-columns: 1fr auto 1fr; gap: clamp(12px, 2vw, 24px); align-items: stretch; }
.colonne { border-radius: 12px; padding: clamp(22px, 2.4vw, 30px); }
.colonne.avant { background: var(--bg-2); }
.colonne.apres { background: var(--accent-soft); }
.col-titre { margin: 0 0 16px; font-size: 13px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-2); }
.apres .col-titre { color: var(--accent-deep); }
.colonne ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.colonne li { display: flex; gap: 12px; align-items: flex-start; font-size: 17px; line-height: 1.4; font-weight: 500; }
.colonne li i { flex: none; width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; font-size: 15px; margin-top: 1px; }
.avant li i { background: #fff; color: var(--ink-3); }
.avant li { color: var(--ink-2); }
.apres li i { background: var(--accent); color: #fff; }
.fleche { align-self: center; width: 48px; height: 48px; border-radius: 50%; background: var(--ink); color: #fff; display: grid; place-items: center; font-size: 20px; }

/* le chemin en quatre marches */
.marches { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: clamp(8px, 1.2vw, 14px); align-items: end; }
.marche { position: relative; background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 18px 18px 20px; display: flex; flex-direction: column; justify-content: flex-end; }
.marche.m1 { min-height: 150px; } .marche.m2 { min-height: 190px; } .marche.m3 { min-height: 230px; } .marche.m4 { min-height: 270px; }
.marche .num { font-size: 13px; font-weight: 800; color: var(--accent); margin-bottom: auto; }
.marche .lib { margin: 18px 0 0; font-size: 17px; font-weight: 700; line-height: 1.25; }
.marche .sous { margin: 6px 0 0; font-size: 14.5px; line-height: 1.4; color: var(--ink-2); }
.marche.entree { background: var(--ink); border-color: var(--ink); }
.marche.entree .lib { color: #fff; } .marche.entree .sous { color: var(--sur-sombre); } .marche.entree .num { color: #8FB0FF; }
.marche .pill { position: absolute; top: -12px; left: 14px; }

.exemple { background: var(--dark); color: #fff; }
.exemple .etiquette { font-size: 13px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: #fff; margin: 0 0 14px; display: flex; align-items: center; gap: 10px; }
.exemple .etiquette::before { content: ""; width: 24px; height: 3px; background: var(--pop); border-radius: 2px; }
.exemple h2 { margin-bottom: 16px; }
.texte-exemple { font-size: clamp(18px, 1.6vw, 21px); line-height: 1.55; color: var(--sur-sombre); margin: 0; max-width: 62ch; }

.appel-final { margin-top: clamp(36px, 4vw, 56px); display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px 24px; padding: clamp(24px, 3vw, 36px); background: var(--accent); border-radius: 16px; }
.cta-titre { margin: 0; font-size: clamp(22px, 2.4vw, 32px); font-weight: 800; letter-spacing: -.02em; color: #fff; }
.bouton-murphy { background: #fff; color: var(--ink); border: 0; border-radius: var(--radius); padding: 14px 22px; font-weight: 700; font-size: 16px; cursor: pointer; transition: transform .2s var(--ease); }
.bouton-murphy:hover { transform: translateY(-1px); }

.pied { display: flex; flex-wrap: wrap; gap: 8px 24px; justify-content: space-between; padding: 28px var(--gutter); font-size: 13px; color: var(--ink-2); border-top: 1px solid var(--line); }
.pied a { color: var(--ink-2); }

/* ---------- Téléphone et tablette étroite : Murphy devient une feuille basse ---------- */
@media (max-width: 860px) {
  :root { --feuille: 148px; }
  body[data-etat="site"] .site { margin-right: 0; padding-bottom: calc(var(--feuille) + 12px); }
  body[data-etat="site"] .murphy {
    top: auto; width: 100%; height: var(--feuille); border-left: 0; border-top: 1px solid var(--dark-line);
    border-radius: 18px 18px 0 0; padding: 10px 16px max(12px, env(safe-area-inset-bottom));
    box-shadow: 0 -12px 40px rgba(1, 21, 58, .28);
  }
  body[data-etat="site"] .murphy.deplie { height: min(78vh, 640px); height: min(78dvh, 640px); }
  body[data-etat="site"] .poignee { cursor: pointer; width: 100%; }
  body[data-etat="site"] .chevron { display: block; margin-left: auto; width: 10px; height: 10px; border-right: 2px solid #fff; border-bottom: 2px solid #fff; transform: rotate(-135deg); transition: transform .3s var(--ease); }
  body[data-etat="site"] .murphy.deplie .chevron { transform: rotate(45deg); }
  body[data-etat="site"] .murphy:not(.deplie) .fil { flex: 0 0 auto; margin-top: 4px; padding: 0; overflow: hidden; }
  body[data-etat="site"] .murphy:not(.deplie) .msg { display: none; }
  body[data-etat="site"] .murphy:not(.deplie) .msg.dernier { display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden; font-size: 14px; color: var(--sur-sombre); animation: none; white-space: normal; }
  body[data-etat="site"] .murphy:not(.deplie) .msg.dernier p { display: none; }
  body[data-etat="site"] .murphy:not(.deplie) .msg.dernier p:last-child { display: inline; }
  body[data-etat="site"] .murphy:not(.deplie) .badge-simulation { display: none; }
  body[data-etat="site"] .murphy:not(.deplie) .ecrit { padding: 2px 0; }
  body[data-etat="site"] .murphy:not(.deplie) .mention { display: none; }
  body[data-etat="site"] .murphy:not(.deplie) .saisie { margin-top: 8px; padding: 4px 4px 4px 14px; border-radius: 12px; }
  body[data-etat="site"] .murphy:not(.deplie) .saisie button { width: 38px; height: 38px; }
  body[data-etat="site"] .murphy:not(.deplie) .saisie textarea { padding: 6px 0; }
  .entete { flex-wrap: wrap; gap: 8px 12px; padding: 8px 16px; }
  .historique { order: 3; flex-basis: 100%; justify-content: flex-start; }
  .bouton-rappel { margin-left: auto; }
  .cadre-accueil { height: calc(100vh - 104px - var(--feuille)); height: calc(100dvh - 104px - var(--feuille)); }
  .chaine { flex-direction: column; align-items: stretch; gap: 0; }
  .chaine .etape { display: grid; grid-template-columns: 56px 1fr; grid-template-rows: auto auto auto; column-gap: 16px; text-align: left; align-items: center; padding: 0; }
  .chaine .rond { grid-row: 1 / span 3; grid-column: 1; }
  .chaine .haut { grid-column: 2; grid-row: 1; height: auto; margin: 0 0 4px; justify-content: flex-start; }
  .chaine .haut:empty { display: none; }
  .chaine .lib { grid-column: 2; margin: 0; }
  .chaine .sous { grid-column: 2; max-width: none; }
  .chaine .lien { margin: 6px 0 6px 18px; transform: rotate(90deg); }
  .accroche { border-radius: 14px; align-items: flex-start; padding: 8px 14px 8px 8px; }
  .avant-apres { grid-template-columns: 1fr; }
  .fleche { justify-self: center; transform: rotate(90deg); }
  .marches { grid-template-columns: 1fr 1fr; }
  .marche.m1, .marche.m2, .marche.m3, .marche.m4 { min-height: 0; }
  .marche .num { margin-bottom: 0; }
  .logo img { width: 76px; }
  .bouton-rappel { padding: 8px 12px; font-size: 14px; }
  .msg.visiteur { font-size: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
