/* Accueil — points forts : SIREN, saisie assistée, sécurité.
   Même monde que accueil.css (nuit / beige, serif, bleu unique). Préfixe pf-/sd-/pp-/pi-/po-/pv-
   pour ne rien heurter (la classe .msg appartient déjà au fil du héros). */

/* En-têtes de section */
.pf-head { display: grid; gap: 18px; max-width: 980px; margin-bottom: clamp(36px, 5vw, 56px); }
.pf-head h2 { font-size: clamp(2.5rem, 5.8vw, 5rem); }
.pf-head p, .pf-lead { color: var(--mute-light); font-size: 1.1rem; max-width: 58ch; }
.cream .pf-lead { color: var(--mute-dark); }

/* ---------- 1. Le SIREN suffit ---------- */
.pf-siren { background: radial-gradient(1000px 520px at 15% 0%, #16204a 0%, transparent 60%), var(--night); }
.sd { padding: clamp(18px, 2.4vw, 28px); gap: 22px; }
.sd-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 14px; }
.sd-bar .ex { margin-left: auto; font-size: .64rem; letter-spacing: .14em; text-transform: uppercase; color: var(--mute-light); border: 1px solid var(--line-light); padding: 3px 9px; border-radius: 99px; }
.sd-input { display: inline-flex; align-items: center; gap: 12px; padding: 10px 16px; border: 1px solid rgba(52, 97, 255, .6); border-radius: 10px; background: rgba(52, 97, 255, .08); min-width: 0; }
.sd-input small { font-size: .62rem; font-weight: 600; letter-spacing: .16em; color: #9db4ff; }
.sd-num { font: 500 clamp(1.15rem, 2.2vw, 1.5rem)/1 ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace; letter-spacing: .08em; font-variant-numeric: tabular-nums; min-width: 11ch; }
.sd-caret { width: 2px; height: 1.3em; background: var(--blue); animation: sd-blink 1s steps(1) infinite; }
@keyframes sd-blink { 50% { opacity: 0; } }
.sd-go { font-size: .74rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; padding: 12px 16px; border-radius: 8px; background: var(--blue); color: #fff; transition: transform .15s ease, filter .15s ease; }
.sd-go.press { transform: scale(.94); filter: brightness(1.25); }
.sd-srcs { display: flex; flex-wrap: wrap; gap: 8px; }
.sd-src { display: inline-flex; align-items: center; gap: 8px; font-size: .78rem; color: #6f6c67; border: 1px solid var(--line-light); padding: 6px 12px 6px 8px; border-radius: 99px; transition: color .3s ease, border-color .3s ease; }
.sd-src i { width: 14px; height: 14px; border-radius: 50%; border: 1.5px solid var(--line-light); }
.sd-src.run { color: var(--ink-light); border-color: rgba(52, 97, 255, .6); }
.sd-src.run i { border-color: var(--blue); border-top-color: transparent; animation: spin .8s linear infinite; }
.sd-src.ok { color: var(--ink-light); border-color: rgba(34, 197, 94, .45); }
.sd-src.ok i { background: #22c55e; border-color: #22c55e; }

.sd-body { display: grid; grid-template-columns: .85fr 1.15fr; gap: clamp(16px, 2.4vw, 28px); align-items: stretch; }
.sd-doc { position: relative; background: #f5f2ec; color: #1a1a1a; border-radius: 8px; min-height: 470px; overflow: hidden; box-shadow: 0 30px 60px -30px rgba(0, 0, 0, .8); }
.sd-doc::after { content: ""; position: absolute; inset: auto 0 0; height: 70px; background: linear-gradient(transparent, #f5f2ec); pointer-events: none; }
.sd-doc-in { position: absolute; inset: 0 0 auto; padding: 58px 26px 80px; display: grid; gap: 16px; transition: transform .7s cubic-bezier(.4, .1, .2, 1); font-family: var(--serif); font-size: .92rem; line-height: 1.55; }
.sd-doc h4 { margin: 0; text-align: center; font-family: var(--serif); font-weight: 600; letter-spacing: .3em; font-size: 1.05rem; }
.sd-c { text-align: center; font-size: .82rem; color: #55524d; padding-bottom: 10px; border-bottom: 1px solid #ddd6ca; }
.sd-art h5 { margin: 0 0 4px; font-family: var(--sans); font-size: .66rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: #6b675f; }
.sd-art p { margin: 0; }
.sd-hl { background-image: linear-gradient(rgba(52, 97, 255, .22), rgba(52, 97, 255, .22)); background-repeat: no-repeat; background-size: 100% 100%; transition: background-size .6s ease; border-radius: 2px; }
.sd-doc.playing .sd-hl { background-size: 0 100%; }
.sd-doc.playing .sd-art.on .sd-hl { background-size: 100% 100%; }
.sd-page { position: absolute; z-index: 3; inset: 0 0 auto; display: flex; justify-content: space-between; gap: 12px; font: 600 .62rem/1 var(--sans); letter-spacing: .12em; text-transform: uppercase; color: #6b675f; background: #ebe6dc; padding: 11px 14px; border-bottom: 1px solid #ddd6ca; font-variant-numeric: tabular-nums; }
.sd-page::before { content: "statuts-a-jour.pdf"; letter-spacing: .04em; text-transform: none; font-weight: 500; }
.sd-scan { position: absolute; z-index: 1; left: 0; right: 0; height: 46px; top: -60px; background: linear-gradient(transparent, rgba(52, 97, 255, .16), transparent); border-bottom: 1.5px solid rgba(52, 97, 255, .55); pointer-events: none; }
.sd-doc.playing .sd-scan { animation: sd-scan 1.9s cubic-bezier(.5, 0, .5, 1) infinite; }
@keyframes sd-scan { from { top: -20px; } to { top: 100%; } }

.sd-fields { list-style: none; margin: 0; padding: 0; display: grid; gap: 7px; align-content: start; }
.sd-f { display: grid; grid-template-columns: minmax(110px, 30%) 1fr auto; gap: 12px; align-items: center; padding: 9px 12px; border-radius: 9px; border: 1px solid var(--line-light); font-size: .9rem; min-width: 0; transition: background .5s ease, border-color .5s ease; }
.sd-f small { font-size: .7rem; color: var(--mute-light); letter-spacing: .02em; }
.sd-f b { font-weight: 500; min-width: 0; overflow-wrap: anywhere; position: relative; }
.sd-f em { font-style: normal; font-size: .62rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; white-space: nowrap; padding: 3px 8px; border-radius: 99px; color: var(--mute-light); border: 1px solid var(--line-light); }
.sd-f.st em { color: #b9c8ff; border-color: rgba(52, 97, 255, .5); background: rgba(52, 97, 255, .12); }
/* État vide : un trait gris à la place de la valeur */
.sd-f:not(.on) b { color: transparent; }
.sd-f:not(.on) b::after { content: ""; position: absolute; left: 0; top: 50%; translate: 0 -50%; width: 60%; height: 8px; border-radius: 4px; background: rgba(255, 255, 255, .07); }
.sd-f:not(.on) em { opacity: 0; }
.sd-f.on b { animation: sd-in .45s ease both; }
.sd-f.flash { background: rgba(52, 97, 255, .16); border-color: rgba(52, 97, 255, .6); }
@keyframes sd-in { from { opacity: 0; transform: translateX(-6px); } }
.sd-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 18px 28px; }
.sd-count { display: flex; align-items: center; gap: 14px; }
.sd-count b { font-family: var(--serif); font-weight: 400; font-size: clamp(3rem, 6vw, 4.4rem); line-height: .9; color: var(--blue); font-variant-numeric: tabular-nums; min-width: 2ch; text-align: right; }
.sd-count span { font-size: .78rem; letter-spacing: .1em; text-transform: uppercase; color: var(--mute-light); line-height: 1.4; }
.sd-foot .result { flex: 1 1 320px; }

.pf-trois { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; margin-top: clamp(40px, 6vw, 72px); }
.pf-trois small { font-size: .66rem; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; color: var(--blue); }
.pf-trois b { display: block; font-family: var(--serif); font-weight: 400; font-size: clamp(1.6rem, 2.6vw, 2.1rem); margin: 4px 0 6px; }
.pf-trois p { color: var(--mute-light); font-size: .94rem; max-width: 34ch; }

/* ---------- 2. La saisie assistée ---------- */
.pf-rac .wrap { display: grid; grid-template-columns: .9fr 1.1fr; gap: clamp(32px, 6vw, 90px); align-items: center; }
.pf-rac-txt { display: grid; gap: 18px; min-width: 0; }
.pf-rac h2 { font-size: clamp(2.5rem, 5vw, 4.2rem); }
.pf-tabs { display: grid; gap: 10px; margin-top: 10px; }
.pf-tab { all: unset; box-sizing: border-box; cursor: pointer; position: relative; overflow: hidden; display: grid; grid-template-columns: 44px 1fr; gap: 16px; align-items: center; padding: 14px 16px; border-radius: 12px; border: 1px solid var(--line-dark); background: rgba(255, 255, 255, .35); transition: background .3s ease, border-color .3s ease, color .3s ease; }
.pf-tab:hover { background: rgba(255, 255, 255, .6); }
.pf-tab:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
.pf-tab h3 { font-size: 1.45rem; color: var(--ink-dark); transition: color .3s ease; }
.pf-tab p { font-size: .86rem; color: var(--mute-dark); transition: color .3s ease; }
.pf-ic { width: 44px; height: 44px; border-radius: 10px; display: grid; place-items: center; border: 1px solid var(--line-dark); }
.pf-ic svg { width: 22px; height: 22px; fill: none; stroke: var(--ink-dark); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.pf-tab .bar { position: absolute; left: 0; bottom: 0; height: 3px; width: 0; background: rgba(255, 255, 255, .85); }
.pf-tab.on { background: var(--night); border-color: var(--night); }
.pf-tab.on h3 { color: var(--ink-light); }
.pf-tab.on p { color: var(--mute-light); }
.pf-tab.on .pf-ic { background: var(--blue); border-color: var(--blue); }
.pf-tab.on .pf-ic svg { stroke: #fff; }
.pf-rac.auto .pf-tab.on .bar { animation: fill 9s linear forwards; background: var(--blue); }
.pf-rac.paused .pf-tab.on .bar { animation-play-state: paused; }

.pf-stage { position: relative; min-width: 0; background: #111114; color: var(--ink-light); border-radius: 18px; padding: clamp(18px, 2.4vw, 28px); box-shadow: 0 50px 90px -40px rgba(0, 0, 0, .55); min-height: 520px; }
.pf-pane { display: grid; gap: 18px; align-content: start; }
.pf-pane.on { animation: sd-in .4s ease both; }

/* Profils */
.pp-sel { position: relative; display: grid; gap: 8px; }
.pp-box { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-radius: 10px; border: 1px solid var(--line-light); font-size: .98rem; transition: border-color .3s ease, background .3s ease; }
.pp-box.open { border-color: var(--blue); background: rgba(52, 97, 255, .1); }
.pp-box #pp-nom { flex: 1; min-width: 0; }
.pp-box.vide #pp-nom { color: var(--mute-light); }
.pp-chev { color: var(--mute-light); }
.pp-star { color: #f5b301; }
.pp-star.dim { color: var(--mute-light); }
.pp-menu { position: absolute; z-index: 3; left: 0; right: 0; top: calc(100% + 6px); list-style: none; margin: 0; padding: 6px; border-radius: 12px; background: #1b1b20; border: 1px solid var(--line-light); box-shadow: 0 30px 50px -20px rgba(0, 0, 0, .8); display: grid; gap: 2px; }
.pp-menu li { display: grid; grid-template-columns: 18px 1fr auto; gap: 10px; align-items: center; padding: 10px 12px; border-radius: 8px; font-size: .92rem; transition: background .25s ease; }
.pp-menu li small { font-size: .72rem; color: var(--mute-light); }
.pp-menu li.hl { background: rgba(52, 97, 255, .22); }

/* Pièce d'identité */
.pi-types { display: flex; flex-wrap: wrap; gap: 8px; }
.pi-types span { font-size: .74rem; padding: 5px 12px; border-radius: 99px; border: 1px solid var(--line-light); color: var(--mute-light); transition: all .3s ease; }
.pi-types span.on { background: var(--blue); border-color: var(--blue); color: #fff; }
.pi-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; align-items: center; }
.pi-card { position: relative; overflow: hidden; aspect-ratio: 1.586; max-width: 100%; border-radius: 12px; padding: 12px 14px; color: #1c2a3a; background: linear-gradient(135deg, #e8eef6 0%, #d5e0ee 55%, #e9e2ef 100%); display: grid; grid-template-columns: 30% 1fr; grid-template-rows: auto 1fr auto; gap: 6px 12px; box-shadow: 0 24px 40px -20px rgba(0, 0, 0, .8); }
.pi-top { grid-column: 1 / -1; font: 700 .58rem/1 var(--sans); letter-spacing: .18em; color: #3b4f68; }
.pi-ph { background: #c3cfdf; border-radius: 6px; display: grid; place-items: end center; overflow: hidden; }
.pi-ph svg { width: 80%; fill: #8fa0b8; }
.pi-l { display: grid; gap: 3px; align-content: start; font: 600 .66rem/1.2 var(--sans); }
.pi-l small { display: block; font-weight: 400; font-size: .5rem; color: #5a6b80; letter-spacing: .06em; }
.pi-mrz { grid-column: 1 / -1; font: 500 .56rem/1 ui-monospace, Menlo, Consolas, monospace; letter-spacing: .12em; color: #3b4f68; white-space: nowrap; overflow: hidden; }
.pi-scan { position: absolute; z-index: 2; left: 0; right: 0; height: 30%; top: -35%; background: linear-gradient(transparent, rgba(52, 97, 255, .3)); border-bottom: 2px solid var(--blue); }
.pi-card.scan .pi-scan { animation: pi-scan 1.5s ease-in-out 2; }
@keyframes pi-scan { 0% { top: -35%; } 50% { top: 100%; } 100% { top: -35%; } }
.pi-f .sd-f { grid-template-columns: minmax(96px, 42%) 1fr; }

/* Objet social */
.po-in { display: grid; gap: 8px; }
.po-mots { display: flex; flex-wrap: wrap; gap: 8px; min-height: 36px; padding: 8px; border-radius: 10px; border: 1px solid var(--line-light); }
.po-mots span { font-size: .86rem; padding: 4px 10px; border-radius: 6px; background: rgba(255, 255, 255, .08); animation: sd-in .3s ease both; }
.po-go { justify-self: start; font-size: .78rem; font-weight: 600; letter-spacing: .08em; padding: 10px 16px; border-radius: 8px; background: var(--blue); color: #fff; transition: transform .15s ease, filter .15s ease; }
.po-go.press { transform: scale(.94); filter: brightness(1.25); }
.po-out { background: #f5f2ec; color: #1a1a1a; border-radius: 10px; padding: 18px 20px; min-height: 168px; font-family: var(--serif); font-size: 1.02rem; line-height: 1.6; }
.po-out p.typing::after { content: ""; display: inline-block; width: 2px; height: 1.1em; margin-left: 2px; vertical-align: -2px; background: var(--blue); animation: sd-blink 1s steps(1) infinite; }
.po-meta { display: flex; justify-content: space-between; gap: 12px; font-size: .82rem; color: var(--mute-light); }
.po-meta b { color: #86efac; font-weight: 600; font-variant-numeric: tabular-nums; }

/* ---------- 4. Sécurité ---------- */
.pf-sec { background: radial-gradient(800px 600px at 22% 50%, #121c44 0%, transparent 62%), #08080a; }
.pf-sec .wrap { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(36px, 6vw, 96px); align-items: center; }
.pf-sec-txt { display: grid; gap: 18px; min-width: 0; }
.pf-sec h2 { font-size: clamp(2.6rem, 5.4vw, 4.6rem); }
.pf-gar { list-style: none; margin: 8px 0 0; padding: 0; border-top: 1px solid var(--line-light); }
.pf-gar li { display: grid; grid-template-columns: 22px minmax(0, 1fr); column-gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--line-light); }
.pf-gar li::before { content: "✓"; grid-row: span 2; color: #22c55e; font-weight: 800; }
.pf-gar b { font-family: var(--serif); font-weight: 400; font-size: 1.35rem; line-height: 1.15; }
.pf-gar span { color: var(--mute-light); font-size: .94rem; }

.pf-vault { position: relative; width: min(100%, 440px); justify-self: center; padding-top: 70px; }
.pv-safe { width: 100%; height: auto; display: block; overflow: visible; }
.pv-body { fill: #15151a; stroke: rgba(243, 239, 232, .18); stroke-width: 1.5; }
.pv-slot { fill: #050507; }
.pv-door { fill: #1c1c23; stroke: rgba(52, 97, 255, .55); stroke-width: 2; }
.pv-dial { transform-origin: 130px 138px; }
.pv-dial circle { fill: none; stroke: rgba(243, 239, 232, .35); stroke-width: 2; }
.pv-dial path { stroke: rgba(243, 239, 232, .55); stroke-width: 3; stroke-linecap: round; }
.pv-dial .pv-hub { fill: var(--blue); stroke: none; }
.pv-bolt { fill: rgba(243, 239, 232, .25); }
.pv-docs { position: absolute; top: 0; left: 50%; translate: -50% 0; width: 100%; height: 100px; pointer-events: none; }
.pv-docs span { position: absolute; left: 50%; top: 6px; translate: -50% 0; font-size: .74rem; font-weight: 600; white-space: nowrap; color: var(--ink-dark); background: var(--paper); padding: 8px 12px; border-radius: 4px; box-shadow: 0 10px 20px -8px rgba(0, 0, 0, .7); opacity: 0; }
.pv-badge { position: absolute; left: 50%; bottom: -18px; translate: -50% 0; display: inline-flex; align-items: center; gap: 10px; white-space: nowrap; font-size: .74rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; padding: 10px 16px; border-radius: 99px; background: var(--blue); color: #fff; box-shadow: 0 0 0 8px rgba(52, 97, 255, .16); }
.pv-lock { width: 12px; height: 10px; border-radius: 2px; background: #fff; position: relative; margin-top: 4px; }
.pv-lock::before { content: ""; position: absolute; left: 2px; top: -7px; width: 8px; height: 8px; border: 2px solid #fff; border-bottom: 0; border-radius: 5px 5px 0 0; box-sizing: border-box; }

@media (prefers-reduced-motion: no-preference) {
  .pv-docs span { animation: pv-drop 6s cubic-bezier(.5, 0, .4, 1) infinite; }
  .pv-docs span:nth-child(2) { animation-delay: 2s; }
  .pv-docs span:nth-child(3) { animation-delay: 4s; }
  .pv-dial { animation: pv-turn 6s cubic-bezier(.6, 0, .3, 1) infinite; }
  .pv-badge { animation: pv-pulse 2s ease-out infinite; }
}
@media (prefers-reduced-motion: reduce) { .pv-docs span { opacity: 1; } .pv-docs span:nth-child(1) { left: 22%; } .pv-docs span:nth-child(3) { left: 78%; } }
@keyframes pv-drop {
  0% { opacity: 0; transform: translateY(-14px) rotate(-3deg); }
  8% { opacity: 1; transform: translateY(0) rotate(-3deg); }
  22% { opacity: 1; transform: translateY(70px) rotate(0) scale(.9); }
  30%, 100% { opacity: 0; transform: translateY(84px) scale(.6); }
}
@keyframes pv-turn { 0%, 20% { transform: rotate(0); } 30% { transform: rotate(120deg); } 53% { transform: rotate(120deg); } 63% { transform: rotate(240deg); } 86% { transform: rotate(240deg); } 96%, 100% { transform: rotate(360deg); } }
@keyframes pv-pulse { 0% { box-shadow: 0 0 0 0 rgba(52, 97, 255, .5); } 100% { box-shadow: 0 0 0 16px rgba(52, 97, 255, 0); } }

/* ---------- Écrans étroits ---------- */
@media (max-width: 1000px) {
  .sd-body, .pf-rac .wrap, .pf-sec .wrap { grid-template-columns: 1fr; }
  .sd-doc { min-height: 320px; }
  .pf-stage { min-height: 0; }
  .pf-vault { order: 2; width: min(100%, 340px); }
}
@media (max-width: 640px) {
  .pf-trois { grid-template-columns: 1fr; }
  .sd-f { grid-template-columns: 1fr auto; gap: 2px 10px; }
  .sd-f small { grid-column: 1 / -1; }
  .pi-grid { grid-template-columns: 1fr; }
  .sd-bar .ex { margin-left: 0; }
  .sd-num { min-width: 0; }
  .sd-doc { min-height: 250px; }
  .sd-fields { gap: 5px; }
  .sd-f { padding: 7px 10px; }
  .pf-stage .c-top b { font-size: 1.35rem; }
  .pf-stage .ex { white-space: nowrap; }
}
@media (prefers-reduced-motion: reduce) {
  .sd-caret, .po-out p.typing::after { animation: none; }
}
