/* Les quatre cartes d'usage de l'accueil : titre, scène animée, argumentaire.
   Chaque scène part d'une vraie photo (images préparées par tools/cartes/preparer-images.js),
   sur laquelle apparaissent des fenêtres de l'application. Personnes et profils fictifs ;
   aucune fenêtre n'appelle un service réel. */

/* Gabarit de la carte */
.product-cards .product-card { display: grid; grid-template-rows: 72px 300px 1fr; align-items: stretch; aspect-ratio: auto; min-height: 0; overflow: hidden; isolation: isolate; background: #f2f2f2; color: #151515; }
.product-cards .product-card::before { display: none; }
.product-cards #votre-site { min-height: 670px; }
.product-cards :is(.card-heading, .card-motion-stage, .card-sales) { width: 100%; }
.card-heading { position: relative; z-index: 3; display: flex; align-items: center; padding: 24px 22px; }
.card-heading h3 { margin: 0; font-size: 17px; font-weight: 650; line-height: 1.25; letter-spacing: -.02em; }
.card-motion-stage { position: relative; min-width: 0; overflow: hidden; border-radius: 18px; box-shadow: inset 0 0 0 1px #173b5c08; }
.product-cards .card-sales { align-self: start; padding: 22px; text-align: left; transform: none; }
.product-cards .card-sales > p { max-width: none; margin: 0; font-size: 16px; font-weight: 600; line-height: 1.5; }
.product-cards .card-sales > .card-sales-detail { margin-top: 14px; font-size: 14px; font-weight: 400; }
.product-cards .profile-steps { margin-top: 18px; font-size: 14px; line-height: 1.5; }
.product-cards .profile-steps p { margin: 0 0 10px; font-size: 14px; }
.profile-steps ol { margin: 0; padding-left: 18px; }
.profile-steps li { margin-top: 10px; padding-left: 3px; }
@media (min-width: 1101px) {
 .product-cards { display: flex; align-items: stretch; gap: 18px; }
 .product-cards .product-card { flex: 1 1 0; min-width: 0; }
}
@media (hover: hover) and (prefers-reduced-motion: no-preference) {
 .product-cards .product-card:hover { background: #101e30; color: #fff; }
}
@media (min-width: 1101px) and (hover: hover) and (prefers-reduced-motion: no-preference) {
 .product-cards .product-card.is-revealed { transition: flex-grow 700ms cubic-bezier(.4, 0, .2, 1), background-color 500ms ease, color 500ms ease, box-shadow 500ms ease; }
 .product-cards .product-card.is-revealed:hover { flex-grow: 1.28; transform: none; box-shadow: 0 16px 36px #102c4530; }
}
/* Une scène a besoin de largeur : deux colonnes en dessous de 1100 px, une seule en dessous de 700 px. */
@media (max-width: 1100px) { .product-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); } .product-cards .product-card { grid-template-rows: 72px 400px 1fr; } }
@media (max-width: 700px) { .product-cards { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 540px) {
 .product-cards .product-card { grid-template-rows: auto 400px auto; }
 .product-cards #votre-site { min-height: 0; }
}

/* Scène. L'état de base est la composition finale : c'est ce qu'on voit sur mobile
   et avec réduction des animations. Au survol, cards-motion.js joue la séquence
   depuis la photo seule, puis la rembobine. */
.scene { position: absolute; inset: 0; overflow: hidden; container-type: size; background: #d9d4cc; }
.scene-photo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% var(--photo-y, 45%); transform-origin: var(--focus, 50% 50%); }

/* Fenêtres en verre dépoli, à la manière des notifications système. */
.scene-stack { position: absolute; z-index: 1; display: grid; gap: 2.2cqh; }
.scene-toast { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: .75em; padding: .75em .85em; border: 1px solid #ffffffb3; border-radius: 1.25em; background: #ffffffc7; -webkit-backdrop-filter: blur(16px) saturate(170%); backdrop-filter: blur(16px) saturate(170%); box-shadow: 0 1px 1px #0b142014, 0 14px 34px -12px #0b142073; color: #0f1b2a; font-size: clamp(10.5px, 2.85cqw, 12.5px); line-height: 1.25; text-align: left; }
.scene > .scene-toast { position: absolute; z-index: 1; }
.scene-icon { display: grid; place-items: center; align-self: start; width: 2.5em; aspect-ratio: 1; border-radius: .8em; background: linear-gradient(150deg, #2a5b87, #173b5c); color: #fff; box-shadow: inset 0 1px 0 #ffffff40, 0 2px 5px -2px #173b5c99; }
.scene-icon svg { width: 1.35em; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.scene-text { min-width: 0; }
.scene-text > b { display: block; font-size: 1.04em; font-weight: 650; letter-spacing: -.01em; }
.scene-text small { display: block; margin-top: .2em; color: #59656f; font-size: .88em; }
.scene-check { width: 1.65em; }
.scene-check circle { fill: #1f8f5a; }
.scene-check path { fill: none; stroke: #fff; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 13; }
.scene-chips { display: flex; flex-wrap: wrap; gap: .3em; margin: .5em 0 .55em; }
.scene-chip { padding: .2em .55em; border-radius: 999px; background: #173b5c; color: #fff; font-size: .86em; font-style: normal; font-weight: 600; }
.scene-chip.is-quiet { background: #e6ecf2; color: #51606e; }
.scene-progress { display: block; height: .32em; overflow: hidden; border-radius: 999px; background: #dde5ec; }
.scene-progress > span { display: block; width: var(--part, 100%); height: 100%; border-radius: inherit; background: linear-gradient(90deg, #3b7bb3, #173b5c); transform-origin: left; }
.scene-text small.scene-swap { display: grid; }
.scene-swap > span, .scene-button > span { grid-area: 1 / 1; }
.scene-before { visibility: hidden; }
.scene-live { display: flex; align-items: center; gap: .4em; color: #1f7a4d; font-weight: 600; }
.scene-live::before { content: ''; flex: none; width: .5em; height: .5em; border-radius: 50%; background: #22a565; box-shadow: 0 0 0 .2em #22a56533; }
.scene-button { position: relative; display: grid; padding: .5em 1em; border-radius: 999px; background: #176b43; color: #fff; font-weight: 650; text-align: center; white-space: nowrap; }
.scene-cursor { position: absolute; z-index: 2; left: 62%; top: 62%; width: 1.6em; filter: drop-shadow(0 1px 1px #0006); opacity: 0; }

/* Carte 1 : scanR, import, publication. */
#votre-site .scene { --focus: 66% 70%; }
#votre-site .scene-stack { top: 4cqh; right: 3cqw; width: max(58cqw, 205px); }
.import-toast { grid-template-columns: auto 1fr; }
.scene-number { --scene-count: 8; counter-reset: scene var(--scene-count); color: #173b5c; font-size: 1.15em; }
.scene-number::before { content: counter(scene); }
.publish-toast { left: 3cqw; bottom: 4cqh; width: max(50cqw, 185px); }

/* Carte 2 : vue d'ensemble, veille, LinkedIn. */
#vue-ensemble .scene { --focus: 28% 40%; --photo-y: 42%; }
.overview-toast { left: 2.5cqw; bottom: 4cqh; width: 45cqw; grid-template-columns: 1fr; }
.scene-meter { display: grid; grid-template-columns: 7.2em 1fr auto; white-space: nowrap; align-items: center; gap: .5em; margin-top: .42em; font-size: .88em; font-weight: 500; }
.scene-meter em { color: #59656f; font-style: normal; font-variant-numeric: tabular-nums; }
#vue-ensemble .scene-stack { right: 2.5cqw; bottom: 4cqh; width: 49cqw; }
.scene-switch { position: relative; width: 2.6em; height: 1.5em; border-radius: 999px; background: #1f8f5a; }
.scene-switch i { position: absolute; top: .15em; left: 1.25em; width: 1.2em; aspect-ratio: 1; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px #0b142059; }
.veille-alerts { grid-column: 1 / -1; display: grid; gap: .3em; padding-top: .5em; border-top: 1px solid #0f1b2a14; font-size: .88em; font-weight: 600; }
.veille-alert { display: flex; align-items: center; gap: .5em; }
.veille-alert::before { content: ''; flex: none; width: .55em; height: .55em; border-radius: 50%; background: #2a6fa8; box-shadow: 0 0 0 .2em #2a6fa833; }
.veille-alert.is-open::before { background: #22a565; box-shadow: 0 0 0 .2em #22a56533; }
.scene-icon.is-linkedin { overflow: hidden; background: #fff; box-shadow: 0 2px 5px -2px #0a66c299; }
.scene-icon.is-linkedin svg { width: 100%; fill: #0a66c2; stroke: none; }

/* Carte 3 : document, format, CV. */
#vos-exports .scene { --focus: 72% 40%; --photo-y: 40%; }
.scene-doc { position: absolute; z-index: 1; left: 3cqw; top: 5cqh; width: min(37cqw, 56cqh); aspect-ratio: 595 / 842; overflow: hidden; border-radius: 3px; background: #fff; box-shadow: 0 1px 2px #0b142033, 0 18px 36px -12px #0b142080; }
.scene-doc img { display: block; width: 100%; height: 100%; }
.export-toast { right: 2.5cqw; top: 3cqh; width: max(54cqw, 150px); grid-template-columns: 1fr; }
.export-toast .scene-chips { margin: .4em 0 0; }
.scene-text small.scene-label { margin-top: .6em; color: #59656f; font-size: .86em; font-weight: 600; }
.scene-period { display: flex; align-items: center; justify-content: space-between; gap: .5em; margin-top: .55em; }
.scene-period .scene-label { margin-top: 0; }
.scene-text small.scene-select { margin-top: 0; padding: .15em .6em; border: 1px solid #cdd7e0; border-radius: .55em; background: #ffffffa6; color: #0f1b2a; font-weight: 600; text-align: center; }
.format-toast { right: 2.5cqw; bottom: 3cqh; width: max(54cqw, 150px); grid-template-columns: 1fr; }
.scene-files { display: grid; grid-template-columns: repeat(3, 1fr); gap: .4em; margin-top: .5em; }
.scene-file { position: relative; display: flex; align-items: center; justify-content: center; gap: .35em; padding: .4em .2em; border: 1px solid #d4dce4; border-radius: .7em; background: #ffffffa6; font-size: .88em; font-weight: 600; }
.scene-file::before { content: ''; flex: none; width: .75em; height: .95em; border-radius: .14em; background: var(--file); }
.scene-file.is-chosen { border-color: #173b5c; background: #e4edf5; box-shadow: inset 0 0 0 1px #173b5c; }
.download-toast { left: 3cqw; bottom: 3cqh; width: min(37cqw, 56cqh); padding: .5em .6em; grid-template-columns: 1fr auto; gap: .4em; }
.download-toast .scene-text > b { overflow: hidden; font-size: .92em; text-overflow: ellipsis; white-space: nowrap; }

/* Carte 4 : la question, puis quatre profils. */
#referencement .scene { --focus: 40% 45%; --photo-y: 38%; }
.search-toast { left: 3cqw; right: 3cqw; top: 3.5cqh; grid-template-columns: 1fr auto; }
.search-query { display: block; font-size: 1.04em; font-weight: 500; }
.search-query > span { display: block; width: max-content; max-width: 100%; }
.search-send { display: grid; place-items: center; width: 2.3em; aspect-ratio: 1; border-radius: .75em; background: #173b5c; color: #fff; }
.search-send svg { width: 1.2em; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.results-toast { left: 3cqw; bottom: 3cqh; width: max(62cqw, 225px); display: block; padding: .6em .75em .55em; }
.results-head { display: flex; justify-content: space-between; gap: .5em; margin: 0 0 .25em; color: #59656f; font-size: .86em; }
.result-row { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: .55em; padding: .3em 0; border-top: 1px solid #0f1b2a14; }
.result-row > i { display: grid; place-items: center; width: 2em; aspect-ratio: 1; border-radius: .55em; background: #dfe9f2; color: #173b5c; font-size: .86em; font-style: normal; font-weight: 700; }
.result-row b { display: block; font-weight: 650; }
.result-row small { display: block; color: #59656f; font-size: .88em; }
.result-row em { color: #59656f; font-size: .86em; font-style: normal; text-decoration: underline; text-underline-offset: .15em; }

/* Séquence au survol. Chaque élément a son départ (--at) et, si besoin, sa durée (--for) :
   le tableau des temps se lit carte par carte, sur 3,2 s. */
@property --scene-count { syntax: '<integer>'; inherits: false; initial-value: 8; }
@media (hover: hover) and (prefers-reduced-motion: no-preference) {
 .scene-photo { animation: scene-camera 3200ms cubic-bezier(.3, .2, .2, 1) both paused; }
 .scene-toast, .scene-doc, .result-row, .veille-alert { animation: scene-rise 380ms cubic-bezier(.2, .8, .2, 1) var(--at) both paused; }
 .scene-check path { animation: scene-tick 300ms ease-out var(--at) both paused; }
 .scene-chip:not(.is-quiet) { animation: scene-chip-on 130ms ease-out var(--at) both paused; }
 .scene-progress > span { animation: scene-fill var(--for) cubic-bezier(.4, 0, .2, 1) var(--at) both paused; }
 .scene-number { animation: scene-count var(--for) cubic-bezier(.4, 0, .2, 1) var(--at) both paused; }
 .scene-before { visibility: visible; animation: scene-fade-out 120ms linear var(--at) both paused; }
 .scene-after { animation: scene-fade-in 160ms linear var(--at) both paused; }
 .scene-button { animation: scene-press 260ms ease-out var(--at) both paused; }
 .scene-cursor { animation: scene-cursor-move 460ms cubic-bezier(.4, 0, .2, 1) calc(var(--at) - 460ms) both paused, scene-cursor-press 240ms ease-out var(--at) both paused; }
 .scene-switch { animation: scene-switch-on 200ms ease-out var(--at) both paused; }
 .scene-switch i { animation: scene-knob-on 200ms ease-out var(--at) both paused; }
 .scene-file.is-chosen { animation: scene-file-on 160ms ease-out var(--at) both paused; }
 .search-query > span { animation: scene-type var(--for) steps(var(--letters)) var(--at) both paused; }
 .search-send { animation: scene-press-soft 260ms ease-out var(--at) both paused; }

 /* Carte 1 */
 .scanr-toast { --at: 130ms; }
 .scanr-toast .scene-check path { --at: 450ms; }
 .import-toast { --at: 770ms; }
 .import-toast .scene-chip { --at: calc(1030ms + var(--i) * 130ms); }
 .import-toast :is(.scene-progress > span, .scene-number) { --at: 1030ms; --for: 670ms; }
 .publish-toast { --at: 1800ms; }
 .publish-toast :is(.scene-before, .scene-after, .scene-button, .scene-cursor) { --at: 2530ms; }

 /* Carte 2 */
 .overview-toast { --at: 130ms; }
 .overview-toast .scene-progress > span { --at: calc(400ms + var(--i) * 130ms); --for: 480ms; }
 .veille-toast { --at: 1000ms; }
 .veille-toast :is(.scene-switch, .scene-switch i) { --at: 1260ms; }
 .veille-toast :is(.scene-before, .scene-after) { --at: 1380ms; }
 .veille-alert { --at: calc(1480ms + var(--i) * 220ms); }
 .linkedin-toast { --at: 2020ms; }
 .linkedin-toast :is(.scene-button, .scene-cursor) { --at: 2740ms; }

 /* Carte 3 */
 .export-toast { --at: 130ms; }
 .export-toast .scene-chip { --at: 380ms; }
 .export-rubrics .scene-chip { --at: calc(560ms + var(--i) * 110ms); }
 .export-toast :is(.scene-before, .scene-after) { --at: 1150ms; }
 .format-toast { --at: 1350ms; }
 .format-toast :is(.scene-file.is-chosen, .scene-cursor) { --at: 2030ms; }
 .scene-doc { --at: 2180ms; }
 .download-toast { --at: 2600ms; }
 .download-toast .scene-check path { --at: 2880ms; }

 /* Carte 4 */
 .search-toast { --at: 130ms; }
 .search-query > span:nth-child(1) { --at: 400ms; --for: 620ms; }
 .search-query > span:nth-child(2) { --at: 1020ms; --for: 560ms; }
 .search-send { --at: 1640ms; }
 .results-toast { --at: 1800ms; }
 .result-row { --at: calc(1960ms + var(--i) * 140ms); }
}
@keyframes scene-camera { from { scale: 1; } to { scale: 1.08; } }
@keyframes scene-rise { from { opacity: 0; translate: 0 9px; scale: .96; } }
@keyframes scene-tick { from { stroke-dashoffset: 13; } to { stroke-dashoffset: 0; } }
@keyframes scene-chip-on { from { background: #e6ecf2; color: #94a2b0; } }
@keyframes scene-fill { from { scale: 0 1; } }
@keyframes scene-count { from { --scene-count: 0; } }
@keyframes scene-fade-out { to { opacity: 0; } }
@keyframes scene-fade-in { from { opacity: 0; } }
@keyframes scene-press {
 0% { scale: 1; background: #173b5c; }
 35% { scale: .92; background: #173b5c; }
 100% { scale: 1; }
}
@keyframes scene-press-soft { 40% { scale: .88; } }
@keyframes scene-cursor-move {
 from { opacity: 0; translate: 26cqw 18cqh; }
 30% { opacity: 1; }
 to { opacity: 1; translate: 0 0; }
}
@keyframes scene-cursor-press { 50% { scale: .85; } }
@keyframes scene-switch-on { from { background: #b9c4ce; } }
@keyframes scene-knob-on { from { left: .15em; } }
@keyframes scene-file-on { from { border-color: #d4dce4; background: #ffffffa6; box-shadow: none; } }
@keyframes scene-type { from { clip-path: inset(0 100% 0 0); } to { clip-path: inset(0 0 0 0); } }

.scene-text{overflow-wrap:anywhere;}
#vue-ensemble .scene-toast{grid-template-columns:auto minmax(0,1fr) auto;gap:.45em;}
#vue-ensemble .scene-text{padding-right:.2em;}
#vue-ensemble .scene-toast small{font-size:max(10px,.88em);}

#vue-ensemble .scene-chip {font-size:max(10px,.8em);}

/* Visuel dès le haut de la carte ; accroche et bénéfice regroupés dessous. */
.product-cards .product-card{grid-template-rows:300px 1fr;}
.product-cards #votre-site{min-height:0;}
.product-cards .card-sales h3{margin:0;font-size:20px;font-weight:650;line-height:1.2;letter-spacing:-.025em;}
.product-cards .card-sales h3::before{display:none;}
.product-cards .card-sales > .card-sales-detail{margin-top:12px;font-size:14px;font-weight:400;line-height:1.55;}
@media(max-width:1100px){.product-cards .product-card{grid-template-rows:400px 1fr;}}
